23 lines
602 B
Python
23 lines
602 B
Python
from PySide6.QtWidgets import QWidget
|
|
from .ui_form import Ui_RNCParams
|
|
from .config import groups
|
|
|
|
class Widget_RNCParams(QWidget, Ui_RNCParams):
|
|
def __init__(self, parent=None):
|
|
super(Widget_RNCParams, self).__init__(parent)
|
|
self.setupUi(self)
|
|
|
|
|
|
self.init_data()
|
|
self.bind_slot()
|
|
|
|
def bind_slot(self):
|
|
self.combobox_rnc.currentIndexChanged.connect(self.update_table)
|
|
def init_data(self):
|
|
# 初始化组件数据
|
|
|
|
self.combobox_rnc.addItems(item['name'] for item in groups)
|
|
|
|
def update_table(self):
|
|
print('item changed')
|