[rygel] gst-renderer: Use 'this' for methods as well



commit dc75584666c7e9acee3ed0dd77283a7b8a4e4220
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Wed Oct 14 15:05:45 2009 +0300

    gst-renderer: Use 'this' for methods as well

 .../gst-renderer/rygel-gst-av-transport.vala       |   47 ++++++++++----------
 src/plugins/gst-renderer/rygel-gst-changelog.vala  |    8 ++--
 .../gst-renderer/rygel-gst-rendering-control.vala  |   26 +++++-----
 3 files changed, 41 insertions(+), 40 deletions(-)
---
diff --git a/src/plugins/gst-renderer/rygel-gst-av-transport.vala b/src/plugins/gst-renderer/rygel-gst-av-transport.vala
index 4a22ed1..b6a91ae 100644
--- a/src/plugins/gst-renderer/rygel-gst-av-transport.vala
+++ b/src/plugins/gst-renderer/rygel-gst-av-transport.vala
@@ -139,22 +139,23 @@ public class Rygel.GstAVTransport : Service {
         this.changelog = new GstChangeLog (this, LAST_CHANGE_NS);
         this.video_window = GstVideoWindow.get_default ();
 
-        query_variable["LastChange"].connect (query_last_change_cb);
+        query_variable["LastChange"].connect (this.query_last_change_cb);
 
-        action_invoked["SetAVTransportURI"].connect (set_av_transport_uri_cb);
-        action_invoked["GetMediaInfo"].connect (get_media_info_cb);
-        action_invoked["GetTransportInfo"].connect (get_transport_info_cb);
-        action_invoked["GetPositionInfo"].connect (get_position_info_cb);
+        action_invoked["SetAVTransportURI"].connect (
+                                        this.set_av_transport_uri_cb);
+        action_invoked["GetMediaInfo"].connect (this.get_media_info_cb);
+        action_invoked["GetTransportInfo"].connect (this.get_transport_info_cb);
+        action_invoked["GetPositionInfo"].connect (this.get_position_info_cb);
         action_invoked["GetDeviceCapabilities"].connect (
-                                        get_device_capabilities_cb);
+                                        this.get_device_capabilities_cb);
         action_invoked["GetTransportSettings"].connect (
-                                        get_transport_settings_cb);
-        action_invoked["Stop"].connect (stop_cb);
-        action_invoked["Play"].connect (play_cb);
-        action_invoked["Pause"].connect (pause_cb);
-        action_invoked["Seek"].connect (seek_cb);
-        action_invoked["Next"].connect (next_cb);
-        action_invoked["Previous"].connect (previous_cb);
+                                        this.get_transport_settings_cb);
+        action_invoked["Stop"].connect (this.stop_cb);
+        action_invoked["Play"].connect (this.play_cb);
+        action_invoked["Pause"].connect (this.pause_cb);
+        action_invoked["Seek"].connect (this.seek_cb);
+        action_invoked["Next"].connect (this.next_cb);
+        action_invoked["Previous"].connect (this.previous_cb);
 
         this.video_window.notify["playback-state"].connect (
                                         this.notify_state_cb);
