扫二维码与项目经理沟通
我们在微信上24小时期待你的声音
解答本文疑问/技术咨询/运营咨询/技术建议/互联网交流
1,QComboBox
connect(ui.load_combobox, SIGNAL(currentIndexChanged(int)), this, SLOT(load_sel(int)));
bool
ar_editor_window,::load_sel(int
index)
{
//int seleitem = ui.load_combobox->currentIndex();
bool rt = false;
switch (index)
{
case 0:
;
break;
case 1:
;
break;
default:
break;
}
return rt;
}
2,按钮菜单
_load_button = new
QPushButton()
_load_menu = new
QMenu();
_load_model_action = new QAction(_load_menu);
_load_pack_action = new QAction(_load_menu);
_load_menu->addAction(_load_model_action);
_load_menu->addAction(_load_pack_action);
_load_button->setMenu(_load_menu);
//remove_watermarks_button->setStyleSheet("QPushButton::menu-indicator{image:None;}");//去掉下拉三角
_load_button->setText(QStringLiteral ("导入"));
_load_model_action->setText(QStringLiteral("导入模型"));
_load_pack_action->setText(QStringLiteral("导入资源包"));
connect(_load_model_action, SIGNAL(triggered()), this, SLOT(load_model()));
connect(_load_pack_action, SIGNAL(triggered()), this, SLOT(load_pack()));
我们在微信上24小时期待你的声音
解答本文疑问/技术咨询/运营咨询/技术建议/互联网交流