Fix warnings.
This commit is contained in:
parent
4f0f1dd84b
commit
8ab46669de
2 changed files with 31 additions and 31 deletions
58
main.cpp
58
main.cpp
|
@ -324,38 +324,38 @@ int main(int, char**)
|
|||
// 1. Show the big demo window (Most of the sample code is in ImGui::ShowDemoWindow()! You can browse its code to learn more about Dear ImGui!).
|
||||
if (show_demo_window)
|
||||
ImGui::ShowDemoWindow(&show_demo_window);
|
||||
if (ImGui::BeginMainMenuBar()) {
|
||||
if (ImGui::BeginMenu(ICON_FK_FILE "File")) {
|
||||
if (ImGui::MenuItem(ICON_FK_FOLDER_OPEN "Open")) {
|
||||
fileDialog.Open();
|
||||
}
|
||||
if (ImGui::MenuItem(ICON_FK_WINDOW_CLOSE "Quit")) {
|
||||
done = true;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
if (ImGui::BeginMainMenuBar()) {
|
||||
if (ImGui::BeginMenu(ICON_FK_FILE "File")) {
|
||||
if (ImGui::MenuItem(ICON_FK_FOLDER_OPEN "Open")) {
|
||||
fileDialog.Open();
|
||||
}
|
||||
if (ImGui::BeginMenu(ICON_FK_SCISSORS "Edit")) {
|
||||
if (ImGui::MenuItem(ICON_FK_COG "Preferences...")) {
|
||||
prefs_window = true;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
if (ImGui::MenuItem(ICON_FK_WINDOW_CLOSE "Quit")) {
|
||||
done = true;
|
||||
}
|
||||
#ifdef DEBUG
|
||||
if (ImGui::BeginMenu(ICON_FK_COG "Debug")) {
|
||||
if (ImGui::MenuItem("Show ImGui Demo Window", nullptr, show_demo_window)) {
|
||||
show_demo_window = !show_demo_window;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
#endif
|
||||
if (ImGui::BeginMenu(ICON_FK_INFO_CIRCLE "Help")) {
|
||||
if (ImGui::MenuItem(ICON_FK_INFO "About", nullptr, about_window)) {
|
||||
about_window = !about_window;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
ImGui::EndMainMenuBar();
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
if (ImGui::BeginMenu(ICON_FK_SCISSORS "Edit")) {
|
||||
if (ImGui::MenuItem(ICON_FK_COG "Preferences...")) {
|
||||
prefs_window = true;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
#ifdef DEBUG
|
||||
if (ImGui::BeginMenu(ICON_FK_COG "Debug")) {
|
||||
if (ImGui::MenuItem("Show ImGui Demo Window", nullptr, show_demo_window)) {
|
||||
show_demo_window = !show_demo_window;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
#endif
|
||||
if (ImGui::BeginMenu(ICON_FK_INFO_CIRCLE "Help")) {
|
||||
if (ImGui::MenuItem(ICON_FK_INFO "About", nullptr, about_window)) {
|
||||
about_window = !about_window;
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
ImGui::EndMainMenuBar();
|
||||
}
|
||||
ImGui::SetNextWindowDockID(dockid);
|
||||
ImGui::Begin(ICON_FK_PLAY "Player", nullptr, 0);
|
||||
{
|
||||
|
|
|
@ -277,7 +277,7 @@ bool Theme::ShowEditor(bool* open, Theme* &theme, ImGuiID dockid, int window_wid
|
|||
if (themePath.stem().string().starts_with(filter)) {
|
||||
const bool is_selected = strcmp(themePath.stem().generic_string().c_str(), selectedThemeName) == 0;
|
||||
if (ImGui::Selectable(themePath.stem().generic_string().c_str(), is_selected)) {
|
||||
strncpy(selectedThemeName, themePath.stem().generic_string().c_str(), 1024);
|
||||
strncpy(selectedThemeName, themePath.stem().generic_string().c_str(), 1023);
|
||||
}
|
||||
if (is_selected) {
|
||||
ImGui::SetItemDefaultFocus();
|
||||
|
@ -494,4 +494,4 @@ Theme::Theme(string path) : Theme() {
|
|||
}
|
||||
Theme::Theme(path path) : Theme(path.string()) {
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue