mirror of
https://github.com/283375/arcaea-offline-pyside-ui.git
synced 2025-04-21 18:20:18 +00:00
fix: repeat tab initialization
This commit is contained in:
parent
93bea4b88a
commit
2898e99cdf
@ -23,16 +23,16 @@ class MainWindow(Ui_MainWindow, QMainWindow):
|
|||||||
super().__init__(parent)
|
super().__init__(parent)
|
||||||
self.setupUi(self)
|
self.setupUi(self)
|
||||||
|
|
||||||
currentIndex = self.tabWidget.currentIndex()
|
# currentIndex = self.tabWidget.currentIndex()
|
||||||
ocrTabIndex = self.tabWidget.indexOf(self.tab_ocr)
|
# ocrTabIndex = self.tabWidget.indexOf(self.tab_ocr)
|
||||||
self.tabWidget.removeTab(ocrTabIndex)
|
# self.tabWidget.removeTab(ocrTabIndex)
|
||||||
self.tab_ocr.deleteLater()
|
# self.tab_ocr.deleteLater()
|
||||||
# if OCR_ENABLED_FLAG:
|
# if OCR_ENABLED_FLAG:
|
||||||
# self.tab_ocr = TabOcr(self.tabWidget)
|
# self.tab_ocr = TabOcr(self.tabWidget)
|
||||||
# else:
|
# else:
|
||||||
# self.tab_ocr = TabOcrDisabled(self.tabWidget)
|
# self.tab_ocr = TabOcrDisabled(self.tabWidget)
|
||||||
# self.tab_ocr.contentLabel.setText(OCR_ERROR_TEXT)
|
# self.tab_ocr.contentLabel.setText(OCR_ERROR_TEXT)
|
||||||
self.tab_ocr = TabOcrEntry(self.tabWidget)
|
# self.tab_ocr = TabOcrEntry(self.tabWidget)
|
||||||
self.tabWidget.insertTab(ocrTabIndex, self.tab_ocr, "")
|
# self.tabWidget.insertTab(ocrTabIndex, self.tab_ocr, "")
|
||||||
self.tabWidget.setCurrentIndex(currentIndex)
|
# self.tabWidget.setCurrentIndex(currentIndex)
|
||||||
self.retranslateUi(self)
|
# self.retranslateUi(self)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user