[Sugar-devel] [PATCH sugar v2 04/21] PEP8 cleanup: fix spaces around operators and parentheses

Sascha Silbe sascha-pgp at silbe.org
Fri Nov 19 16:13:12 EST 2010


Reviewed-by: James Cameron <quozl at laptop.org>
CC: Aleksey Lim <alsroot at member.fsf.org>
Signed-off-by: Sascha Silbe <sascha-pgp at silbe.org>

diff --git a/extensions/cpsection/aboutme/model.py b/extensions/cpsection/aboutme/model.py
index fd7261c..3bb96d5 100644
--- a/extensions/cpsection/aboutme/model.py
+++ b/extensions/cpsection/aboutme/model.py
@@ -19,13 +19,14 @@ from gettext import gettext as _
 import gconf
 
 
-_COLORS = {'red': {'dark':'#b20008', 'medium':'#e6000a', 'light':'#ffadce'},
-           'orange': {'dark':'#9a5200', 'medium':'#c97e00', 'light':'#ffc169'},
-           'yellow': {'dark':'#807500', 'medium':'#be9e00', 'light':'#fffa00'},
-           'green': {'dark':'#008009', 'medium':'#00b20d', 'light':'#8bff7a'},
-           'blue': {'dark':'#00588c', 'medium':'#005fe4', 'light':'#bccdff'},
-           'purple': {'dark':'#5e008c', 'medium':'#7f00bf', 'light':'#d1a3ff'}
-           }
+_COLORS = {
+    'red': {'dark': '#b20008', 'medium': '#e6000a', 'light': '#ffadce'},
+    'orange': {'dark': '#9a5200', 'medium': '#c97e00', 'light': '#ffc169'},
+    'yellow': {'dark': '#807500', 'medium': '#be9e00', 'light': '#fffa00'},
+    'green': {'dark': '#008009', 'medium': '#00b20d', 'light': '#8bff7a'},
+    'blue': {'dark': '#00588c', 'medium': '#005fe4', 'light': '#bccdff'},
+    'purple': {'dark': '#5e008c', 'medium': '#7f00bf', 'light': '#d1a3ff'},
+}
 
 _MODIFIERS = ('dark', 'medium', 'light')
 
diff --git a/extensions/cpsection/aboutme/view.py b/extensions/cpsection/aboutme/view.py
index 95314a1..69f212a 100644
--- a/extensions/cpsection/aboutme/view.py
+++ b/extensions/cpsection/aboutme/view.py
@@ -96,7 +96,7 @@ def _next_index(current_index):
 def _previous_index(current_index):
     previous_index = current_index - 1
     if previous_index < 0:
-        previous_index = len(colors)-1
+        previous_index = len(colors) - 1
     return previous_index
 
 
@@ -131,7 +131,7 @@ class ColorPicker(EventIcon):
     __gsignals__ = {
         'color-changed': (gobject.SIGNAL_RUN_FIRST,
                           gobject.TYPE_NONE,
-                          ([object]))
+                          ([object])),
         }
 
     def __init__(self, picker):
@@ -184,12 +184,12 @@ class AboutMe(SectionView):
         self._color_alert = None
 
         self._pickers = {
-                _PREVIOUS_FILL_COLOR: ColorPicker(_PREVIOUS_FILL_COLOR),
-                _NEXT_FILL_COLOR: ColorPicker(_NEXT_FILL_COLOR),
-                _CURRENT_COLOR: ColorPicker(_CURRENT_COLOR),
-                _NEXT_STROKE_COLOR: ColorPicker(_NEXT_STROKE_COLOR),
-                _PREVIOUS_STROKE_COLOR: ColorPicker(_PREVIOUS_STROKE_COLOR)
-                }
+            _PREVIOUS_FILL_COLOR: ColorPicker(_PREVIOUS_FILL_COLOR),
+            _NEXT_FILL_COLOR: ColorPicker(_NEXT_FILL_COLOR),
+            _CURRENT_COLOR: ColorPicker(_CURRENT_COLOR),
+            _NEXT_STROKE_COLOR: ColorPicker(_NEXT_STROKE_COLOR),
+            _PREVIOUS_STROKE_COLOR: ColorPicker(_PREVIOUS_STROKE_COLOR),
+        }
 
         self._setup_color()
         initial_color = XoColor(self._model.get_color_xo())
diff --git a/extensions/cpsection/datetime/model.py b/extensions/cpsection/datetime/model.py
index 39d5e5e..0a68fd7 100644
--- a/extensions/cpsection/datetime/model.py
+++ b/extensions/cpsection/datetime/model.py
@@ -39,7 +39,7 @@ def _initialize():
 
 
 def read_all_timezones(fn=_zone_tab):
-    fd = open (fn, 'r')
+    fd = open(fn, 'r')
     lines = fd.readlines()
     fd.close()
     timezones = []
diff --git a/extensions/cpsection/frame/view.py b/extensions/cpsection/frame/view.py
index fb2b6b7..5c9d473 100644
--- a/extensions/cpsection/frame/view.py
+++ b/extensions/cpsection/frame/view.py
@@ -24,7 +24,7 @@ from jarabe.controlpanel.sectionview import SectionView
 from jarabe.controlpanel.inlinealert import InlineAlert
 
 
-_never =  _('never')
+_never = _('never')
 _instantaneous = _('instantaneous')
 _seconds_label = _('%s seconds')
 _MAX_DELAY = 1000
