26#include <wx/nonownedwnd.h>
28#include <wx/msw/registry.h>
38 const wxString lightModeKey = wxT(
"AppsUseLightTheme" );
42 wxRegKey themeKey( wxRegKey::HKCU,
43 wxT(
"SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Themes\\Personalize" ) );
45 if( !themeKey.Exists() )
48 if( !themeKey.HasValue( lightModeKey ) )
53 if( !themeKey.QueryValue( lightModeKey, &val ) )
58 wxColour bg = wxSystemSettings::GetColour( wxSYS_COLOUR_WINDOW );
61 double brightness = ( bg.Red() / 255.0 ) * 0.299 +
62 ( bg.Green() / 255.0 ) * 0.587 +
63 ( bg.Blue() / 255.0 ) * 0.117;
65 return brightness < 0.5;
72 return wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE );
89 return ( aWindow->GetHWND() == GetForegroundWindow() );
109 case wxCURSOR_BULLSEYE:
133 return aWindow->GetContentScaleFactor();
139 return aWindow->GetDPIScaleFactor();
145 return aWindow->GetClientSize();
163 return wxGetMousePosition();
169 aWindow->WarpPointer( aX, aY );
178 ImmAssociateContext( aWindow->GetHWND(), NULL );
182 ImmAssociateContextEx( aWindow->GetHWND(), 0, IACE_DEFAULT );
189 const HIMC himc = ImmGetContext( aWindow->GetHWND() );
190 ImmNotifyIME( himc, NI_COMPOSITIONSTR, CPS_CANCEL, 0 );
191 ImmReleaseContext( aWindow->GetHWND(), himc );
std::shared_ptr< PNS_LOG_VIEWER_OVERLAY > overlay