aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorConor Curran <conor.curran@canonical.com>2010-08-13 19:12:45 +0100
committerConor Curran <conor.curran@canonical.com>2010-08-13 19:12:45 +0100
commit04af32d9b321d4256cb1f7cf1f94b23387b75774 (patch)
treed866f128b1bbdb99c0b1d55f15770369ed270817 /src
parentf648465adb85a872c97bdb9b9a7d638cb8803049 (diff)
downloadayatana-indicator-sound-04af32d9b321d4256cb1f7cf1f94b23387b75774.tar.gz
ayatana-indicator-sound-04af32d9b321d4256cb1f7cf1f94b23387b75774.tar.bz2
ayatana-indicator-sound-04af32d9b321d4256cb1f7cf1f94b23387b75774.zip
a few tidy ups
Diffstat (limited to 'src')
-rw-r--r--src/metadata-widget.c2
-rw-r--r--src/mpris-controller.vala2
-rw-r--r--src/mpris2-controller.vala14
3 files changed, 6 insertions, 12 deletions
diff --git a/src/metadata-widget.c b/src/metadata-widget.c
index 670d983..da18ccc 100644
--- a/src/metadata-widget.c
+++ b/src/metadata-widget.c
@@ -201,11 +201,9 @@ metadata_widget_property_update(DbusmenuMenuitem* item, gchar* property,
if(g_value_get_int(value) == DBUSMENU_PROPERTY_EMPTY){
g_debug("Metadata widget: property update - reset");
- gchar* empty = "";
GValue new_value = {0};
g_value_init(&new_value, G_TYPE_STRING);
g_value_set_string(&new_value, g_strdup(""));
- //g_free(empty);
value = &new_value;
}
diff --git a/src/mpris-controller.vala b/src/mpris-controller.vala
index db71c70..1e1e00a 100644
--- a/src/mpris-controller.vala
+++ b/src/mpris-controller.vala
@@ -126,7 +126,7 @@ public class MprisController : GLib.Object
this.owner.custom_items[PlayerController.widget_order.METADATA].reset(MetadataMenuitem.attributes_format());
this.owner.custom_items[PlayerController.widget_order.SCRUB].reset(ScrubMenuitem.attributes_format());
- HashTable<string, Value?> status_hash = new HashTable<string, Value?>(str_hash, str_equal);
+ //HashTable<string, Value?> status_hash = new HashTable<string, Value?>(str_hash, str_equal);
status st = this.mpris_player.GetStatus();
int play_state = st.playback;
diff --git a/src/mpris2-controller.vala b/src/mpris2-controller.vala
index fb17bea..cfe0d68 100644
--- a/src/mpris2-controller.vala
+++ b/src/mpris2-controller.vala
@@ -58,7 +58,6 @@ public class Mpris2Controller : GLib.Object
public MprisPlayer mpris2_player {get; construct;}
public PlayerController owner {get; construct;}
-
public Mpris2Controller(PlayerController ctrl)
{
Object(owner: ctrl);
@@ -86,7 +85,7 @@ public class Mpris2Controller : GLib.Object
}
public void property_changed(Object mpris_player, ParamSpec new_status){
- debug("playback status changed, %s", new_status.get_name());
+ debug("playback status changed, %s", new_status.get_name());
}
public bool was_successfull(){
@@ -153,8 +152,7 @@ public class Mpris2Controller : GLib.Object
}
public void set_position(double position)
- {
- /*
+ {
debug("Set position with pos (0-100) %f", position);
HashTable<string, Value?> data = this.mpris2_player.Metadata;
Value? time_value = data.lookup("time");
@@ -175,9 +173,8 @@ public class Mpris2Controller : GLib.Object
else if(v.holds (typeof (string))){
debug("the trackid = %s", v.get_string());
}
- }
-
- //this.mpris2_player.SetPosition((int32)(new_time_position));
+ }
+ /*this.mpris2_player.SetPosition((int32)(new_time_position));
ScrubMenuitem scrub = this.owner.custom_items[PlayerController.widget_order.SCRUB] as ScrubMenuitem;
scrub.update_position(this.mpris2_player.Position);
*/
@@ -187,8 +184,7 @@ public class Mpris2Controller : GLib.Object
{
return (this.mpris2_player != null);
}
-
-
+
}