diff --git a/extensions/cpsection/keyboard/view.py b/extensions/cpsection/keyboard/view.py
index 51062fd..fe3ca15 100644
--- a/extensions/cpsection/keyboard/view.py
+++ b/extensions/cpsection/keyboard/view.py
@@ -47,8 +47,8 @@ class LayoutCombo(gtk.HBox):
     """
 
     __gsignals__ = {
-        'selection-changed' : (gobject.SIGNAL_RUN_LAST, gobject.TYPE_NONE,
-                            (gobject.TYPE_STRING, gobject.TYPE_INT))
+        'selection-changed': (gobject.SIGNAL_RUN_LAST, gobject.TYPE_NONE,
+                              (gobject.TYPE_STRING, gobject.TYPE_INT)),
         }
 
     def __init__(self, keyboard_manager, n):
@@ -59,7 +59,7 @@ class LayoutCombo(gtk.HBox):
         self.set_border_width(style.DEFAULT_SPACING)
         self.set_spacing(style.DEFAULT_SPACING)
 
-        label = gtk.Label(' <b>%s</b> ' % str(n+1))
+        label = gtk.Label(' <b>%s</b> ' % str(n + 1))
         label.set_use_markup(True)
         label.modify_fg(gtk.STATE_NORMAL,
                     style.COLOR_SELECTION_GREY.get_gdk_color())
@@ -71,7 +71,7 @@ class LayoutCombo(gtk.HBox):
         for description, name in self._keyboard_manager.get_languages():
             self._klang_store.append([name, description])
 
-        self._klang_combo = gtk.ComboBox(model = self._klang_store)
+        self._klang_combo = gtk.ComboBox(model=self._klang_store)
         self._klang_combo_changed_id = \
             self._klang_combo.connect('changed', self._klang_combo_changed_cb)
         cell = gtk.CellRendererText()
@@ -79,10 +79,10 @@ class LayoutCombo(gtk.HBox):
         cell.props.ellipsize_set = True
         self._klang_combo.pack_start(cell)
         self._klang_combo.add_attribute(cell, 'text', 1)
-        self.pack_start(self._klang_combo, expand=True, fill = True)
+        self.pack_start(self._klang_combo, expand=True, fill=True)
 
         self._kvariant_store = None
-        self._kvariant_combo = gtk.ComboBox(model = None)
+        self._kvariant_combo = gtk.ComboBox(model=None)
         self._kvariant_combo_changed_id = \
             self._kvariant_combo.connect('changed', \
                                 self._kvariant_combo_changed_cb)
@@ -91,7 +91,7 @@ class LayoutCombo(gtk.HBox):
         cell.props.ellipsize_set = True
         self._kvariant_combo.pack_start(cell)
         self._kvariant_combo.add_attribute(cell, 'text', 1)
-        self.pack_start(self._kvariant_combo, expand=True, fill = True)
+        self.pack_start(self._kvariant_combo, expand=True, fill=True)
 
         self._klang_combo.set_active(self._index)
 
@@ -157,8 +157,7 @@ class Keyboard(SectionView):
         self.set_border_width(style.DEFAULT_SPACING * 2)
         self.set_spacing(style.DEFAULT_SPACING)
 
-        self._layout_table = gtk.Table(rows = 4, columns = 2, \
-                                                homogeneous = False)
+        self._layout_table = gtk.Table(rows=4, columns=2, homogeneous=False)
 
         self._keyboard_manager = model.KeyboardManager(self.get_display())
         self._layout_combo_list = []
@@ -202,7 +201,7 @@ class Keyboard(SectionView):
         for description, name in self._keyboard_manager.get_models():
             kmodel_store.append([name, description])
 
-        kmodel_combo = gtk.ComboBox(model = kmodel_store)
+        kmodel_combo = gtk.ComboBox(model=kmodel_store)
         cell = gtk.CellRendererText()
         cell.props.ellipsize = pango.ELLIPSIZE_MIDDLE
         cell.props.ellipsize_set = True
@@ -216,7 +215,7 @@ class Keyboard(SectionView):
                     kmodel_combo.set_active_iter(row.iter)
                     break
 
-        box_kmodel.pack_start(kmodel_combo, expand = False)
+        box_kmodel.pack_start(kmodel_combo, expand=False)
         self._vbox.pack_start(box_kmodel, expand=False)
         box_kmodel.show_all()
 
@@ -261,7 +260,7 @@ class Keyboard(SectionView):
         for description, name in self._keyboard_manager.get_options_group():
             group_option_store.append([name, description])
 
-        group_option_combo = gtk.ComboBox(model = group_option_store)
+        group_option_combo = gtk.ComboBox(model=group_option_store)
         cell = gtk.CellRendererText()
         cell.props.ellipsize = pango.ELLIPSIZE_MIDDLE
         cell.props.ellipsize_set = True
@@ -282,7 +281,7 @@ class Keyboard(SectionView):
             if not found:
                 group_option_combo.set_active(0)
 
-        box_group_option.pack_start(group_option_combo, expand = False)
+        box_group_option.pack_start(group_option_combo, expand=False)
         self._vbox.pack_start(box_group_option, expand=False)
         box_group_option.show_all()
 
@@ -325,13 +324,13 @@ class Keyboard(SectionView):
         for i in range(0, self._keyboard_manager.get_max_layouts()):
             add_remove_box = self.__create_add_remove_box()
             self._layout_addremovebox_list.append(add_remove_box)
-            self._layout_table.attach(add_remove_box, 1, 2, i, i+1)
+            self._layout_table.attach(add_remove_box, 1, 2, i, i + 1)
 
             layout_combo = LayoutCombo(self._keyboard_manager, i)
             layout_combo.connect('selection-changed', \
                 self.__layout_combo_selection_changed_cb)
             self._layout_combo_list.append(layout_combo)
-            self._layout_table.attach(layout_combo, 0, 1, i, i+1)
+            self._layout_table.attach(layout_combo, 0, 1, i, i + 1)
 
             if i < len(self._klayouts):
                 layout_combo.show_all()
@@ -361,14 +360,14 @@ class Keyboard(SectionView):
 
     def __create_add_remove_box(self):
         '''Creates gtk.Hbox with add/remove buttons'''
-        add_icon =  Icon(icon_name='list-add')
+        add_icon = Icon(icon_name='list-add')
 
         add_button = gtk.Button()
         add_button.set_image(add_icon)
         add_button.connect('clicked',
                             self.__add_button_clicked_cb)
 
-        remove_icon =  Icon(icon_name='list-remove')
+        remove_icon = Icon(icon_name='list-remove')
         remove_button = gtk.Button()
         remove_button.set_image(remove_icon)
         remove_button.connect('clicked',
diff --git a/extensions/cpsection/language/view.py b/extensions/cpsection/language/view.py
index 3a1f1a5..1bd77f8 100644
--- a/extensions/cpsection/language/view.py
+++ b/extensions/cpsection/language/view.py
@@ -181,14 +181,14 @@ class Language(SectionView):
 
     def _create_add_remove_box(self):
         '''Creates gtk.Hbox with add/remove buttons'''
-        add_icon =  Icon(icon_name='list-add')
+        add_icon = Icon(icon_name='list-add')
 
         add_button = gtk.Button()
         add_button.set_image(add_icon)
         add_button.connect('clicked',
                             self.__add_button_clicked_cb)
 
-        remove_icon =  Icon(icon_name='list-remove')
+        remove_icon = Icon(icon_name='list-remove')
         remove_button = gtk.Button()
         remove_button.set_image(remove_icon)
         remove_button.connect('clicked',
@@ -217,7 +217,7 @@ class Language(SectionView):
         selected_langs = self._get_selected_langs()
         last_lang = selected_langs[-1]
 
-        self._determine_add_remove_visibility(last_lang = last_lang)
+        self._determine_add_remove_visibility(last_lang=last_lang)
 
         self._changed = (selected_langs != self._selected_locales)
 
@@ -248,7 +248,7 @@ class Language(SectionView):
 
         return new_codes
 
-    def _determine_add_remove_visibility(self, last_lang = None):
+    def _determine_add_remove_visibility(self, last_lang=None):
         # We should not let users add fallback languages for English (USA)
         # This is because the software is not usually _translated_ into English
         # which means that the fallback gets selected automatically
diff --git a/extensions/deviceicon/battery.py b/extensions/deviceicon/battery.py
index c1c920b..e947ccc 100644
--- a/extensions/deviceicon/battery.py
+++ b/extensions/deviceicon/battery.py
@@ -161,14 +161,10 @@ class BatteryPalette(Palette):
 
 class DeviceModel(gobject.GObject):
     __gproperties__ = {
-        'level'       : (int, None, None, 0, 100, 0,
-                         gobject.PARAM_READABLE),
-        'charging'    : (bool, None, None, False,
-                         gobject.PARAM_READABLE),
-        'discharging' : (bool, None, None, False,
-                         gobject.PARAM_READABLE),
-        'present'     : (bool, None, None, False,
-                         gobject.PARAM_READABLE)
+        'level': (int, None, None, 0, 100, 0, gobject.PARAM_READABLE),
+        'charging': (bool, None, None, False, gobject.PARAM_READABLE),
+        'discharging': (bool, None, None, False, gobject.PARAM_READABLE),
+        'present': (bool, None, None, False, gobject.PARAM_READABLE),
     }
 
     def __init__(self, udi):
diff --git a/extensions/deviceicon/network.py b/extensions/deviceicon/network.py
index 55e334f..d5333af 100644
--- a/extensions/deviceicon/network.py
+++ b/extensions/deviceicon/network.py
@@ -74,8 +74,8 @@ class WirelessPalette(Palette):
     __gtype_name__ = 'SugarWirelessPalette'
 
     __gsignals__ = {
-        'deactivate-connection' : (gobject.SIGNAL_RUN_FIRST,
-                                   gobject.TYPE_NONE, ([]))
+        'deactivate-connection': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                                  ([])),
     }
 
     def __init__(self, primary_text):
@@ -205,10 +205,8 @@ class GsmPalette(Palette):
     __gtype_name__ = 'SugarGsmPalette'
 
     __gsignals__ = {
-        'gsm-connect'         : (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([])),
-        'gsm-disconnect'      : (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([])),
+        'gsm-connect': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
+        'gsm-disconnect': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self):
diff --git a/extensions/deviceicon/speaker.py b/extensions/deviceicon/speaker.py
index ae84036..cb01629 100644
--- a/extensions/deviceicon/speaker.py
+++ b/extensions/deviceicon/speaker.py
@@ -172,8 +172,8 @@ class SpeakerPalette(Palette):
 
 class DeviceModel(gobject.GObject):
     __gproperties__ = {
-        'level'   : (int, None, None, 0, 100, 0, gobject.PARAM_READWRITE),
-        'muted'   : (bool, None, None, False, gobject.PARAM_READWRITE),
+        'level': (int, None, None, 0, 100, 0, gobject.PARAM_READWRITE),
+        'muted': (bool, None, None, False, gobject.PARAM_READWRITE),
     }
 
     def __init__(self):
diff --git a/src/jarabe/controlpanel/gui.py b/src/jarabe/controlpanel/gui.py
index 4e2cbd1..4fa030b 100644
--- a/src/jarabe/controlpanel/gui.py
+++ b/src/jarabe/controlpanel/gui.py
@@ -368,14 +368,10 @@ class _SectionIcon(gtk.EventBox):
     __gtype_name__ = "SugarSectionIcon"
 
     __gproperties__ = {
-        'icon-name'    : (str, None, None, None,
-                          gobject.PARAM_READWRITE),
-        'pixel-size'   : (object, None, None,
-                          gobject.PARAM_READWRITE),
-        'xo-color'     : (object, None, None,
-                          gobject.PARAM_READWRITE),
-        'title'        : (str, None, None, None,
-                          gobject.PARAM_READWRITE)
+        'icon-name': (str, None, None, None, gobject.PARAM_READWRITE),
+        'pixel-size': (object, None, None, gobject.PARAM_READWRITE),
+        'xo-color': (object, None, None, gobject.PARAM_READWRITE),
+        'title': (str, None, None, None, gobject.PARAM_READWRITE),
     }
 
     def __init__(self, **kwargs):
diff --git a/src/jarabe/controlpanel/inlinealert.py b/src/jarabe/controlpanel/inlinealert.py
index 9c08c62..f970af4 100644
--- a/src/jarabe/controlpanel/inlinealert.py
+++ b/src/jarabe/controlpanel/inlinealert.py
@@ -37,11 +37,9 @@ class InlineAlert(gtk.HBox):
     __gtype_name__ = 'SugarInlineAlert'
 
     __gproperties__ = {
-        'msg'    : (str, None, None, None,
-                    gobject.PARAM_READWRITE),
-        'icon'   : (object, None, None,
-                    gobject.PARAM_WRITABLE)
-        }
+        'msg': (str, None, None, None, gobject.PARAM_READWRITE),
+        'icon': (object, None, None, gobject.PARAM_WRITABLE),
+    }
 
     def __init__(self, **kwargs):
 
diff --git a/src/jarabe/controlpanel/sectionview.py b/src/jarabe/controlpanel/sectionview.py
index 5b44161..edef59f 100644
--- a/src/jarabe/controlpanel/sectionview.py
+++ b/src/jarabe/controlpanel/sectionview.py
@@ -23,14 +23,12 @@ class SectionView(gtk.VBox):
     __gtype_name__ = 'SugarSectionView'
 
     __gsignals__ = {
-        'request-close': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE, ([]))
-        }
+        'request-close': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
+    }
 
     __gproperties__ = {
-        'is_valid'      : (bool, None, None, True,
-                           gobject.PARAM_READWRITE)
-        }
+        'is_valid': (bool, None, None, True, gobject.PARAM_READWRITE),
+    }
 
     _APPLY_TIMEOUT = 1000
 
diff --git a/src/jarabe/controlpanel/toolbar.py b/src/jarabe/controlpanel/toolbar.py
index 72b1be3..fca34a0 100644
--- a/src/jarabe/controlpanel/toolbar.py
+++ b/src/jarabe/controlpanel/toolbar.py
@@ -37,7 +37,7 @@ class MainToolbar(gtk.Toolbar):
                             ([])),
         'search-changed': (gobject.SIGNAL_RUN_FIRST,
                           gobject.TYPE_NONE,
-                          ([str]))
+                          ([str])),
     }
 
     def __init__(self):
@@ -97,7 +97,7 @@ class SectionToolbar(gtk.Toolbar):
                             ([])),
         'accept-clicked': (gobject.SIGNAL_RUN_FIRST,
                             gobject.TYPE_NONE,
-                            ([]))
+                            ([])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/desktop/activitieslist.py b/src/jarabe/desktop/activitieslist.py
index 9476370..4a92ed6 100644
--- a/src/jarabe/desktop/activitieslist.py
+++ b/src/jarabe/desktop/activitieslist.py
@@ -43,8 +43,8 @@ class ActivitiesTreeView(gtk.TreeView):
     __gtype_name__ = 'SugarActivitiesTreeView'
 
     __gsignals__ = {
-        'erase-activated' : (gobject.SIGNAL_RUN_FIRST,
-                             gobject.TYPE_NONE, ([str]))
+        'erase-activated': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                            ([str])),
     }
 
     def __init__(self):
@@ -260,8 +260,8 @@ class CellRendererActivityIcon(CellRendererIcon):
     __gtype_name__ = 'SugarCellRendererActivityIcon'
 
     __gsignals__ = {
-        'erase-activated' : (gobject.SIGNAL_RUN_FIRST,
-                             gobject.TYPE_NONE, ([str]))
+        'erase-activated': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                            ([str])),
     }
 
     def __init__(self, tree_view):
@@ -383,8 +383,8 @@ class ActivityListPalette(ActivityPalette):
     __gtype_name__ = 'SugarActivityListPalette'
 
     __gsignals__ = {
-        'erase-activated' : (gobject.SIGNAL_RUN_FIRST,
-                             gobject.TYPE_NONE, ([str]))
+        'erase-activated': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                            ([str])),
     }
 
     def __init__(self, activity_info):
diff --git a/src/jarabe/desktop/favoriteslayout.py b/src/jarabe/desktop/favoriteslayout.py
index 433dd2d..e03e30b 100644
--- a/src/jarabe/desktop/favoriteslayout.py
+++ b/src/jarabe/desktop/favoriteslayout.py
@@ -439,7 +439,7 @@ class SunflowerLayout(RingLayout):
             # removed to make room for the "active activity" icon.
             x = r * cos(phi) + (width - icon_size) / 2
             y = r * sin(phi) + (height - icon_size - \
-                                (style.GRID_CELL_SIZE / 2) ) / 2
+                                (style.GRID_CELL_SIZE / 2)) / 2
 
             # skip allocations outside the allocation box.
             # give up once we can't fit
@@ -489,9 +489,9 @@ class BoxLayout(RingLayout):
         cos = lambda r: cos_d(math.degrees(r))
         sin = lambda r: cos_d(math.degrees(r) - 90)
 
-        return RingLayout._calculate_position\
-               (self, radius, icon_size, index, children_count,
-                sin=sin, cos=cos)
+        return RingLayout._calculate_position(self, radius, icon_size, index,
+                                              children_count, sin=sin,
+                                              cos=cos)
 
 
 class TriangleLayout(RingLayout):
@@ -547,6 +547,6 @@ class TriangleLayout(RingLayout):
         cos = lambda r: cos_d(math.degrees(r))
         sin = lambda r: sin_d(math.degrees(r))
 
-        return RingLayout._calculate_position\
-               (self, radius, icon_size, index, children_count,
-                sin=sin, cos=cos)
+        return RingLayout._calculate_position(self, radius, icon_size, index,
+                                              children_count, sin=sin,
+                                              cos=cos)
diff --git a/src/jarabe/desktop/favoritesview.py b/src/jarabe/desktop/favoritesview.py
index 08c3675..a121a9c 100644
--- a/src/jarabe/desktop/favoritesview.py
+++ b/src/jarabe/desktop/favoritesview.py
@@ -206,9 +206,9 @@ class FavoritesView(hippo.Canvas):
             icon_x, icon_y = icon.get_context().translate_to_widget(icon)
             icon_width, icon_height = icon.get_allocation()
 
-            if (x >= icon_x ) and (x <= icon_x + icon_width) and \
-                    (y >= icon_y ) and (y <= icon_y + icon_height) and \
-                    isinstance(icon, ActivityIcon):
+            if (x >= icon_x) and (x <= icon_x + icon_width) and \
+               (y >= icon_y) and (y <= icon_y + icon_height) and \
+               isinstance(icon, ActivityIcon)):
                 return icon
         return None
 
@@ -603,8 +603,8 @@ class OwnerIcon(BuddyIcon):
     __gtype_name__ = 'SugarFavoritesOwnerIcon'
 
     __gsignals__ = {
-        'register-activate' : (gobject.SIGNAL_RUN_FIRST,
-                                gobject.TYPE_NONE, ([]))
+        'register-activate': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                              ([])),
     }
 
     def __init__(self, size):
diff --git a/src/jarabe/desktop/grid.py b/src/jarabe/desktop/grid.py
index 319ff38..cdba238 100644
--- a/src/jarabe/desktop/grid.py
+++ b/src/jarabe/desktop/grid.py
@@ -31,9 +31,8 @@ _MAX_COLLISIONS_PER_REFRESH = 20
 
 class Grid(_sugarext.Grid):
     __gsignals__ = {
-        'child-changed' : (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
-                           ([gobject.TYPE_PYOBJECT]))
+        'child-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([gobject.TYPE_PYOBJECT])),
     }
 
     def __init__(self, width, height):
diff --git a/src/jarabe/desktop/homebox.py b/src/jarabe/desktop/homebox.py
index beaaf41..b19d562 100644
--- a/src/jarabe/desktop/homebox.py
+++ b/src/jarabe/desktop/homebox.py
@@ -59,7 +59,7 @@ class HomeBox(gtk.VBox):
     def show_software_updates_alert(self):
         alert = Alert()
         updater_icon = Icon(icon_name='module-updater',
-                    pixel_size = style.STANDARD_ICON_SIZE)
+                            pixel_size=style.STANDARD_ICON_SIZE)
         alert.props.icon = updater_icon
         updater_icon.show()
         alert.props.title = _('Software Update')
@@ -151,12 +151,10 @@ class HomeToolbar(gtk.Toolbar):
     __gtype_name__ = 'SugarHomeToolbar'
 
     __gsignals__ = {
-        'query-changed': (gobject.SIGNAL_RUN_FIRST,
-                          gobject.TYPE_NONE,
+        'query-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                           ([str])),
-        'view-changed':  (gobject.SIGNAL_RUN_FIRST,
-                          gobject.TYPE_NONE,
-                          ([object]))
+        'view-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([object])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/desktop/homewindow.py b/src/jarabe/desktop/homewindow.py
index a2ea688..b0f648a 100644
--- a/src/jarabe/desktop/homewindow.py
+++ b/src/jarabe/desktop/homewindow.py
@@ -29,9 +29,9 @@ from jarabe.model.shell import ShellModel
 from jarabe.model import shell
 
 
-_HOME_PAGE       = 0
-_GROUP_PAGE      = 1
-_MESH_PAGE       = 2
+_HOME_PAGE = 0
+_GROUP_PAGE = 1
+_MESH_PAGE = 2
 _TRANSITION_PAGE = 3
 
 _instance = None
diff --git a/src/jarabe/desktop/keydialog.py b/src/jarabe/desktop/keydialog.py
index 63099e2..35b35e6 100644
--- a/src/jarabe/desktop/keydialog.py
+++ b/src/jarabe/desktop/keydialog.py
@@ -26,7 +26,7 @@ from jarabe.model.network import Secrets
 
 
 IW_AUTH_ALG_OPEN_SYSTEM = 'open'
-IW_AUTH_ALG_SHARED_KEY  = 'shared'
+IW_AUTH_ALG_SHARED_KEY = 'shared'
 
 WEP_PASSPHRASE = 1
 WEP_HEX = 2
diff --git a/src/jarabe/desktop/meshbox.py b/src/jarabe/desktop/meshbox.py
index ededa6d..aa32b9c 100644
--- a/src/jarabe/desktop/meshbox.py
+++ b/src/jarabe/desktop/meshbox.py
@@ -157,9 +157,8 @@ class MeshToolbar(gtk.Toolbar):
     __gtype_name__ = 'MeshToolbar'
 
     __gsignals__ = {
-        'query-changed': (gobject.SIGNAL_RUN_FIRST,
-                          gobject.TYPE_NONE,
-                          ([str]))
+        'query-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([str])),
     }
 
     def __init__(self):
@@ -227,7 +226,7 @@ class DeviceObserver(gobject.GObject):
         'access-point-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                                ([gobject.TYPE_PYOBJECT])),
         'access-point-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                                 ([gobject.TYPE_PYOBJECT]))
+                                 ([gobject.TYPE_PYOBJECT])),
     }
 
     def __init__(self, device):
diff --git a/src/jarabe/desktop/schoolserver.py b/src/jarabe/desktop/schoolserver.py
index 8dc7d71..5388466 100644
--- a/src/jarabe/desktop/schoolserver.py
+++ b/src/jarabe/desktop/schoolserver.py
@@ -40,7 +40,7 @@ def generate_serial_number():
 
     serial_part1 = []
 
-    for y_ in range(3) :
+    for y_ in range(3):
         serial_part1.append(random.choice(ascii_uppercase))
 
     serial_part1 = ''.join(serial_part1)
diff --git a/src/jarabe/desktop/transitionbox.py b/src/jarabe/desktop/transitionbox.py
index 184f62c..4042044 100644
--- a/src/jarabe/desktop/transitionbox.py
+++ b/src/jarabe/desktop/transitionbox.py
@@ -68,8 +68,7 @@ class TransitionBox(hippo.Canvas):
     __gtype_name__ = 'SugarTransitionBox'
 
     __gsignals__ = {
-        'completed': (gobject.SIGNAL_RUN_FIRST,
-                      gobject.TYPE_NONE, ([]))
+        'completed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/frame/activitiestray.py b/src/jarabe/frame/activitiestray.py
index 05891b4..6d4d875 100644
--- a/src/jarabe/frame/activitiestray.py
+++ b/src/jarabe/frame/activitiestray.py
@@ -473,8 +473,7 @@ class BaseTransferPalette(Palette):
     __gtype_name__ = "SugarBaseTransferPalette"
 
     __gsignals__ = {
-        'dismiss-clicked':          (gobject.SIGNAL_RUN_FIRST,
-                                     gobject.TYPE_NONE, ([])),
+        'dismiss-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self, file_transfer):
diff --git a/src/jarabe/frame/clipboard.py b/src/jarabe/frame/clipboard.py
index 8e237dd..95ae192 100644
--- a/src/jarabe/frame/clipboard.py
+++ b/src/jarabe/frame/clipboard.py
@@ -38,7 +38,7 @@ class Clipboard(gobject.GObject):
         'object-deleted': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                         ([int])),
         'object-state-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                        ([object]))
+                        ([object])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/frame/clipboardtray.py b/src/jarabe/frame/clipboardtray.py
index 40a1f65..1c06552 100644
--- a/src/jarabe/frame/clipboardtray.py
+++ b/src/jarabe/frame/clipboardtray.py
@@ -156,7 +156,7 @@ class ClipboardTray(tray.VTray):
         if 'XdndDirectSave0' in context.targets:
             window = context.source_window
             prop_type, format_, filename = \
-                window.property_get('XdndDirectSave0','text/plain')
+                window.property_get('XdndDirectSave0', 'text/plain')
 
             # FIXME query the clipboard service for a filename?
             base_dir = tempfile.gettempdir()
diff --git a/src/jarabe/frame/eventarea.py b/src/jarabe/frame/eventarea.py
index cdd6f97..af6f1b6 100644
--- a/src/jarabe/frame/eventarea.py
+++ b/src/jarabe/frame/eventarea.py
@@ -25,10 +25,8 @@ _MAX_DELAY = 1000
 
 class EventArea(gobject.GObject):
     __gsignals__ = {
-        'enter': (gobject.SIGNAL_RUN_FIRST,
-                  gobject.TYPE_NONE, ([])),
-        'leave': (gobject.SIGNAL_RUN_FIRST,
-                  gobject.TYPE_NONE, ([]))
+        'enter': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
+        'leave': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self):
@@ -42,7 +40,7 @@ class EventArea(gobject.GObject):
         self._corner_delay = client.get_int('/desktop/sugar/frame/corner_delay')
 
         right = gtk.gdk.screen_width() - 1
-        bottom = gtk.gdk.screen_height() -1
+        bottom = gtk.gdk.screen_height() - 1
         width = gtk.gdk.screen_width() - 2
         height = gtk.gdk.screen_height() - 2
 
diff --git a/src/jarabe/frame/frame.py b/src/jarabe/frame/frame.py
index 39dd31e..933729c 100644
--- a/src/jarabe/frame/frame.py
+++ b/src/jarabe/frame/frame.py
@@ -96,7 +96,7 @@ class _KeyListener(object):
 
 
 class Frame(object):
-    MODE_MOUSE    = 0
+    MODE_MOUSE = 0
     MODE_KEYBOARD = 1
     MODE_NON_INTERACTIVE = 2
 
@@ -183,7 +183,7 @@ class Frame(object):
 
         zoom_toolbar = ZoomToolbar()
         panel.append(hippo.CanvasWidget(widget=zoom_toolbar,
-                box_width=4*style.GRID_CELL_SIZE))
+                box_width=4 * style.GRID_CELL_SIZE))
         zoom_toolbar.show()
 
         activities_tray = ActivitiesTray()
diff --git a/src/jarabe/frame/notification.py b/src/jarabe/frame/notification.py
index fceb41e..703cf2c 100644
--- a/src/jarabe/frame/notification.py
+++ b/src/jarabe/frame/notification.py
@@ -27,9 +27,9 @@ class NotificationIcon(gtk.EventBox):
     __gtype_name__ = 'SugarNotificationIcon'
 
     __gproperties__ = {
-        'xo-color'      : (object, None, None, gobject.PARAM_READWRITE),
-        'icon-name'     : (str, None, None, None, gobject.PARAM_READWRITE),
-        'icon-filename' : (str, None, None, None, gobject.PARAM_READWRITE)
+        'xo-color': (object, None, None, gobject.PARAM_READWRITE),
+        'icon-name': (str, None, None, None, gobject.PARAM_READWRITE),
+        'icon-filename': (str, None, None, None, gobject.PARAM_READWRITE),
     }
 
     _PULSE_TIMEOUT = 3
diff --git a/src/jarabe/intro/window.py b/src/jarabe/intro/window.py
index 4c8d224..168fbc5 100644
--- a/src/jarabe/intro/window.py
+++ b/src/jarabe/intro/window.py
@@ -45,7 +45,7 @@ def create_profile(name, color=None, pixbuf=None):
         color = XoColor()
 
     icon_path = os.path.join(env.get_profile_path(), "buddy-icon.jpg")
-    pixbuf.save(icon_path, "jpeg", {"quality":"85"})
+    pixbuf.save(icon_path, "jpeg", {"quality": "85"})
 
     client = gconf.client_get_default()
     client.set_string("/desktop/sugar/user/nick", name)
@@ -65,8 +65,7 @@ def create_profile(name, color=None, pixbuf=None):
 
 class _Page(hippo.CanvasBox):
     __gproperties__ = {
-        'valid'    : (bool, None, None, False,
-                      gobject.PARAM_READABLE)
+        'valid': (bool, None, None, False, gobject.PARAM_READABLE),
     }
 
     def __init__(self, **kwargs):
@@ -147,7 +146,7 @@ class _ColorPage(_Page):
 class _IntroBox(hippo.CanvasBox):
     __gsignals__ = {
         'done': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                 ([gobject.TYPE_PYOBJECT, gobject.TYPE_PYOBJECT]))
+                 ([gobject.TYPE_PYOBJECT, gobject.TYPE_PYOBJECT])),
     }
 
     PAGE_NAME = 0
diff --git a/src/jarabe/journal/detailview.py b/src/jarabe/journal/detailview.py
index 6a04a44..aa8c039 100644
--- a/src/jarabe/journal/detailview.py
+++ b/src/jarabe/journal/detailview.py
@@ -32,7 +32,7 @@ class DetailView(gtk.VBox):
     __gtype_name__ = 'DetailView'
 
     __gsignals__ = {
-        'go-back-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([]))
+        'go-back-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self, **kwargs):
diff --git a/src/jarabe/journal/journaltoolbox.py b/src/jarabe/journal/journaltoolbox.py
index 08c8b2f..39cd735 100644
--- a/src/jarabe/journal/journaltoolbox.py
+++ b/src/jarabe/journal/journaltoolbox.py
@@ -74,9 +74,8 @@ class SearchToolbar(gtk.Toolbar):
     __gtype_name__ = 'SearchToolbar'
 
     __gsignals__ = {
-        'query-changed': (gobject.SIGNAL_RUN_FIRST,
-                          gobject.TYPE_NONE,
-                          ([object]))
+        'query-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([object])),
         }
 
     def __init__(self):
@@ -369,9 +368,8 @@ class DetailToolbox(Toolbox):
 
 class EntryToolbar(gtk.Toolbar):
     __gsignals__ = {
-        'volume-error': (gobject.SIGNAL_RUN_FIRST,
-                         gobject.TYPE_NONE,
-                         ([str, str]))
+        'volume-error': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([str, str])),
         }
 
     def __init__(self):
diff --git a/src/jarabe/journal/listmodel.py b/src/jarabe/journal/listmodel.py
index fb50ea3..fb34c6a 100644
--- a/src/jarabe/journal/listmodel.py
+++ b/src/jarabe/journal/listmodel.py
@@ -39,12 +39,8 @@ class ListModel(gtk.GenericTreeModel, gtk.TreeDragSource):
     __gtype_name__ = 'JournalListModel'
 
     __gsignals__ = {
-        'ready':    (gobject.SIGNAL_RUN_FIRST,
-                     gobject.TYPE_NONE,
-                     ([])),
-        'progress': (gobject.SIGNAL_RUN_FIRST,
-                     gobject.TYPE_NONE,
-                     ([])),
+        'ready': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
+        'progress': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     COLUMN_UID = 0
@@ -60,18 +56,20 @@ class ListModel(gtk.GenericTreeModel, gtk.TreeDragSource):
     COLUMN_BUDDY_2 = 10
     COLUMN_BUDDY_3 = 11
 
-    _COLUMN_TYPES = {COLUMN_UID:            str,
-                     COLUMN_FAVORITE:       bool,
-                     COLUMN_ICON:           str,
-                     COLUMN_ICON_COLOR:     object,
-                     COLUMN_TITLE:          str,
-                     COLUMN_TIMESTAMP:      str,
-                     COLUMN_CREATION_TIME:  str,
-                     COLUMN_FILESIZE:       str,
-                     COLUMN_PROGRESS:       int,
-                     COLUMN_BUDDY_1:        object,
-                     COLUMN_BUDDY_3:        object,
-                     COLUMN_BUDDY_2:        object}
+    _COLUMN_TYPES = {
+        COLUMN_UID: str,
+        COLUMN_FAVORITE: bool,
+        COLUMN_ICON: str,
+        COLUMN_ICON_COLOR: object,
+        COLUMN_TITLE: str,
+        COLUMN_TIMESTAMP: str,
+        COLUMN_CREATION_TIME: str,
+        COLUMN_FILESIZE: str,
+        COLUMN_PROGRESS: int,
+        COLUMN_BUDDY_1: object,
+        COLUMN_BUDDY_3: object,
+        COLUMN_BUDDY_2: object,
+    }
 
     _PAGE_SIZE = 10
 
diff --git a/src/jarabe/journal/listview.py b/src/jarabe/journal/listview.py
index bca9f2c..b696931 100644
--- a/src/jarabe/journal/listview.py
+++ b/src/jarabe/journal/listview.py
@@ -65,9 +65,7 @@ class BaseListView(gtk.Bin):
     __gtype_name__ = 'JournalBaseListView'
 
     __gsignals__ = {
-        'clear-clicked': (gobject.SIGNAL_RUN_FIRST,
-                          gobject.TYPE_NONE,
-                          ([]))
+        'clear-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self):
@@ -373,8 +371,8 @@ class BaseListView(gtk.Bin):
 
         icon = CanvasIcon(size=style.LARGE_ICON_SIZE,
                           icon_name='activity-journal',
-                          stroke_color = style.COLOR_BUTTON_GREY.get_svg(),
-                          fill_color = style.COLOR_TRANSPARENT.get_svg())
+                          stroke_color=style.COLOR_BUTTON_GREY.get_svg(),
+                          fill_color=style.COLOR_TRANSPARENT.get_svg())
         box.append(icon)
 
         if message == MESSAGE_EMPTY_JOURNAL:
@@ -387,7 +385,7 @@ class BaseListView(gtk.Bin):
         text = hippo.CanvasText(text=text,
                 xalign=hippo.ALIGNMENT_CENTER,
                 font_desc=style.FONT_BOLD.get_pango_desc(),
-                color = style.COLOR_BUTTON_GREY.get_int())
+                color=style.COLOR_BUTTON_GREY.get_int())
         box.append(text)
 
         if message == MESSAGE_NO_MATCH:
@@ -468,9 +466,8 @@ class ListView(BaseListView):
     __gtype_name__ = 'JournalListView'
 
     __gsignals__ = {
-        'detail-clicked': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
-                           ([object]))
+        'detail-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([object])),
     }
 
     def __init__(self):
@@ -579,8 +576,7 @@ class CellRendererActivityIcon(CellRendererIcon):
     __gtype_name__ = 'JournalCellRendererActivityIcon'
 
     __gsignals__ = {
-        'detail-clicked': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
+        'detail-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                            ([str])),
     }
 
diff --git a/src/jarabe/journal/model.py b/src/jarabe/journal/model.py
index 4a9a8c8..c8aab18 100644
--- a/src/jarabe/journal/model.py
+++ b/src/jarabe/journal/model.py
@@ -81,7 +81,7 @@ class BaseResultSet(object):
     """
 
     def __init__(self, query, page_size):
