Browse files

Gtk UI: Fix listing of big files on Windows (bug 1562)

For files > 2GB, the list store couldn't handle the
long integer values. Fix this by using a different data
type in the ListStore.

Also fixed a bug that used the wrong units when showing
the file size in the main window (use_si_units was 1).
  • Loading branch information...
1 parent 411d702 commit d0eaccbc3625976995bde8067ccdab8ad2255d56 @thp thp committed Feb 11, 2012
Showing with 3 additions and 2 deletions.
  1. +3 −2 src/gpodder/gtkui/
@@ -38,6 +38,7 @@
import os
import gtk
+import gobject
import cgi
import re
@@ -122,7 +123,7 @@ class EpisodeListModel(gtk.ListStore):
def __init__(self, on_filter_changed=lambda has_episodes: None):
gtk.ListStore.__init__(self, str, str, str, object, \
str, str, str, str, bool, bool, bool, \
- int, int, str, bool, int, bool)
+ gobject.TYPE_INT64, int, str, bool, int, bool)
# Callback for when the filter / list changes, gets one parameter
# (has_episodes) that is True if the list has any episodes
@@ -155,7 +156,7 @@ def __init__(self, on_filter_changed=lambda has_episodes: None):
def _format_filesize(self, episode):
if episode.file_size > 0:
- return util.format_filesize(episode.file_size, 1)
+ return util.format_filesize(episode.file_size, digits=1)
return None

0 comments on commit d0eaccb

Please sign in to comment.