Added Dock.raiseDock() method
This commit is contained in:
parent
bc7bc29740
commit
e4ca62448b
@ -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."""
|
||||
|
Loading…
Reference in New Issue
Block a user