-        self._total_count  = -1
+        self._total_count = -1
         self._position = -1
         self._query = query
         self._page_size = page_size
@@ -268,7 +268,7 @@ class InplaceResultSet(BaseResultSet):
             keygetter = itemgetter(2) # timestamp
         self._file_list.sort(lambda a, b: b - a,
                              key=keygetter,
-                             reverse=self._sort[0]=='-')
+                             reverse=(self._sort[0] == '-'))
         self.ready.send(self)
 
     def find(self, query):
@@ -281,7 +281,7 @@ class InplaceResultSet(BaseResultSet):
         t = time.time()
 
         offset = int(query.get('offset', 0))
-        limit  = int(query.get('limit', len(self._file_list)))
+        limit = int(query.get('limit', len(self._file_list)))
         total_count = len(self._file_list)
 
         files = self._file_list[offset:offset + limit]
diff --git a/src/jarabe/journal/objectchooser.py b/src/jarabe/journal/objectchooser.py
index 97139f8..ecb8ecf 100644
--- a/src/jarabe/journal/objectchooser.py
+++ b/src/jarabe/journal/objectchooser.py
@@ -35,9 +35,7 @@ class ObjectChooser(gtk.Window):
     __gtype_name__ = 'ObjectChooser'
 
     __gsignals__ = {
-        'response': (gobject.SIGNAL_RUN_FIRST,
-                     gobject.TYPE_NONE,
-                     ([int]))
+        'response': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([int])),
     }
 
     def __init__(self, parent=None, what_filter=''):
