Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrés Ambrois <andresambrois@gmail.com>2010-05-23 07:01:09 (GMT)
committer Andrés Ambrois <andresambrois@gmail.com>2010-08-24 08:49:01 (GMT)
commit2bb49bcc39f371c0c16603a4e5caa28c7619bf36 (patch)
treeaf7b74c12a12d5a745256effe6e4977e62c1247b
parentbe11e0273f9d3f9da023c8669b604f2b377fe362 (diff)
Rename the date column to 'sort_column'
As it will be used to display the currently active sorting property. Signed-off-by: Andrés Ambrois <andresambrois@gmail.com>
-rw-r--r--src/jarabe/journal/listview.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/jarabe/journal/listview.py b/src/jarabe/journal/listview.py
index 9e19f70..375a8ee 100644
--- a/src/jarabe/journal/listview.py
+++ b/src/jarabe/journal/listview.py
@@ -97,7 +97,7 @@ class BaseListView(gtk.Bin):
self.cell_title = None
self.cell_icon = None
self._title_column = None
- self.date_column = None
+ self.sort_column = None
self._add_columns()
self.tree_view.enable_model_drag_source(gtk.gdk.BUTTON1_MASK,
@@ -190,15 +190,15 @@ class BaseListView(gtk.Bin):
date = util.timestamp_to_elapsed_string(timestamp)
date_width = self._get_width_for_string(date)
- self.date_column = gtk.TreeViewColumn()
- self.date_column.props.sizing = gtk.TREE_VIEW_COLUMN_FIXED
- self.date_column.props.fixed_width = date_width
- self.date_column.set_alignment(1)
- self.date_column.props.resizable = True
- self.date_column.props.clickable = True
- self.date_column.pack_start(cell_text)
- self.date_column.add_attribute(cell_text, 'text', ListModel.COLUMN_DATE)
- self.tree_view.append_column(self.date_column)
+ self.sort_column = gtk.TreeViewColumn()
+ self.sort_column.props.sizing = gtk.TREE_VIEW_COLUMN_FIXED
+ self.sort_column.props.fixed_width = date_width
+ self.sort_column.set_alignment(1)
+ self.sort_column.props.resizable = True
+ self.sort_column.props.clickable = True
+ self.sort_column.pack_start(cell_text)
+ self.sort_column.add_attribute(cell_text, 'text', ListModel.COLUMN_TIMESTAMP)
+ self.tree_view.append_column(self.sort_column)
def _get_width_for_string(self, text):
# Add some extra margin
@@ -415,7 +415,7 @@ class BaseListView(gtk.Bin):
while True:
x, y, width, height = self.tree_view.get_cell_area(path,
- self.date_column)
+ self.sort_column)
x, y = self.tree_view.convert_tree_to_widget_coords(x, y)
self.tree_view.queue_draw_area(x, y, width, height)
if path == end_path: