From 4f099e33c5fd3afa9ad37c1e5b62abb9ba645ec5 Mon Sep 17 00:00:00 2001 From: Felipe Borges Date: Fri, 21 Jun 2019 15:17:47 +0200 Subject: [PATCH 1/2] shell: Add global CSS stylesheet --- shell/cc-application.c | 8 ++++++++ shell/gnome-control-center.gresource.xml | 1 + shell/style.css | 0 3 files changed, 9 insertions(+) create mode 100644 shell/style.css diff --git a/shell/cc-application.c b/shell/cc-application.c index 67beb383ca..aea0e9b72e 100644 --- a/shell/cc-application.c +++ b/shell/cc-application.c @@ -276,9 +276,17 @@ cc_application_class_init (CcApplicationClass *klass) static void cc_application_init (CcApplication *self) { + g_autoptr(GtkCssProvider) provider = NULL; + cc_object_storage_initialize (); g_application_add_main_option_entries (G_APPLICATION (self), all_options); + + provider = gtk_css_provider_new (); + gtk_css_provider_load_from_resource (provider, "/org/gnome/ControlCenter/gtk/style.css"); + gtk_style_context_add_provider_for_screen (gdk_screen_get_default (), + GTK_STYLE_PROVIDER (provider), + GTK_STYLE_PROVIDER_PRIORITY_APPLICATION); } GtkApplication * diff --git a/shell/gnome-control-center.gresource.xml b/shell/gnome-control-center.gresource.xml index 567dc783b8..9be077ec9f 100644 --- a/shell/gnome-control-center.gresource.xml +++ b/shell/gnome-control-center.gresource.xml @@ -4,5 +4,6 @@ cc-panel-list.ui cc-window.ui help-overlay.ui + style.css diff --git a/shell/style.css b/shell/style.css new file mode 100644 index 0000000000..e69de29bb2 -- GitLab From eb8263454fba963efd93d33e61ad66294e73bd6a Mon Sep 17 00:00:00 2001 From: Allan Day Date: Fri, 21 Jun 2019 11:52:30 +0100 Subject: [PATCH 2/2] region: Use correct icon for the drag handle There's a dedicated icon for drag handles - we should make use of it. Also, change the color of the handle so it looks like it is part of the row. Fixes #590 --- panels/region/cc-input-row.ui | 7 +++++-- shell/style.css | 3 +++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/panels/region/cc-input-row.ui b/panels/region/cc-input-row.ui index c0e2ac6e20..70794fcee2 100644 --- a/panels/region/cc-input-row.ui +++ b/panels/region/cc-input-row.ui @@ -16,13 +16,16 @@ True 50 - 12 + 4 12 12 True - open-menu-symbolic + list-drag-handle-symbolic + diff --git a/shell/style.css b/shell/style.css index e69de29bb2..a548d65611 100644 --- a/shell/style.css +++ b/shell/style.css @@ -0,0 +1,3 @@ +.drag-handle { + color: @borders; +} -- GitLab