diff --git a/src/jarabe/journal/palettes.py b/src/jarabe/journal/palettes.py
index b2ecd1c..d341506 100644
--- a/src/jarabe/journal/palettes.py
+++ b/src/jarabe/journal/palettes.py
@@ -41,8 +41,7 @@ class ObjectPalette(Palette):
     __gtype_name__ = 'ObjectPalette'
 
     __gsignals__ = {
-        'detail-clicked': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
+        'detail-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                            ([str])),
     }
 
@@ -160,8 +159,8 @@ class FriendsMenu(gtk.Menu):
     __gtype_name__ = 'JournalFriendsMenu'
 
     __gsignals__ = {
-        'friend-selected'  : (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                              ([object])),
+        'friend-selected': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                            ([object])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/journal/volumestoolbar.py b/src/jarabe/journal/volumestoolbar.py
index d4caade..45346ba 100644
--- a/src/jarabe/journal/volumestoolbar.py
+++ b/src/jarabe/journal/volumestoolbar.py
@@ -35,12 +35,10 @@ class VolumesToolbar(gtk.Toolbar):
     __gtype_name__ = 'VolumesToolbar'
 
     __gsignals__ = {
-        'volume-changed': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
+        'volume-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                            ([str])),
-        'volume-error': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
-                           ([str, str]))
+        'volume-error': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([str, str])),
     }
 
     def __init__(self):
