[gnome-software/wip/kalev/gtk-master] Fix up css selectors to work with gtk master



commit b4e8b82176c76a4c91b2551df1ab1349c62c420d
Author: Kalev Lember <klember redhat com>
Date:   Fri Nov 13 14:59:37 2015 +0100

    Fix up css selectors to work with gtk master
    
    XXX: This breaks gtk 3.18.x

 src/gs-feature-tile.c    |    4 ++--
 src/gs-progress-button.c |    6 +++---
 src/gtk-style-hc.css     |    4 ++--
 src/gtk-style.css        |    4 ++--
 4 files changed, 9 insertions(+), 9 deletions(-)
---
diff --git a/src/gs-feature-tile.c b/src/gs-feature-tile.c
index 567261b..268391e 100644
--- a/src/gs-feature-tile.c
+++ b/src/gs-feature-tile.c
@@ -129,7 +129,7 @@ gs_feature_tile_set_app (GsFeatureTile *tile, GsApp *app)
        text_shadow = gs_app_get_metadata_item (app, "Featured::text-shadow");
 
        data = g_string_sized_new (1024);
-       g_string_append (data, ".button.featured-tile {\n");
+       g_string_append (data, "button.featured-tile {\n");
        g_string_append_printf (data, "  border-color: %s;\n", stroke_color);
        if (text_shadow != NULL)
                g_string_append_printf (data, "  text-shadow: %s;\n", text_shadow);
@@ -140,7 +140,7 @@ gs_feature_tile_set_app (GsFeatureTile *tile, GsApp *app)
        g_string_append (data, "  outline-offset: 2px;\n");
        g_string_append_printf (data, "  background: %s;\n", background);
        g_string_append (data, "}\n");
-       g_string_append (data, ".button.featured-tile:hover {\n");
+       g_string_append (data, "button.featured-tile:hover {\n");
        g_string_append (data, "  background: linear-gradient(to bottom,\n");
        g_string_append (data, "                              alpha(#fff,0.16),\n");
        g_string_append_printf (data,
diff --git a/src/gs-progress-button.c b/src/gs-progress-button.c
index ce29f91..22c7226 100644
--- a/src/gs-progress-button.c
+++ b/src/gs-progress-button.c
@@ -38,11 +38,11 @@ gs_progress_button_set_progress (GsProgressButton *button, guint percentage)
        gchar *css;
 
        if (percentage == 0)
-               css = g_strdup (".button.install-progress { background: @theme_bg_color; }");
+               css = g_strdup ("button.install-progress { background: @theme_bg_color; }");
        else if (percentage == 100)
-               css = g_strdup (".button.install-progress { background: @theme_selected_bg_color; }");
+               css = g_strdup ("button.install-progress { background: @theme_selected_bg_color; }");
        else
-               css = g_strdup_printf (".button.install-progress { background: linear-gradient(to right, 
@theme_selected_bg_color %d%%, @theme_bg_color %d%%); }", percentage, percentage + 1);
+               css = g_strdup_printf ("button.install-progress { background: linear-gradient(to right, 
@theme_selected_bg_color %d%%, @theme_bg_color %d%%); }", percentage, percentage + 1);
 
        gtk_css_provider_load_from_data (button->css_provider, css, -1, NULL);
        g_free (css);
diff --git a/src/gtk-style-hc.css b/src/gtk-style-hc.css
index e222160..9cbf97b 100644
--- a/src/gtk-style-hc.css
+++ b/src/gtk-style-hc.css
@@ -57,7 +57,7 @@
 }
 
 /* The rest of the featured-tile CSS is loaded at runtime in gs-feature-tile.c */
-.button.featured-tile {
+button.featured-tile {
        all: unset;
        padding: 0;
        border-radius: 0;
@@ -123,7 +123,7 @@ GtkBox.star {
        background-image: none;
 }
 
-.button.star {
+button.star {
        -GtkWidget-focus-padding: 0;
        background-color: transparent;
        background-image: none;
diff --git a/src/gtk-style.css b/src/gtk-style.css
index 093f812..457c4e6 100644
--- a/src/gtk-style.css
+++ b/src/gtk-style.css
@@ -60,7 +60,7 @@
 }
 
 /* The rest of the featured-tile CSS is loaded at runtime in gs-feature-tile.c */
-.button.featured-tile {
+button.featured-tile {
        all: unset;
        padding: 0;
        border-radius: 0;
@@ -127,7 +127,7 @@ GtkBox.star {
        background-image: none;
 }
 
-.button.star {
+button.star {
        -GtkWidget-focus-padding: 0;
        background-color: transparent;
        background-image: none;


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