[polari/wip/fmuellner/window-experiments: 14/15] mainWindow: Hide left headerbar when in single-room mode



commit e1d97f97aef08f7fc5936bef3a8990aa5ce57129
Author: Florian Müllner <fmuellner gnome org>
Date:   Thu Jul 21 04:18:37 2016 +0200

    mainWindow: Hide left headerbar when in single-room mode

 data/resources/application.css |    8 ++++++--
 data/resources/main-window.ui  |    8 ++++++--
 2 files changed, 12 insertions(+), 4 deletions(-)
---
diff --git a/data/resources/application.css b/data/resources/application.css
index 7a11efd..d9826be 100644
--- a/data/resources/application.css
+++ b/data/resources/application.css
@@ -104,9 +104,13 @@
 
 /* Hack: Move separator by 1px so that it aligns with the sidebar */
 .titlebar > separator:dir(ltr) { margin-left: -1px; }
-.titlebar > headerbar:first-child:dir(ltr) { margin-right: 1px; }
+.titlebar > headerbar:first-child:not(:last-child):dir(ltr) {
+    margin-right: 1px;
+}
 .titlebar > separator:dir(rtl) { margin-right: -1px; }
-.titlebar > headerbar:first-child:dir(rtl) { margin-left: 1px; }
+.titlebar > headerbar:first-child:not(:last-child):dir(rtl) {
+    margin-left: 1px;
+}
 
 .polari-user-list-button {
     padding: 0px 4px;
diff --git a/data/resources/main-window.ui b/data/resources/main-window.ui
index 9c2f69c..b225172 100644
--- a/data/resources/main-window.ui
+++ b/data/resources/main-window.ui
@@ -17,7 +17,9 @@
         <property name="visible">True</property>
         <child>
           <object class="GtkHeaderBar" id="titlebarLeft">
-            <property name="visible">True</property>
+            <property name="visible" bind-source="Gjs_MainWindow"
+                      bind-property="single-room"
+                      bind-flags="sync-create|invert-boolean"/>
             <property name="hexpand">False</property>
             <property name="show-close-button">True</property>
             <child>
@@ -51,7 +53,9 @@
         </child>
         <child>
           <object class="GtkSeparator">
-            <property name="visible">True</property>
+            <property name="visible" bind-source="Gjs_MainWindow"
+                      bind-property="single-room"
+                      bind-flags="sync-create|invert-boolean"/>
             <property name="orientation">vertical</property>
           </object>
         </child>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]