|
@@ -1187,10 +1187,15 @@ void CMainFrame::InitDevicePanel()
|
|
|
// UI下拉框;
|
|
|
CString curText = pChipCombo->GetEditText();
|
|
|
CMFCRibbonComboBox* pStyleCombo = DYNAMIC_DOWNCAST(CMFCRibbonComboBox, pRibbon->FindByID(ID_COMBO_UI));
|
|
|
- for (auto it : m_map_tree.find(curText.GetString())->second)
|
|
|
+ std::map<std::string, std::vector<UITree>>::iterator itTree = m_map_tree.find(curText.GetString());
|
|
|
+ if (itTree != m_map_tree.end())
|
|
|
{
|
|
|
- pStyleCombo->AddItem(it.ui.c_str());
|
|
|
+ for ( auto it : itTree->second )
|
|
|
+ {
|
|
|
+ pStyleCombo->AddItem(it.ui.c_str());
|
|
|
+ }
|
|
|
}
|
|
|
+
|
|
|
pStyleCombo->SetEditText(m_rscfg.menutree_style.c_str());
|
|
|
|
|
|
CString strCurChip = pChipCombo->GetEditText();
|