[gnome-music] Added css themeing for the playerbar



commit ee04877ce69b411d2294c88186d376cbe5a83d97
Author: Seif Lotfy <seif lotfy com>
Date:   Thu Apr 4 11:29:58 2013 +0200

    Added css themeing for the playerbar

 data/application.css |   10 ++++++++++
 src/player.js        |   15 +++++++++------
 2 files changed, 19 insertions(+), 6 deletions(-)
---
diff --git a/data/application.css b/data/application.css
index 2f02bd0..0354094 100644
--- a/data/application.css
+++ b/data/application.css
@@ -12,6 +12,16 @@
 @define-color music_selection_button_dark_b #1c1c1c;
 @define-color music_selection_box_dark_border #3e7b05;
 
+.play-bar {
+    border-width: 1px 0 0;
+    border-style: solid;
+    border-color: shade(@borders, 0.90);
+    padding: 0 1px;
+
+    box-shadow: inset 0 -1px shade(@borders, 1.30);
+    background-color: @theme_bg_color;
+}
+
 .music-selection-mode {
     background-image: -gtk-gradient(linear, left top, left bottom,
                                     from(@music_selection_box_a),
diff --git a/src/player.js b/src/player.js
index a21e938..4c2c7f6 100644
--- a/src/player.js
+++ b/src/player.js
@@ -124,9 +124,9 @@ const Player = new Lang.Class({
             toolbar_start,
             toolbar_song_info;
 
-        this.eventbox = new Gtk.Box();
-        this.eventbox.set_spacing(9)
-        this.eventbox.set_border_width(9)
+        this.box = new Gtk.Box();
+        this.box.set_spacing(9)
+        this.box.set_border_width(9)
         toolbar_start = new Gtk.Box({
             orientation: Gtk.Orientation.HORIZONTAL,
             spacing: 0
@@ -147,7 +147,7 @@ const Player = new Lang.Class({
         next_btn.connect("clicked", Lang.bind(this, this._onNextBtnClicked));
         toolbar_start.pack_start(next_btn, false, false, 0);
         
-        this.eventbox.pack_start(toolbar_start, false, false, 3)
+        this.box.pack_start(toolbar_start, false, false, 3)
 
 
         this.progress_scale = new Gtk.Scale({
@@ -206,7 +206,7 @@ const Player = new Lang.Class({
         toolbar_center.pack_start(this.song_total_time_lbl, false, false, 0);
         */
         
-        this.eventbox.pack_start(toolbar_center, true, true, 0)
+        this.box.pack_start(toolbar_center, true, true, 0)
 
         toolbar_end = new Gtk.Box({
             orientation: Gtk.Orientation.HORIZONTAL,
@@ -218,7 +218,7 @@ const Player = new Lang.Class({
             xscale: 0,
             yscale: 0
         });
-        this.eventbox.pack_end(toolbar_end, false, false, 3);
+        this.box.pack_end(toolbar_end, false, false, 3);
 
         rate_btn = new Gtk.Button ();
         rate_btn.set_image(Gtk.Image.new_from_icon_name("bookmark-new-symbolic", Gtk.IconSize.BUTTON));
@@ -229,6 +229,9 @@ const Player = new Lang.Class({
         this.shuffle_btn.connect("clicked", Lang.bind(this, this._onShuffleBtnClicked));
         toolbar_end.pack_end(this.shuffle_btn, false, false, 0);
 
+        this.eventbox = new Gtk.EventBox();
+        this.eventbox.get_style_context().add_class("play-bar")
+        this.eventbox.add(this.box);
         this.eventbox.show_all();
 
     },


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