@@ -134,9 +132,8 @@ class VolumesToolbar(gtk.Toolbar):
 
 class BaseButton(RadioToolButton):
     __gsignals__ = {
-        'volume-error': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE,
-                           ([str, str]))
+        'volume-error': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([str, str])),
     }
 
     def __init__(self, mount_point):
diff --git a/src/jarabe/model/adhoc.py b/src/jarabe/model/adhoc.py
index a3f2927..88e1bbc 100644
--- a/src/jarabe/model/adhoc.py
+++ b/src/jarabe/model/adhoc.py
@@ -55,7 +55,7 @@ class AdHocManager(gobject.GObject):
         'members-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                             ([gobject.TYPE_PYOBJECT, gobject.TYPE_PYOBJECT])),
         'state-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                          ([gobject.TYPE_PYOBJECT, gobject.TYPE_PYOBJECT]))
+                          ([gobject.TYPE_PYOBJECT, gobject.TYPE_PYOBJECT])),
     }
 
     _AUTOCONNECT_TIMEOUT = 30
diff --git a/src/jarabe/model/bundleregistry.py b/src/jarabe/model/bundleregistry.py
index da37118..2d51d99 100644
--- a/src/jarabe/model/bundleregistry.py
+++ b/src/jarabe/model/bundleregistry.py
@@ -42,12 +42,12 @@ class BundleRegistry(gobject.GObject):
     """Tracks the available activity bundles"""
 
     __gsignals__ = {
-        'bundle-added':   (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                           ([gobject.TYPE_PYOBJECT])),
+        'bundle-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([gobject.TYPE_PYOBJECT])),
         'bundle-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                            ([gobject.TYPE_PYOBJECT])),
         'bundle-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                           ([gobject.TYPE_PYOBJECT]))
+                           ([gobject.TYPE_PYOBJECT])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/model/friends.py b/src/jarabe/model/friends.py
index b317130..bad6eed 100644
--- a/src/jarabe/model/friends.py
+++ b/src/jarabe/model/friends.py
@@ -94,10 +94,10 @@ class FriendBuddyModel(BuddyModel):
 
 class Friends(gobject.GObject):
     __gsignals__ = {
-        'friend-added':   (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE, ([object])),
-        'friend-removed': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE, ([str]))
+        'friend-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([object])),
+        'friend-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([str])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/model/invites.py b/src/jarabe/model/invites.py
index 8fbc398..e24a429 100644
--- a/src/jarabe/model/invites.py
+++ b/src/jarabe/model/invites.py
@@ -111,10 +111,10 @@ class ActivityInvite(object):
 
 class Invites(gobject.GObject):
     __gsignals__ = {
-        'invite-added':   (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE, ([object])),
-        'invite-removed': (gobject.SIGNAL_RUN_FIRST,
-                           gobject.TYPE_NONE, ([object]))
+        'invite-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                         ([object])),
+        'invite-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([object])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/model/neighborhood.py b/src/jarabe/model/neighborhood.py
index ec825ac..372f48e 100644
--- a/src/jarabe/model/neighborhood.py
+++ b/src/jarabe/model/neighborhood.py
@@ -71,14 +71,14 @@ _model = None
 
 class ActivityModel(gobject.GObject):
     __gsignals__ = {
-        'current-buddy-added':   (gobject.SIGNAL_RUN_FIRST,
-                                  gobject.TYPE_NONE, ([object])),
-        'current-buddy-removed': (gobject.SIGNAL_RUN_FIRST,
-                                  gobject.TYPE_NONE, ([object])),
-        'buddy-added':           (gobject.SIGNAL_RUN_FIRST,
-                                  gobject.TYPE_NONE, ([object])),
-        'buddy-removed':         (gobject.SIGNAL_RUN_FIRST,
-                                  gobject.TYPE_NONE, ([object])),
+        'current-buddy-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                                ([object])),
+        'current-buddy-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                                  ([object])),
+        'buddy-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                        ([object])),
+        'buddy-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([object])),
     }
 
     def __init__(self, activity_id, room_handle):
@@ -159,28 +159,26 @@ class ActivityModel(gobject.GObject):
 
 class _Account(gobject.GObject):
     __gsignals__ = {
-        'activity-added':       (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object, object])),
-        'activity-updated':     (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object, object])),
-        'activity-removed':     (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object])),
-        'buddy-added':          (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object, object, object])),
-        'buddy-updated':        (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object, object])),
-        'buddy-removed':        (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object])),
-        'buddy-joined-activity': (gobject.SIGNAL_RUN_FIRST,
-                                  gobject.TYPE_NONE, ([object, object])),
-        'buddy-left-activity':   (gobject.SIGNAL_RUN_FIRST,
-                                  gobject.TYPE_NONE, ([object, object])),
+        'activity-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([object, object])),
+        'activity-updated': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                             ([object, object])),
+        'activity-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                             ([object])),
+        'buddy-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                        ([object, object, object])),
+        'buddy-updated': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([object, object])),
+        'buddy-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([object])),
+        'buddy-joined-activity': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                                  ([object, object])),
+        'buddy-left-activity': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                                ([object, object])),
         'current-activity-updated': (gobject.SIGNAL_RUN_FIRST,
                                      gobject.TYPE_NONE, ([object, object])),
