gnome-specimen r38 - trunk-from-bzr
- From: wbolster svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-specimen r38 - trunk-from-bzr
- Date: Tue, 17 Jun 2008 18:41:51 +0000 (UTC)
Author: wbolster
Date: Tue Jun 17 18:41:51 2008
New Revision: 38
URL: http://svn.gnome.org/viewvc/gnome-specimen?rev=38&view=rev
Log:
* specimenwindow.py:
- Tiny code cleanup: remove unneeded parentheses for tuple
expansion.
Modified:
trunk-from-bzr/ (props changed)
trunk-from-bzr/specimenwindow.py
Modified: trunk-from-bzr/specimenwindow.py
==============================================================================
--- trunk-from-bzr/specimenwindow.py (original)
+++ trunk-from-bzr/specimenwindow.py Tue Jun 17 18:41:51 2008
@@ -237,7 +237,7 @@
self._set_cell_attributes_for_name_cell(cell, name)
else:
# this is a preview row
- (name, face) = model.get(iter, 0, 2)
+ name, face = model.get(iter, 0, 2)
# Sometimes 'face' is None with GTK+ 2.9. Not sure why, bug #322471
# and bug #309221 might be related. Checking for None here seems to
# workaround the problem.
@@ -334,7 +334,7 @@
return number_of_rows / 2
def delete_selected(self):
- (model, iter) = self.previews_treeview.get_selection().get_selected()
+ model, iter = self.previews_treeview.get_selection().get_selected()
if iter is not None:
# Remove 2 rows
model.remove(iter)
@@ -375,7 +375,7 @@
# this is a child row
model = treeview.get_model()
iter = model.get_iter(path)
- (family, face) = model.get(iter, 1, 2)
+ family, face = model.get(iter, 1, 2)
self.add_preview(family, face)
def on_preview_size_changed(self, widget, user_data=None):
@@ -390,7 +390,7 @@
def on_previews_treeview_move_cursor(self, treeview, step, count, data=None):
'Makes sure only name rows can be selected/have focus'
- (path, column) = treeview.get_cursor()
+ path, column = treeview.get_cursor()
if path is not None and path[0] % 2 == 0:
if count == 1: new_path = (path[0] + 1,) # forward
else: new_path = (path[0] - 1,) # backward
@@ -429,7 +429,6 @@
def show_colors_dialog(self):
'Shows the colors dialog'
-
# Create the dialog
colors_dialog = gtk.Dialog(
'Change colors...',
@@ -493,9 +492,9 @@
def on_add_button_clicked(self, widget, data=None):
'Callback for the Add button'
- (model, iter) = self.fonts_treeview.get_selection().get_selected()
+ model, iter = self.fonts_treeview.get_selection().get_selected()
if iter is not None:
- (family, face) = model.get(iter, 1, 2)
+ family, face = model.get(iter, 1, 2)
self.add_preview(family, face)
self.fonts_treeview.grab_focus()
@@ -527,7 +526,7 @@
except (AttributeError):
self.clipboard = gtk.Clipboard()
else:
- (model, iter) = self.previews_treeview.get_selection().get_selected()
+ model, iter = self.previews_treeview.get_selection().get_selected()
if iter is not None:
# Copy the font name to the clipboard.
name = model.get_value(iter, 0);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]