[geary/wip/christopherdavis/full-height-separator] main-toolbar: Use a full-height, splitting separator
- From: Christopher Davis <christopherdavis src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary/wip/christopherdavis/full-height-separator] main-toolbar: Use a full-height, splitting separator
- Date: Thu, 18 Apr 2019 20:35:21 +0000 (UTC)
commit d4436fa372b4e8355d9967ba397f657c0e0b95d8
Author: Christopher Davis <brainblasted disroot org>
Date: Thu Apr 18 16:31:41 2019 -0400
main-toolbar: Use a full-height, splitting separator
Previously we used a separator in the middle of the main toolbar and extended the width of the HeaderBar
in order to
special case for Ambiance.
Ambiance is no longer the default Ubuntu theme, and sticking
with GNOME design patterns should be prioritized over
special casing with a theme.
Fixes https://gitlab.gnome.org/GNOME/geary/issues/389
src/client/components/main-toolbar.vala | 12 ++----------
ui/main-toolbar.ui | 23 +++++++++++------------
2 files changed, 13 insertions(+), 22 deletions(-)
---
diff --git a/src/client/components/main-toolbar.vala b/src/client/components/main-toolbar.vala
index b80e6912..92855f60 100644
--- a/src/client/components/main-toolbar.vala
+++ b/src/client/components/main-toolbar.vala
@@ -67,18 +67,10 @@ public class MainToolbar : Gtk.Box {
public MainToolbar(Configuration config) {
- // Instead of putting a separator between the two headerbars, as other applications do,
- // we put a separator at the right end of the left headerbar. This greatly improves
- // the appearance under the Ambiance theme (see bug #746171). To get this separator to
- // line up with the handle of the pane, we need to extend the width of the left-hand
- // headerbar a bit. Six pixels is right both for Adwaita and Ambiance.
+ // Sync headerbar width with left pane
config.bind(Configuration.MESSAGES_PANE_POSITION_KEY, this, "left-pane-width",
SettingsBindFlags.GET);
- this.bind_property("left-pane-width", this.folder_header, "width-request",
- BindingFlags.SYNC_CREATE, (binding, source_value, ref target_value) => {
- target_value = left_pane_width + 6;
- return true;
- });
+ this.bind_property("left-pane-width", this.folder_header, "width-request", BindingFlags.SYNC_CREATE);
if (config.desktop_environment != Configuration.DesktopEnvironment.UNITY) {
this.bind_property("account", this.folder_header, "title", BindingFlags.SYNC_CREATE);
diff --git a/ui/main-toolbar.ui b/ui/main-toolbar.ui
index 410dea1c..72549aab 100644
--- a/ui/main-toolbar.ui
+++ b/ui/main-toolbar.ui
@@ -32,17 +32,6 @@
</child>
</object>
</child>
- <child>
- <object class="GtkSeparator" id="header_separator">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="orientation">vertical</property>
- </object>
- <packing>
- <property name="pack_type">end</property>
- <property name="position">1</property>
- </packing>
- </child>
<child>
<object class="GtkToggleButton" id="search_conversations_button">
<property name="visible">True</property>
@@ -95,6 +84,16 @@
<property name="position">0</property>
</packing>
</child>
+ <child>
+ <object class="GtkSeparator" id="header_separator">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ </object>
+ <packing>
+ <property name="position">1</property>
+ </packing>
+ </child>
<child>
<object class="GtkHeaderBar" id="conversation_header">
<property name="visible">True</property>
@@ -359,7 +358,7 @@
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">2</property>
</packing>
</child>
</template>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]