Fullscreen mode added

This commit is contained in:
coderkun 2012-07-12 16:26:11 +02:00
parent 237e8d3757
commit 74d79ee0bc

View file

@ -210,8 +210,10 @@ class MCGGtk(Gtk.Window):
def _update_fullscreen(self):
if self._fullscreened:
self._toolbar.hide()
self._cover_panel.fullscreen();
else:
self._toolbar.show()
self._cover_panel.unfullscreen();
@ -464,7 +466,6 @@ class CoverPanel(Gtk.HPaned):
# Scroll
self._cover_scroll = Gtk.ScrolledWindow()
self._cover_scroll.add_with_viewport(self._cover_box)
self._cover_scroll.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.NEVER)
self.pack1(self._cover_scroll, True, True)
# GridModel
self._cover_grid_model = Gtk.ListStore(GdkPixbuf.Pixbuf, str, str, str)
@ -720,6 +721,14 @@ class CoverPanel(Gtk.HPaned):
self._callback(self.SIGNAL_TOGGLE_FULLSCREEN, event)
def fullscreen(self):
self.remove(self._cover_grid_scroll)
def unfullscreen(self):
self.pack2(self._cover_grid_scroll, False, True)
def compare_albums(self, model, row1, row2, criterion):
hash1 = model.get_value(row1, 3)
hash2 = model.get_value(row2, 3)