From c9a3fc6edc3c768b86726ae2c769a12922a7d118 Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso Date: Wed, 22 Oct 2008 14:02:24 +0000 Subject: Fix palettes in the favorites view --- diff --git a/src/jarabe/desktop/favoritesview.py b/src/jarabe/desktop/favoritesview.py index 4c840dd..855c4b6 100644 --- a/src/jarabe/desktop/favoritesview.py +++ b/src/jarabe/desktop/favoritesview.py @@ -283,17 +283,11 @@ class FavoritesView(hippo.Canvas): self._layout = LAYOUT_MAP[layout]() self._box.set_layout(self._layout) - - #TODO: compatibility hack while sort() gets added to the hippo - # python bindings + + #TODO: compatibility hack while sort() gets added to the hippo python + # bindings if hasattr(self._box, 'sort'): self._box.sort(self._layout.compare_activities) - else: - icons = self._box.get_children() - self._box.clear() - for icon in icons: - self._box.insert_sorted( - icon, 0, self._layout.compare_activities) for icon in self._box.get_children(): if icon not in [self._my_icon, self._current_activity]: @@ -435,7 +429,7 @@ class CurrentActivityIcon(CanvasIcon, hippo.CanvasItem): self.palette = None def create_palette(self): - if home_activity.is_journal(): + if self._home_activity.is_journal(): palette = JournalPalette(self._home_activity) else: palette = CurrentActivityPalette(self._home_activity) -- cgit v0.9.1