SaveTool: make the weapon part selector focus on the current item.
This commit is contained in:
parent
d1712bf8cb
commit
3c4dfbda9a
1 changed files with 3 additions and 0 deletions
|
@ -479,6 +479,9 @@ void SaveTool::drawWeaponEditor(Weapon& weapon) {
|
||||||
if(ImGui::Selectable(mapped_part.second.data(), mapped_part.first == part.id)) {
|
if(ImGui::Selectable(mapped_part.second.data(), mapped_part.first == part.id)) {
|
||||||
part.id = mapped_part.first;
|
part.id = mapped_part.first;
|
||||||
}
|
}
|
||||||
|
if(mapped_part.first == part.id) {
|
||||||
|
ImGui::SetItemDefaultFocus();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ImGui::EndListBox();
|
ImGui::EndListBox();
|
||||||
|
|
Loading…
Reference in a new issue