refactor!: Modify command argument handling and move on_ method to bool_command (#1826)

This commit is contained in:
Andreas Maerten
2023-07-26 22:22:40 +02:00
committed by GitHub
parent f73c1bdc98
commit 96493b5a22
104 changed files with 562 additions and 381 deletions

View File

@ -70,8 +70,8 @@ namespace big
}
ImGui::PushItemWidth(300);
components::input_text_with_hint("Category", "Category", &category);
components::input_text_with_hint("Location name", "New location", &new_location_name);
components::input_text_with_hint("Category", "Category", category);
components::input_text_with_hint("Location name", "New location", new_location_name);
ImGui::PopItemWidth();
components::button("Save current location", [] {
@ -140,7 +140,7 @@ namespace big
components::small_text("Double click to teleport\nShift click to delete");
ImGui::Spacing();
components::input_text_with_hint("##filter", "Search", &filter);
components::input_text_with_hint("##filter", "Search", filter);
ImGui::BeginGroup();
components::small_text("Categories");

View File

@ -296,7 +296,7 @@ namespace big
ImGui::SameLine();
ImGui::BeginGroup();
static std::string input_file_name;
components::input_text_with_hint("Weapon Loadout Filename", "Loadout Name", &input_file_name);
components::input_text_with_hint("Weapon Loadout Filename", "Loadout Name", input_file_name);
components::button("Save Loadout", [] {
persist_weapons::save_weapons(input_file_name);
input_file_name.clear();