[gnome-music] shortcuts: Fix CSS to allow ctrl+space accelerator



commit a12507f663818875e788b96adba195d4a0eede41
Author: Marinus Schraal <mschraal src gnome org>
Date:   Mon Sep 12 14:10:31 2016 +0200

    shortcuts: Fix CSS to allow ctrl+space accelerator
    
    Turns out we still used outdated css nodes to unbind space key.
    
    Revert the change in df89b9b and fix the css node names and add flowbox.
    Use the 'widget' name for libgd classes, since they are outdated and
    don't provide a css name yet.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=754096

 data/application.css |   17 +++++++----------
 data/help-overlay.ui |    2 +-
 2 files changed, 8 insertions(+), 11 deletions(-)
---
diff --git a/data/application.css b/data/application.css
index 5b8199f..cbacd61 100644
--- a/data/application.css
+++ b/data/application.css
@@ -1,19 +1,16 @@
 @define-color music_entry_tag_bg #3465a4;
 @define-color music_entry_tag_fg @theme_base_color;
 
-@binding-set UnbindSpace{
-    unbind "space";
+@binding-set unbind-ctrl-space {
+    unbind "<ctrl>space";
 }
 
-GdMainListView{
-    -gtk-key-bindings: UnbindSpace;
-}
-GdMainView{
-    -gtk-key-bindings: UnbindSpace;
-}
-GtkTreeView{
-    -gtk-key-bindings: UnbindSpace;
+/* Use widget for libgd classes, since they aren't updated
+   to gtk+-3.20 css naming yet. */
+flowbox, treeview, widget {
+    -gtk-key-bindings: unbind-ctrl-space;
 }
+
 .cover{
     padding-left:24px;
 }
diff --git a/data/help-overlay.ui b/data/help-overlay.ui
index e6bc6d5..f817127 100644
--- a/data/help-overlay.ui
+++ b/data/help-overlay.ui
@@ -49,7 +49,7 @@
               <object class="GtkShortcutsShortcut">
                 <property name="visible">True</property>
                 <property name="title" translatable="yes" context="shortcut window">Play/Pause</property>
-                <property name="accelerator">&lt;Primary&gt;P</property>
+                <property name="accelerator">&lt;Ctrl&gt;space &lt;Primary&gt;P</property>
               </object>
             </child>
             <child>


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