-        'connected':                (gobject.SIGNAL_RUN_FIRST,
-                                     gobject.TYPE_NONE, ([])),
-        'disconnected':             (gobject.SIGNAL_RUN_FIRST,
-                                     gobject.TYPE_NONE, ([])),
+        'connected': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
+        'disconnected': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
     }
 
     def __init__(self, account_path):
@@ -623,14 +621,14 @@ class _Account(gobject.GObject):
 
 class Neighborhood(gobject.GObject):
     __gsignals__ = {
-        'activity-added':       (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object])),
-        'activity-removed':     (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object])),
-        'buddy-added':          (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object])),
-        'buddy-removed':        (gobject.SIGNAL_RUN_FIRST,
-                                 gobject.TYPE_NONE, ([object]))
+        'activity-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([object])),
+        'activity-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                             ([object])),
+        'buddy-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                        ([object])),
+        'buddy-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([object])),
     }
 
     def __init__(self):
diff --git a/src/jarabe/model/network.py b/src/jarabe/model/network.py
index 20fd192..fa32b79 100644
--- a/src/jarabe/model/network.py
+++ b/src/jarabe/model/network.py
@@ -154,91 +154,91 @@ def get_error_by_reason(reason):
 
     if _nm_device_state_reason_description is None:
         _nm_device_state_reason_description = {
-            NM_DEVICE_STATE_REASON_UNKNOWN: \
-                _("The reason for the device state change \ is unknown."),
-            NM_DEVICE_STATE_REASON_NONE: \
+            NM_DEVICE_STATE_REASON_UNKNOWN:
+                _("The reason for the device state change is unknown."),
+            NM_DEVICE_STATE_REASON_NONE:
                 _("The state change is normal."),
-            NM_DEVICE_STATE_REASON_NOW_MANAGED: \
+            NM_DEVICE_STATE_REASON_NOW_MANAGED:
                 _("The device is now managed."),
-            NM_DEVICE_STATE_REASON_NOW_UNMANAGED: \
+            NM_DEVICE_STATE_REASON_NOW_UNMANAGED:
                 _("The device is no longer managed."),
-            NM_DEVICE_STATE_REASON_CONFIG_FAILED: \
+            NM_DEVICE_STATE_REASON_CONFIG_FAILED:
                 _("The device could not be readied for configuration."),
-            NM_DEVICE_STATE_REASON_CONFIG_UNAVAILABLE : \
-                _("IP configuration could not be reserved " \
-                      "(no available address, timeout, etc)."),
-            NM_DEVICE_STATE_REASON_CONFIG_EXPIRED : \
+            NM_DEVICE_STATE_REASON_CONFIG_UNAVAILABLE:
+                _("IP configuration could not be reserved "
+                  "(no available address, timeout, etc)."),
+            NM_DEVICE_STATE_REASON_CONFIG_EXPIRED:
                 _("The IP configuration is no longer valid."),
-            NM_DEVICE_STATE_REASON_NO_SECRETS : \
+            NM_DEVICE_STATE_REASON_NO_SECRETS:
                 _("Secrets were required, but not provided."),
-            NM_DEVICE_STATE_REASON_SUPPLICANT_DISCONNECT : \
-                _("The 802.1X supplicant disconnected from "\
-                      "the access point or authentication server."),
-            NM_DEVICE_STATE_REASON_SUPPLICANT_CONFIG_FAILED : \
+            NM_DEVICE_STATE_REASON_SUPPLICANT_DISCONNECT:
+                _("The 802.1X supplicant disconnected from "
+                  "the access point or authentication server."),
+            NM_DEVICE_STATE_REASON_SUPPLICANT_CONFIG_FAILED:
                 _("Configuration of the 802.1X supplicant failed."),
-            NM_DEVICE_STATE_REASON_SUPPLICANT_FAILED : \
+            NM_DEVICE_STATE_REASON_SUPPLICANT_FAILED:
                 _("The 802.1X supplicant quit or failed unexpectedly."),
-            NM_DEVICE_STATE_REASON_SUPPLICANT_TIMEOUT : \
+            NM_DEVICE_STATE_REASON_SUPPLICANT_TIMEOUT:
                 _("The 802.1X supplicant took too long to authenticate."),
-            NM_DEVICE_STATE_REASON_PPP_START_FAILED : \
+            NM_DEVICE_STATE_REASON_PPP_START_FAILED:
                 _("The PPP service failed to start within the allowed time."),
-            NM_DEVICE_STATE_REASON_PPP_DISCONNECT : \
+            NM_DEVICE_STATE_REASON_PPP_DISCONNECT:
                 _("The PPP service disconnected unexpectedly."),
-            NM_DEVICE_STATE_REASON_PPP_FAILED : \
+            NM_DEVICE_STATE_REASON_PPP_FAILED:
                 _("The PPP service quit or failed unexpectedly."),
-            NM_DEVICE_STATE_REASON_DHCP_START_FAILED : \
+            NM_DEVICE_STATE_REASON_DHCP_START_FAILED:
                 _("The DHCP service failed to start within the allowed time."),
-            NM_DEVICE_STATE_REASON_DHCP_ERROR : \
+            NM_DEVICE_STATE_REASON_DHCP_ERROR:
                 _("The DHCP service reported an unexpected error."),
-            NM_DEVICE_STATE_REASON_DHCP_FAILED : \
+            NM_DEVICE_STATE_REASON_DHCP_FAILED:
                 _("The DHCP service quit or failed unexpectedly."),
-            NM_DEVICE_STATE_REASON_SHARED_START_FAILED : \
+            NM_DEVICE_STATE_REASON_SHARED_START_FAILED:
                 _("The shared connection service failed to start."),
-            NM_DEVICE_STATE_REASON_SHARED_FAILED : \
-                _("The shared connection service quit or " \
-                      "failed unexpectedly."),
-            NM_DEVICE_STATE_REASON_AUTOIP_START_FAILED : \
+            NM_DEVICE_STATE_REASON_SHARED_FAILED:
+                _("The shared connection service quit or "
+                  "failed unexpectedly."),
+            NM_DEVICE_STATE_REASON_AUTOIP_START_FAILED:
                 _("The AutoIP service failed to start."),
-            NM_DEVICE_STATE_REASON_AUTOIP_ERROR : \
+            NM_DEVICE_STATE_REASON_AUTOIP_ERROR:
                 _("The AutoIP service reported an unexpected error."),
-            NM_DEVICE_STATE_REASON_AUTOIP_FAILED : \
+            NM_DEVICE_STATE_REASON_AUTOIP_FAILED:
                 _("The AutoIP service quit or failed unexpectedly."),
-            NM_DEVICE_STATE_REASON_MODEM_BUSY : \
+            NM_DEVICE_STATE_REASON_MODEM_BUSY:
                 _("Dialing failed because the line was busy."),
-            NM_DEVICE_STATE_REASON_MODEM_NO_DIAL_TONE : \
+            NM_DEVICE_STATE_REASON_MODEM_NO_DIAL_TONE:
                 _("Dialing failed because there was no dial tone."),
-            NM_DEVICE_STATE_REASON_MODEM_NO_CARRIER : \
+            NM_DEVICE_STATE_REASON_MODEM_NO_CARRIER:
                 _("Dialing failed because there was no carrier."),
-            NM_DEVICE_STATE_REASON_MODEM_DIAL_TIMEOUT : \
+            NM_DEVICE_STATE_REASON_MODEM_DIAL_TIMEOUT:
                 _("Dialing timed out."),
-            NM_DEVICE_STATE_REASON_MODEM_DIAL_FAILED : \
+            NM_DEVICE_STATE_REASON_MODEM_DIAL_FAILED:
                 _("Dialing failed."),
-            NM_DEVICE_STATE_REASON_MODEM_INIT_FAILED : \
+            NM_DEVICE_STATE_REASON_MODEM_INIT_FAILED:
                 _("Modem initialization failed."),
-            NM_DEVICE_STATE_REASON_GSM_APN_FAILED : \
+            NM_DEVICE_STATE_REASON_GSM_APN_FAILED:
                 _("Failed to select the specified GSM APN."),
-            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_NOT_SEARCHING : \
+            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_NOT_SEARCHING:
                 _("Not searching for networks."),
-            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_DENIED : \
+            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_DENIED:
                 _("Network registration was denied."),
-            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_TIMEOUT : \
+            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_TIMEOUT:
                 _("Network registration timed out."),
-            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_FAILED : \
+            NM_DEVICE_STATE_REASON_GSM_REGISTRATION_FAILED:
                 _("Failed to register with the requested GSM network."),
-            NM_DEVICE_STATE_REASON_GSM_PIN_CHECK_FAILED : \
+            NM_DEVICE_STATE_REASON_GSM_PIN_CHECK_FAILED:
                 _("PIN check failed."),
-            NM_DEVICE_STATE_REASON_FIRMWARE_MISSING : \
+            NM_DEVICE_STATE_REASON_FIRMWARE_MISSING:
                 _("Necessary firmware for the device may be missing."),
-            NM_DEVICE_STATE_REASON_REMOVED : \
+            NM_DEVICE_STATE_REASON_REMOVED:
                 _("The device was removed."),
-            NM_DEVICE_STATE_REASON_SLEEPING : \
+            NM_DEVICE_STATE_REASON_SLEEPING:
                 _("NetworkManager went to sleep."),
-            NM_DEVICE_STATE_REASON_CONNECTION_REMOVED : \
-                _("The device's active connection was removed " \
-                      "or disappeared."),
-            NM_DEVICE_STATE_REASON_USER_REQUESTED : \
+            NM_DEVICE_STATE_REASON_CONNECTION_REMOVED:
+                _("The device's active connection was removed "
+                  "or disappeared."),
+            NM_DEVICE_STATE_REASON_USER_REQUESTED:
                 _("A user or client requested the disconnection."),
-            NM_DEVICE_STATE_REASON_CARRIER : \
+            NM_DEVICE_STATE_REASON_CARRIER:
                 _("The device's carrier/link changed.")}
 
     return _nm_device_state_reason_description[reason]