@@ -209,7 +210,7 @@ public class Rygel.GstAVTransport : Service {
 
     private void set_av_transport_uri_cb (Service             service,
                                           owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -226,7 +227,7 @@ public class Rygel.GstAVTransport : Service {
 
     private void get_media_info_cb (Service             service,
                                     owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -264,7 +265,7 @@ public class Rygel.GstAVTransport : Service {
 
     private void get_transport_info_cb (Service             service,
                                         owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -283,7 +284,7 @@ public class Rygel.GstAVTransport : Service {
 
     private void get_position_info_cb (Service             service,
                                        owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -317,7 +318,7 @@ public class Rygel.GstAVTransport : Service {
 
     private void get_device_capabilities_cb (Service             service,
                                              owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -330,7 +331,7 @@ public class Rygel.GstAVTransport : Service {
 
     private void get_transport_settings_cb (Service             service,
                                             owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -341,7 +342,7 @@ public class Rygel.GstAVTransport : Service {
     }
 
     private void stop_cb (Service service, owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -351,7 +352,7 @@ public class Rygel.GstAVTransport : Service {
     }
 
     private void play_cb (Service service, owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -370,7 +371,7 @@ public class Rygel.GstAVTransport : Service {
     }
 
     private void pause_cb (Service service, owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -380,7 +381,7 @@ public class Rygel.GstAVTransport : Service {
     }
 
     private void seek_cb (Service service, owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
diff --git a/src/plugins/gst-renderer/rygel-gst-changelog.vala b/src/plugins/gst-renderer/rygel-gst-changelog.vala
index 71631a8..65f1e5d 100644
--- a/src/plugins/gst-renderer/rygel-gst-changelog.vala
+++ b/src/plugins/gst-renderer/rygel-gst-changelog.vala
@@ -52,7 +52,7 @@ public class Rygel.GstChangeLog : Object {
 
     private bool timeout () {
         // Emit notification
-        this.service.notify ("LastChange", typeof (string), finish ());
+        this.service.notify ("LastChange", typeof (string), this.finish ());
         debug ("LastChange sent");
 
         // Reset
@@ -67,7 +67,7 @@ public class Rygel.GstChangeLog : Object {
         // Make sure we have a notification timeout
         if (this.service != null && this.timeout_id == 0) {
             debug ("Setting up timeout for LastChange");
-            this.timeout_id = Timeout.add (200, timeout);
+            this.timeout_id = Timeout.add (200, this.timeout);
         }
     }
 
@@ -75,7 +75,7 @@ public class Rygel.GstChangeLog : Object {
         debug (@"'%s = %s' logged", variable, value);
         this.hash.set (variable, "<%s val=\"%s\"/>".printf (variable, value));
 
-        ensure_timeout ();
+        this.ensure_timeout ();
     }
 
     public void log_with_channel (string variable,
@@ -86,7 +86,7 @@ public class Rygel.GstChangeLog : Object {
                                                                  value,
                                                                  channel));
 
-        ensure_timeout ();
+        this.ensure_timeout ();
     }
 
     public string finish () {
diff --git a/src/plugins/gst-renderer/rygel-gst-rendering-control.vala b/src/plugins/gst-renderer/rygel-gst-rendering-control.vala
index cc746e9..ac14a08 100644
--- a/src/plugins/gst-renderer/rygel-gst-rendering-control.vala
+++ b/src/plugins/gst-renderer/rygel-gst-rendering-control.vala
@@ -82,14 +82,14 @@ public class Rygel.GstRenderingControl : Service {
         this.changelog = new GstChangeLog (this, LAST_CHANGE_NS);
         this.video_window = GstVideoWindow.get_default ();
 
-        query_variable["LastChange"].connect (query_last_change_cb);
+        query_variable["LastChange"].connect (this.query_last_change_cb);
 
-        action_invoked["ListPresets"].connect (list_presets_cb);
-        action_invoked["SelectPreset"].connect (select_preset_cb);
-        action_invoked["GetMute"].connect (get_mute_cb);
-        action_invoked["SetMute"].connect (set_mute_cb);
-        action_invoked["GetVolume"].connect (get_volume_cb);
-        action_invoked["SetVolume"].connect (set_volume_cb);
+        action_invoked["ListPresets"].connect (this.list_presets_cb);
+        action_invoked["SelectPreset"].connect (this.select_preset_cb);
+        action_invoked["GetMute"].connect (this.get_mute_cb);
+        action_invoked["SetMute"].connect (this.set_mute_cb);
+        action_invoked["GetVolume"].connect (this.get_volume_cb);
+        action_invoked["SetVolume"].connect (this.set_volume_cb);
 
         this._volume = Volume.to_percentage (this.video_window.volume);
     }
@@ -123,7 +123,7 @@ public class Rygel.GstRenderingControl : Service {
 
     private void list_presets_cb (Service             service,
                                   owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -136,7 +136,7 @@ public class Rygel.GstRenderingControl : Service {
 
     private void select_preset_cb (Service             service,
                                    owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -168,7 +168,7 @@ public class Rygel.GstRenderingControl : Service {
 
     private void get_mute_cb (Service             service,
                               owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -183,7 +183,7 @@ public class Rygel.GstRenderingControl : Service {
 
     private void set_mute_cb (Service             service,
                               owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -202,7 +202,7 @@ public class Rygel.GstRenderingControl : Service {
 
     private void get_volume_cb (Service             service,
                                 owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 
@@ -217,7 +217,7 @@ public class Rygel.GstRenderingControl : Service {
 
     private void set_volume_cb (Service             service,
                                 owned ServiceAction action) {
-        if (!check_instance_id (action)) {
+        if (!this.check_instance_id (action)) {
             return;
         }
 



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