From 14b28ba899b3fe414b3cdb537372ab13d4f56d85 Mon Sep 17 00:00:00 2001 From: iTrooz_ Date: Thu, 13 Oct 2022 08:07:46 +0200 Subject: [PATCH] ui: Show non existing folders in red in about view (#781) * show non existing folders in red in about view * use ImGuiCustomCol_ToolbarRed for theming * Fix compilation problem for Ubuntu --- plugins/builtin/source/content/views/view_about.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/plugins/builtin/source/content/views/view_about.cpp b/plugins/builtin/source/content/views/view_about.cpp index 6bfd70609..dd7443ffd 100644 --- a/plugins/builtin/source/content/views/view_about.cpp +++ b/plugins/builtin/source/content/views/view_about.cpp @@ -161,8 +161,13 @@ namespace hex::plugin::builtin { ImGui::TextUnformatted(name); ImGui::TableNextColumn(); - for (auto &path : fs::getDefaultPaths(type)) - ImGui::TextUnformatted(hex::toUTF8String(path).c_str()); + for (auto &path : fs::getDefaultPaths(type, true)){ + if(fs::isDirectory(path)){ + ImGui::TextUnformatted(hex::toUTF8String(path).c_str()); + }else{ + ImGui::TextFormattedColored(ImGui::GetCustomColorVec4(ImGuiCustomCol_ToolbarRed), hex::toUTF8String(path).c_str()); + } + } } ImGui::EndTable();