Exit with ESC (#1195)
This commit is contained in:
parent
4fe0e1d06a
commit
a3a8dd7f0d
4
extern/igfd/ImGuiFileDialogConfig.h
vendored
4
extern/igfd/ImGuiFileDialogConfig.h
vendored
|
@ -36,8 +36,8 @@
|
||||||
//#define IGFD_KEY_BACKSPACE GLFW_KEY_BACKSPACE
|
//#define IGFD_KEY_BACKSPACE GLFW_KEY_BACKSPACE
|
||||||
|
|
||||||
// by ex you can quit the dialog by pressing the key excape
|
// by ex you can quit the dialog by pressing the key excape
|
||||||
//#define USE_DIALOG_EXIT_WITH_KEY
|
#define USE_DIALOG_EXIT_WITH_KEY
|
||||||
//#define IGFD_EXIT_KEY GLFW_KEY_ESCAPE
|
#define IGFD_EXIT_KEY ImGuiKey_Escape
|
||||||
|
|
||||||
// widget
|
// widget
|
||||||
// filter combobox width
|
// filter combobox width
|
||||||
|
|
|
@ -140,7 +140,7 @@ void FurnaceGUI::drawNewSong() {
|
||||||
|
|
||||||
ImGui::SameLine();
|
ImGui::SameLine();
|
||||||
|
|
||||||
if (ImGui::Button("Cancel")) {
|
if (ImGui::Button("Cancel") || ImGui::IsKeyPressed(ImGuiKey_Escape)) {
|
||||||
ImGui::CloseCurrentPopup();
|
ImGui::CloseCurrentPopup();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue