|
videodv
|
videodv
Posted 7 Years Ago
|
|
Group: Forum Members
Last Active: 3 Years Ago
Posts: 342,
Visits: 12.0K
|
Just a quick update here is the code to populate a combo box
ui_combo_box = qtui_widget.findChild(PySide2.QtWidgets.QComboBox, "comboBox")
get_screen_objects_combo_box(ui_combo_box)
def get_screen_objects_combo_box(): #-----Get all props ----- prop_objects = RLPy.RScene.FindObjects( RLPy.EObjectType_Prop ) for item in prop_objects: ui_combo_box.addItem(item.GetName())
And to get the selected item ui_combo_box.activated[str].connect(run_combo_box)
def run_combo_box(text): print("Combo Box Text: {}".format(text.GetName())
Hope this helps Chris.
|