[Sugar-devel] [sugar] Fixed name clash set_state

Martin Abente mabente at paraguayeduca.org
Wed May 19 15:25:41 EDT 2010


Method set_state at GsmPalette class was unintentionally overiding
its parent method.

Signed-off-by: Martin Abente <mabente at paraguayeduca.org>
---
 extensions/deviceicon/network.py |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/extensions/deviceicon/network.py b/extensions/deviceicon/network.py
index 94a4293..5f10ce3 100644
--- a/extensions/deviceicon/network.py
+++ b/extensions/deviceicon/network.py
@@ -235,7 +235,7 @@ class GsmPalette(Palette):
         self.menu.append(self._toggle_state_item)
         self._toggle_state_item.show()
 
-        self.set_state(_GSM_STATE_NOT_READY)
+        self.set_gsm_state(_GSM_STATE_NOT_READY)
 
         self.info_box = gtk.VBox()
 
@@ -267,7 +267,7 @@ class GsmPalette(Palette):
         alignment.add(child)
         return alignment
 
-    def set_state(self, state):
+    def set_gsm_state(self, state):
         self._current_state = state
         self._update_label_and_text()
 
@@ -852,7 +852,7 @@ class GsmDeviceView(TrayIcon):
             gsm_state = _GSM_STATE_NEED_AUTH
             
         if self._palette is not None:
-            self._palette.set_state(gsm_state)
+            self._palette.set_gsm_state(gsm_state)
 
     def disconnect(self):
         self._bus.remove_signal_receiver(self.__state_changed_cb,
-- 
1.6.0.4



More information about the Sugar-devel mailing list