@@ -667,7 +667,7 @@ class NMSettingsConnection(dbus.service.Object):
 class AccessPoint(gobject.GObject):
     __gsignals__ = {
         'props-changed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                          ([gobject.TYPE_PYOBJECT]))
+                          ([gobject.TYPE_PYOBJECT])),
     }
 
     def __init__(self, device, model):
diff --git a/src/jarabe/model/shell.py b/src/jarabe/model/shell.py
index 624648c..3c8b4db 100644
--- a/src/jarabe/model/shell.py
+++ b/src/jarabe/model/shell.py
@@ -312,27 +312,22 @@ class ShellModel(gobject.GObject):
     """
 
     __gsignals__ = {
-        'activity-added':          (gobject.SIGNAL_RUN_FIRST,
-                                    gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT])),
-        'activity-removed':        (gobject.SIGNAL_RUN_FIRST,
-                                    gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT])),
+        'activity-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([gobject.TYPE_PYOBJECT])),
+        'activity-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                             ([gobject.TYPE_PYOBJECT])),
         'active-activity-changed': (gobject.SIGNAL_RUN_FIRST,
                                     gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT])),
+                                    ([gobject.TYPE_PYOBJECT])),
         'tabbing-activity-changed': (gobject.SIGNAL_RUN_FIRST,
-                                    gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT])),
-        'launch-started':          (gobject.SIGNAL_RUN_FIRST,
-                                    gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT])),
-        'launch-completed':        (gobject.SIGNAL_RUN_FIRST,
-                                    gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT])),
-        'launch-failed':           (gobject.SIGNAL_RUN_FIRST,
-                                    gobject.TYPE_NONE,
-                                   ([gobject.TYPE_PYOBJECT]))
+                                     gobject.TYPE_NONE,
+                                     ([gobject.TYPE_PYOBJECT])),
+        'launch-started': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                           ([gobject.TYPE_PYOBJECT])),
+        'launch-completed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                             ([gobject.TYPE_PYOBJECT])),
+        'launch-failed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
+                          ([gobject.TYPE_PYOBJECT])),
     }
 
     ZOOM_MESH = 0
diff --git a/src/jarabe/util/emulator.py b/src/jarabe/util/emulator.py
index afcac30..4c9ca8e 100644
--- a/src/jarabe/util/emulator.py
+++ b/src/jarabe/util/emulator.py
@@ -34,7 +34,7 @@ default_dimensions = (800, 600)
 
 
 def _run_xephyr(display, dpi, dimensions, fullscreen):
-    cmd = [ 'Xephyr' ]
+    cmd = ['Xephyr']
     cmd.append(':%d' % display)
     cmd.append('-ac')
     cmd += ['-title', _('Sugar in a window')]
@@ -42,25 +42,25 @@ def _run_xephyr(display, dpi, dimensions, fullscreen):
     screen_size = (gtk.gdk.screen_width(), gtk.gdk.screen_height())
 
     if (not dimensions) and (fullscreen is None) and \
-       (screen_size < default_dimensions) :
+       (screen_size < default_dimensions):
         # no forced settings, screen too small => fit screen
         fullscreen = True
-    elif (not dimensions) :
+    elif not dimensions:
         # screen is big enough or user has en/disabled fullscreen manually
         # => use default size (will get ignored for fullscreen)
         dimensions = '%dx%d' % default_dimensions
 
-    if not dpi :
+    if not dpi:
         dpi = gtk.settings_get_default().get_property('gtk-xft-dpi') / 1024
 
-    if fullscreen :
+    if fullscreen:
         cmd.append('-fullscreen')
 
-    if dimensions :
+    if dimensions:
         cmd.append('-screen')
         cmd.append(dimensions)
 
-    if dpi :
+    if dpi:
         cmd.append('-dpi')
         cmd.append('%d' % dpi)
 
diff --git a/src/jarabe/util/telepathy/connection_watcher.py b/src/jarabe/util/telepathy/connection_watcher.py
index 2e073ae..685ef2c 100644
--- a/src/jarabe/util/telepathy/connection_watcher.py
+++ b/src/jarabe/util/telepathy/connection_watcher.py
@@ -37,7 +37,7 @@ class ConnectionWatcher(gobject.GObject):
         'connection-added': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                         ([gobject.TYPE_PYOBJECT])),
         'connection-removed': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
-                        ([gobject.TYPE_PYOBJECT]))
+                        ([gobject.TYPE_PYOBJECT])),
     }
 
     def __init__(self, bus=None):
diff --git a/src/jarabe/view/keyhandler.py b/src/jarabe/view/keyhandler.py
index 794092d..78a0693 100644
--- a/src/jarabe/view/keyhandler.py
+++ b/src/jarabe/view/keyhandler.py
@@ -39,30 +39,30 @@ _TABBING_MODIFIER = gtk.gdk.MOD1_MASK
 
 
 _actions_table = {
-    'F1'                   : 'zoom_mesh',
-    'F2'                   : 'zoom_group',
-    'F3'                   : 'zoom_home',
-    'F4'                   : 'zoom_activity',
-    'F5'                   : 'open_search',
-    'F6'                   : 'frame',
-    'XF86AudioMute'        : 'volume_mute',
-    'F11'                  : 'volume_down',
-    'XF86AudioLowerVolume' : 'volume_down',
-    'F12'                  : 'volume_up',
-    'XF86AudioRaiseVolume' : 'volume_up',
-    '<alt>F11'             : 'volume_min',
-    '<alt>F12'             : 'volume_max',
-    '0x93'                 : 'frame',
-    '<alt>Tab'             : 'next_window',
-    '<alt><shift>Tab'      : 'previous_window',
-    '<alt>Escape'          : 'close_window',
-    '0xDC'                 : 'open_search',
+    'F1': 'zoom_mesh',
+    'F2': 'zoom_group',
+    'F3': 'zoom_home',
+    'F4': 'zoom_activity',
+    'F5': 'open_search',
+    'F6': 'frame',
+    'XF86AudioMute': 'volume_mute',
+    'F11': 'volume_down',
+    'XF86AudioLowerVolume': 'volume_down',
+    'F12': 'volume_up',
+    'XF86AudioRaiseVolume': 'volume_up',
+    '<alt>F11': 'volume_min',
+    '<alt>F12': 'volume_max',
+    '0x93': 'frame',
+    '<alt>Tab': 'next_window',
+    '<alt><shift>Tab': 'previous_window',
+    '<alt>Escape': 'close_window',
+    '0xDC': 'open_search',
 # the following are intended for emulator users
-    '<alt><shift>f'        : 'frame',
-    '<alt><shift>q'        : 'quit_emulator',
-    'XF86Search'           : 'open_search',
-    '<alt><shift>o'        : 'open_search',
-    '<alt><shift>s'        : 'say_text',
+    '<alt><shift>f': 'frame',
+    '<alt><shift>q': 'quit_emulator',
+    'XF86Search': 'open_search',
+    '<alt><shift>o': 'open_search',
+    '<alt><shift>s': 'say_text',
 }
 
 SPEECH_DBUS_SERVICE = 'org.laptop.Speech'
diff --git a/src/jarabe/view/viewsource.py b/src/jarabe/view/viewsource.py
index e6e7e36..7b2a24f 100644
--- a/src/jarabe/view/viewsource.py
+++ b/src/jarabe/view/viewsource.py
@@ -132,10 +132,10 @@ class ViewSource(gtk.Window):
         file_name = ''
 
         activity_bundle = ActivityBundle(bundle_path)
-        command =  activity_bundle.get_command()
+        command = activity_bundle.get_command()
         if len(command.split(' ')) > 1:
             name = command.split(' ')[1].split('.')[0]
-            file_name =  name + '.py'
+            file_name = name + '.py'
             path = os.path.join(activity_bundle.get_path(), file_name)
             self._selected_file = path
 
@@ -260,11 +260,8 @@ class Toolbar(gtk.Toolbar):
     __gtype_name__ = 'SugarViewSourceToolbar'
 
     __gsignals__ = {
-        'stop-clicked':    (gobject.SIGNAL_RUN_FIRST,
-                            gobject.TYPE_NONE,
-                            ([])),
-        'source-selected': (gobject.SIGNAL_RUN_FIRST,
-                            gobject.TYPE_NONE,
+        'stop-clicked': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, ([])),
+        'source-selected': (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE,
                             ([str])),
     }
 
-- 
1.7.2.3



More information about the Sugar-devel mailing list