From e95e786432cd4385cf6dd86bec2d21538d0ffff5 Mon Sep 17 00:00:00 2001 From: Marco Pesenti Gritti Date: Thu, 16 Aug 2007 12:51:33 +0200 Subject: [PATCH] Adapt to icon name changes --- shell/intro/colorpicker.py | 2 +- shell/model/homeactivity.py | 2 +- shell/view/BuddyIcon.py | 2 +- shell/view/BuddyMenu.py | 4 ++-- shell/view/clipboardmenu.py | 4 ++-- shell/view/devices/network/wired.py | 2 +- shell/view/home/MyIcon.py | 2 +- sugar/graphics/objectchooser.py | 2 +- tests/test-snowflake-layout.py | 4 ++-- tests/test-spread-layout.py | 2 +- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/shell/intro/colorpicker.py b/shell/intro/colorpicker.py index f7ab59cc..d70d84cc 100644 --- a/shell/intro/colorpicker.py +++ b/shell/intro/colorpicker.py @@ -26,7 +26,7 @@ class ColorPicker(hippo.CanvasBox, hippo.CanvasItem): self.props.orientation = hippo.ORIENTATION_HORIZONTAL self._xo = CanvasIcon(size=style.XLARGE_ICON_SIZE, - icon_name='theme:stock-buddy') + icon_name='theme:xo') self._set_random_colors() self._xo.connect('activated', self._xo_activated_cb) self.append(self._xo) diff --git a/shell/model/homeactivity.py b/shell/model/homeactivity.py index e95fe9ad..434a3a68 100644 --- a/shell/model/homeactivity.py +++ b/shell/model/homeactivity.py @@ -103,7 +103,7 @@ class HomeActivity(gobject.GObject): if self._activity_info: return self._activity_info.icon else: - return 'theme:stock-missing' + return 'theme:image-missing' def get_icon_color(self): """Retrieve the appropriate icon colour for this activity diff --git a/shell/view/BuddyIcon.py b/shell/view/BuddyIcon.py index ebd12f05..f16b71cd 100644 --- a/shell/view/BuddyIcon.py +++ b/shell/view/BuddyIcon.py @@ -20,7 +20,7 @@ from view.BuddyMenu import BuddyMenu class BuddyIcon(CanvasIcon): def __init__(self, shell, buddy): - CanvasIcon.__init__(self, icon_name='theme:stock-buddy', + CanvasIcon.__init__(self, icon_name='theme:xo', xo_color=buddy.get_color()) self._shell = shell diff --git a/shell/view/BuddyMenu.py b/shell/view/BuddyMenu.py index e3efb5cc..e3d1a203 100644 --- a/shell/view/BuddyMenu.py +++ b/shell/view/BuddyMenu.py @@ -80,10 +80,10 @@ class BuddyMenu(Palette): friends = shell_model.get_friends() if friends.has_buddy(self._buddy): - menu_item = MenuItem(_('Remove friend'), 'stock-remove') + menu_item = MenuItem(_('Remove friend'), 'list-remove') menu_item.connect('activate', self._remove_friend_cb) else: - menu_item = MenuItem(_('Make friend'), 'stock-add') + menu_item = MenuItem(_('Make friend'), 'list-add') menu_item.connect('activate', self._make_friend_cb) self.menu.append(menu_item) diff --git a/shell/view/clipboardmenu.py b/shell/view/clipboardmenu.py index 3acf90ee..7b0c52a8 100644 --- a/shell/view/clipboardmenu.py +++ b/shell/view/clipboardmenu.py @@ -63,12 +63,12 @@ class ClipboardMenu(Palette): self.append(self._preview_text) """ - self._remove_item = MenuItem(_('Remove'), 'stock-remove') + self._remove_item = MenuItem(_('Remove'), 'list-remove') self._remove_item.connect('activate', self._remove_item_activate_cb) self.menu.append(self._remove_item) self._remove_item.show() - self._open_item = MenuItem(_('Open'), 'stock-keep') + self._open_item = MenuItem(_('Open')) self._open_item_activate_sid = self._open_item.connect('activate', self._open_item_activate_cb) self.menu.append(self._open_item) diff --git a/shell/view/devices/network/wired.py b/shell/view/devices/network/wired.py index e2b9ce3a..662c672d 100644 --- a/shell/view/devices/network/wired.py +++ b/shell/view/devices/network/wired.py @@ -19,4 +19,4 @@ from view.devices import deviceview class DeviceView(deviceview.DeviceView): def __init__(self, model): deviceview.DeviceView.__init__(self, model) - self.props.icon_name = 'theme:stock-net-wired' + self.props.icon_name = 'theme:network-wired' diff --git a/shell/view/home/MyIcon.py b/shell/view/home/MyIcon.py index 2168b0b5..f4013b97 100644 --- a/shell/view/home/MyIcon.py +++ b/shell/view/home/MyIcon.py @@ -20,5 +20,5 @@ from sugar import profile class MyIcon(CanvasIcon): def __init__(self, size): CanvasIcon.__init__(self, size=size, - icon_name='theme:stock-buddy', + icon_name='theme:xo', xo_color=profile.get_color()) diff --git a/sugar/graphics/objectchooser.py b/sugar/graphics/objectchooser.py index 5b09e13d..46739f69 100644 --- a/sugar/graphics/objectchooser.py +++ b/sugar/graphics/objectchooser.py @@ -150,7 +150,7 @@ class CollapsedEntry(CanvasRoundBox): self._icon_name = type.icon if not self._icon_name: - self._icon_name = 'theme:stock-missing' + self._icon_name = 'theme:image-missing' return self._icon_name diff --git a/tests/test-snowflake-layout.py b/tests/test-snowflake-layout.py index 279f6388..bf3e69e3 100755 --- a/tests/test-snowflake-layout.py +++ b/tests/test-snowflake-layout.py @@ -37,12 +37,12 @@ def add_snowflake(parent, size): box.set_layout(layout) icon = CanvasIcon(scale=0.8, xo_color=XoColor(), - icon_name='theme:object-link') + icon_name='theme:xo') layout.add_center(icon) for k in range(0, size): icon = CanvasIcon(scale=0.4, xo_color=XoColor(), - icon_name='theme:stock-buddy') + icon_name='theme:xo') layout.add(icon) window = gtk.Window() diff --git a/tests/test-spread-layout.py b/tests/test-spread-layout.py index 412d7fca..7d123158 100755 --- a/tests/test-spread-layout.py +++ b/tests/test-spread-layout.py @@ -35,7 +35,7 @@ def _create_icon(): scale = 1.0 + random.random() * 1.5 icon = CanvasIcon(scale=scale, xo_color=color, - icon_name='theme:stock-buddy') + icon_name='theme:xo') icon.set_tooltip('Test') layout.add(icon)