43 Qt.WindowStaysOnTopHint | \ |
43 Qt.WindowStaysOnTopHint | \ |
44 Qt.X11BypassWindowManagerHint |
44 Qt.X11BypassWindowManagerHint |
45 if Globals.isWindowsPlatform(): |
45 if Globals.isWindowsPlatform(): |
46 flags |= Qt.ToolTip |
46 flags |= Qt.ToolTip |
47 self.setWindowFlags(flags) |
47 self.setWindowFlags(flags) |
|
48 |
|
49 self.frame.layout().setAlignment( |
|
50 self.verticalLayout, Qt.AlignLeft | Qt.AlignVCenter) |
48 |
51 |
49 self.__timer = QTimer(self) |
52 self.__timer = QTimer(self) |
50 self.__timer.setSingleShot(True) |
53 self.__timer.setSingleShot(True) |
51 self.__timer.timeout.connect(self.close) |
54 self.__timer.timeout.connect(self.close) |
52 |
55 |
97 self.__timer.stop() |
100 self.__timer.stop() |
98 self.__timer.setInterval(self.__timeout) |
101 self.__timer.setInterval(self.__timeout) |
99 self.__timer.start() |
102 self.__timer.start() |
100 |
103 |
101 super().show() |
104 super().show() |
|
105 |
|
106 msh = self.minimumSizeHint() |
|
107 self.resize(max(self.width(), msh.width()), msh.height()) |
102 |
108 |
103 def mousePressEvent(self, evt): |
109 def mousePressEvent(self, evt): |
104 """ |
110 """ |
105 Protected method to handle presses of a mouse button. |
111 Protected method to handle presses of a mouse button. |
106 |
112 |