From d99ad42f06e598d862d14e57e68e9fd49214cb9a Mon Sep 17 00:00:00 2001 From: Crementif <26669564+Crementif@users.noreply.github.com> Date: Sat, 26 Jul 2025 00:19:12 +0200 Subject: [PATCH] UI: Make placeholder game list icons black when using dark mode Might prevent a flashbang when game icons are being loaded. Might not fully fix it, since I can't really replicate it with the small amount of games I've currently got stored on this PC. --- src/gui/wxgui/components/wxGameList.cpp | 4 ++-- src/gui/wxgui/debugger/ModuleWindow.cpp | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/gui/wxgui/components/wxGameList.cpp b/src/gui/wxgui/components/wxGameList.cpp index 008bc087..9751c9c4 100644 --- a/src/gui/wxgui/components/wxGameList.cpp +++ b/src/gui/wxgui/components/wxGameList.cpp @@ -140,8 +140,8 @@ wxGameList::wxGameList(wxWindow* parent, wxWindowID id) { const auto& config = GetWxGUIConfig(); - char transparent_bitmap[kIconWidth * kIconWidth * 4] = {wxIMAGE_ALPHA_TRANSPARENT}; - memset((void*)transparent_bitmap, wxIMAGE_ALPHA_TRANSPARENT, sizeof(transparent_bitmap)); + char transparent_bitmap[kIconWidth * kIconWidth * 4] = {}; + memset((void*)transparent_bitmap, wxSystemSettings::GetAppearance().IsDark() ? 0xFF : 0x00, sizeof(transparent_bitmap)); wxBitmap blank(transparent_bitmap, kIconWidth, kIconWidth); blank.UseAlpha(true); diff --git a/src/gui/wxgui/debugger/ModuleWindow.cpp b/src/gui/wxgui/debugger/ModuleWindow.cpp index 638e374f..32dfd89e 100644 --- a/src/gui/wxgui/debugger/ModuleWindow.cpp +++ b/src/gui/wxgui/debugger/ModuleWindow.cpp @@ -23,8 +23,6 @@ ModuleWindow::ModuleWindow(DebuggerWindow2& parent, const wxPoint& main_position { this->SetSizeHints(wxDefaultSize, wxDefaultSize); - // this->wxWindowBase::SetBackgroundColour(*wxWHITE); - wxBoxSizer* main_sizer = new wxBoxSizer(wxVERTICAL); m_modules = new wxListView(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLC_REPORT);