Skip to content
Snippets Groups Projects
Commit e4ca6244 authored by Luke Campagnola's avatar Luke Campagnola
Browse files

Added Dock.raiseDock() method

parent bc7bc297
No related branches found
No related tags found
No related merge requests found
......@@ -241,6 +241,13 @@ class TContainer(Container, QtGui.QWidget):
else:
w.label.setDim(True)
def raiseDock(self, dock):
"""Move *dock* to the top of the stack"""
self.stack.currentWidget().label.setDim(True)
self.stack.setCurrentWidget(dock)
dock.label.setDim(False)
def type(self):
return 'tab'
......
......@@ -208,6 +208,11 @@ class Dock(QtGui.QWidget, DockDrop):
self.moveLabel = False
self.setOrientation(force=True)
def raiseDock(self):
"""If this Dock is stacked underneath others, raise it to the top."""
self.container().raiseDock(self)
def close(self):
"""Remove this dock from the DockArea it lives inside."""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment