(self, event)
| 55 | self.setPixmap(QPixmap('Data/2.png')) |
| 56 | |
| 57 | def mousePressEvent(self, event): |
| 58 | super(SettingWidget, self).mousePressEvent(event) |
| 59 | pos = event.pos() |
| 60 | if pos.y() >= self.height() - 30: |
| 61 | if self.width() - 95 <= pos.x() <= self.width() - 10: |
| 62 | # 点击切换按钮 |
| 63 | self.windowChanged.emit() |
| 64 | elif pos.y() <= 40: |
| 65 | if pos.x() > self.width() - 30: |
| 66 | # 点击关闭按钮的地方 |
| 67 | self.windowClosed.emit() |
| 68 | |
| 69 | |
| 70 | class Window(QStackedWidget): |
nothing calls this directly
no test coverage detected