MCPcopy Create free account
hub / github.com/PyQt5/PyQtClient / onCategoryChanged

Method onCategoryChanged

Widgets/Dialogs/SkinDialog.py:136–151  ·  view source on GitHub ↗

分类切换 :param button: 分类按钮 :param toggled: 是否选中

(self, button, toggled)

Source from the content-addressed store, hash-verified

134 self.categoryBtnGroups.buttons()[0].setChecked(True)
135
136 def onCategoryChanged(self, button, toggled):
137 """分类切换
138 :param button: 分类按钮
139 :param toggled: 是否选中
140 """
141 if not toggled:
142 return
143 widget = button.property('widget')
144 self.stackedWidgetPictures.setCurrentWidget(widget)
145 runnable = widget.init()
146 if runnable:
147 if not hasattr(self, '_threadPool'):
148 self._threadPool = QThreadPool(self)
149 self._threadPool.setMaxThreadCount(5)
150 widget.showWaiting()
151 self._threadPool.start(runnable)
152
153 def onPictureDownFinished(self, widget):
154 widget.showWaiting(False)

Callers

nothing calls this directly

Calls 3

initMethod · 0.45
showWaitingMethod · 0.45
startMethod · 0.45

Tested by

no test coverage detected