diff options
author | Conor Curran <conor.curran@canonical.com> | 2010-07-13 12:18:08 +0100 |
---|---|---|
committer | Conor Curran <conor.curran@canonical.com> | 2010-07-13 12:18:08 +0100 |
commit | 4325e0092d77cc2d993c7305c49d0517f3defb0e (patch) | |
tree | c3ed0eba5a33b8e55b104f8eb9b25f868c9fe3b1 /src/player-controller.vala | |
parent | f383ead1168dde3374dabc2040035907d4ab484d (diff) | |
download | ayatana-indicator-sound-4325e0092d77cc2d993c7305c49d0517f3defb0e.tar.gz ayatana-indicator-sound-4325e0092d77cc2d993c7305c49d0517f3defb0e.tar.bz2 ayatana-indicator-sound-4325e0092d77cc2d993c7305c49d0517f3defb0e.zip |
prep work done for scrub bar
Diffstat (limited to 'src/player-controller.vala')
-rw-r--r-- | src/player-controller.vala | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/src/player-controller.vala b/src/player-controller.vala index d272d14..db81ee2 100644 --- a/src/player-controller.vala +++ b/src/player-controller.vala @@ -23,8 +23,16 @@ using Gee; public class PlayerController : GLib.Object { - public const int METADATA = 2; - private const int TRANSPORT = 3; + public const int WIDGET_QUANTITY = 4;//for now //5; + + public static enum widget_order{ + SEPARATOR, + TITLE, + METADATA, + TRANSPORT + } + //public const int METADATA = 2; + //private const int TRANSPORT = 3; public enum state{ OFFLINE, @@ -51,7 +59,6 @@ public class PlayerController : GLib.Object this.custom_items = new ArrayList<PlayerItem>(); this.update_state(initial_state); this.menu_offset = offset; - debug("offset = %i", offset); construct_widgets(); establish_mpris_connection(); update_layout(); @@ -66,7 +73,7 @@ public class PlayerController : GLib.Object public void activate() { this.establish_mpris_connection(); - this.custom_items[METADATA].property_set_bool(MENUITEM_PROP_VISIBLE, true); + this.custom_items[widget_order.METADATA].property_set_bool(MENUITEM_PROP_VISIBLE, true); } /* @@ -126,8 +133,8 @@ public class PlayerController : GLib.Object visibility = false; } debug("about the set the visibility on both the transport and metadata widget to %s", visibility.to_string()); - this.custom_items[TRANSPORT].property_set_bool(MENUITEM_PROP_VISIBLE, visibility); - this.custom_items[METADATA].property_set_bool(MENUITEM_PROP_VISIBLE, visibility); + this.custom_items[widget_order.TRANSPORT].property_set_bool(MENUITEM_PROP_VISIBLE, visibility); + this.custom_items[widget_order.METADATA].property_set_bool(MENUITEM_PROP_VISIBLE, visibility); // DEBUG if(this.mpris_adaptor == null){ warning("Why is the mpris object null"); |