From 2435a76caa730ea31e2729c3a8d641e14ff18e63 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sat, 28 Sep 2024 14:01:18 +0200 Subject: [PATCH] Don't set dpiScale if not doing anything with it. --- profiler/src/main.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/profiler/src/main.cpp b/profiler/src/main.cpp index 3d27185d..e459b446 100644 --- a/profiler/src/main.cpp +++ b/profiler/src/main.cpp @@ -99,7 +99,7 @@ static char addr[1024] = { "127.0.0.1" }; static ConnectionHistory* connHist; static std::atomic viewShutdown { ViewShutdown::False }; static double animTime = 0; -static float dpiScale = 1.f; +static float dpiScale = -1.f; static bool dpiScaleOverriddenFromEnv = false; static float userScale = 1.f; static float prevScale = 1.f; @@ -385,7 +385,6 @@ int main( int argc, char** argv ) backend.SetIcon( iconPx, iconX, iconY ); bptr = &backend; - dpiScale = backend.GetDpiScale(); const auto envDpiScale = getenv( "TRACY_DPI_SCALE" ); if( envDpiScale ) {