[gnome-characters] categoryList: Mimic GtkStackSidebar style
- From: Daiki Ueno <dueno src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-characters] categoryList: Mimic GtkStackSidebar style
- Date: Mon, 2 Mar 2015 02:02:38 +0000 (UTC)
commit 04c46802c71e492ae4da474e5837fe88f0a9aaf0
Author: Daiki Ueno <dueno src gnome org>
Date: Mon Mar 2 10:54:20 2015 +0900
categoryList: Mimic GtkStackSidebar style
data/application.css | 4 ++--
src/categoryList.js | 8 +++++++-
2 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/data/application.css b/data/application.css
index 871857d..0c1d828 100644
--- a/data/application.css
+++ b/data/application.css
@@ -1,5 +1,5 @@
-.list-row.category-list-row .category-label {
- padding: 10pt;
+.category-label {
+ padding: 3pt;
}
.menu-title {
diff --git a/src/categoryList.js b/src/categoryList.js
index 9057ba9..efdaa18 100644
--- a/src/categoryList.js
+++ b/src/categoryList.js
@@ -116,9 +116,15 @@ const CategoryListWidget = new Lang.Class({
params = Params.fill(params, {});
this.parent(params);
+ // Mimic GtkStackSidebar to take advantage of the standard theme.
+ this.get_style_context().add_class('sidebar');
+
for (let index in Category) {
let category = Category[index];
- this.add(new CategoryListRowWidget({}, category));
+ let rowWidget = new CategoryListRowWidget({}, category);
+ // Mimic GtkStackSidebar to take advantage of the standard theme.
+ rowWidget.get_style_context().add_class('sidebar-item');
+ this.add(rowWidget);
}
},
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]