From 13b2cf6b1cf701da6dd63867efe9eea1cd2a3d6e Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Tue, 26 Jul 2022 20:10:19 +1000 Subject: [PATCH] WindowInfo: Linux build fix --- src/common/window_info.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/common/window_info.cpp b/src/common/window_info.cpp index ca2b2f901..5327a8c88 100644 --- a/src/common/window_info.cpp +++ b/src/common/window_info.cpp @@ -87,7 +87,7 @@ bool WindowInfo::QueryRefreshRateForWindow(const WindowInfo& wi, float* refresh_ #ifdef USE_X11 -#include "common/scope_guard.h" +#include "common/scoped_guard.h" #include "gl/x11_window.h" #include @@ -107,7 +107,7 @@ static bool GetRefreshRateFromXRandR(const WindowInfo& wi, float* refresh_rate) return false; } - Common::ScopeGuard res_guard([res]() { XRRFreeScreenResources(res); }); + ScopedGuard res_guard([res]() { XRRFreeScreenResources(res); }); int num_monitors; XRRMonitorInfo* mi = XRRGetMonitors(display, window, True, &num_monitors); @@ -121,7 +121,7 @@ static bool GetRefreshRateFromXRandR(const WindowInfo& wi, float* refresh_rate) Log_WarningPrintf("XRRGetMonitors() returned %d monitors, using first", num_monitors); } - Common::ScopeGuard mi_guard([mi]() { XRRFreeMonitors(mi); }); + ScopedGuard mi_guard([mi]() { XRRFreeMonitors(mi); }); if (mi->noutput <= 0) { Log_ErrorPrint("Monitor has no outputs"); @@ -139,7 +139,7 @@ static bool GetRefreshRateFromXRandR(const WindowInfo& wi, float* refresh_rate) return false; } - Common::ScopeGuard oi_guard([oi]() { XRRFreeOutputInfo(oi); }); + ScopedGuard oi_guard([oi]() { XRRFreeOutputInfo(oi); }); XRRCrtcInfo* ci = XRRGetCrtcInfo(display, res, oi->crtc); if (!ci) @@ -148,7 +148,7 @@ static bool GetRefreshRateFromXRandR(const WindowInfo& wi, float* refresh_rate) return false; } - Common::ScopeGuard ci_guard([ci]() { XRRFreeCrtcInfo(ci); }); + ScopedGuard ci_guard([ci]() { XRRFreeCrtcInfo(ci); }); XRRModeInfo* mode = nullptr; for (int i = 0; i < res->nmode; i++)