Commit bb3e667e authored by Alexandru Băluț's avatar Alexandru Băluț
Browse files

viewer: Separate the undock callback

parent e18adcac
......@@ -280,7 +280,7 @@ class ViewerContainer(Gtk.Box, Loggable):
self.undock_button = Gtk.ToolButton()
self.undock_button.connect("clicked", self.undock)
self.undock_button.connect("clicked", self.undock_cb)
_("Detach the viewer\nYou can re-attach it by closing the newly created window."))
bbox.pack_start(self.undock_button, False, False, 0)
......@@ -393,9 +393,12 @@ class ViewerContainer(Gtk.Box, Loggable):
align=Gtk.Align.CENTER, when_not_in_view=True)
def undock_cb(self, unused_widget):
# Public methods for controlling playback
def undock(self, *unused_widget):
def undock(self):
if not self.docked:
self.warning("The viewer is already undocked")
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment