mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-11-12 14:25:29 +01:00
small x11 improovement
This commit is contained in:
1 parent
4e54117238
commit
3e9678c899
1 file changed
+1
-8
@@ -86,13 +86,6 @@ static int xrandrGetCurrentRate(void* xrandr, Display* display)
|
||||
if(ffXRRConfigCurrentRate == NULL)
|
||||
return 0;
|
||||
|
||||
XRRMonitorInfo*(*ffXRRGetMonitors)(Display*, Window, Bool, int*) = dlsym(xrandr, "XRRGetMonitors");
|
||||
if(ffXRRGetMonitors == NULL)
|
||||
return 0;
|
||||
|
||||
void(*ffXRRFreeMonitors)(XRRMonitorInfo*) = dlsym(xrandr, "XRRFreeMonitors");
|
||||
if(ffXRRFreeMonitors == NULL)
|
||||
return 0;
|
||||
|
||||
XRRScreenConfiguration* xrrscreenconf = ffXRRGetScreenInfo(display, DefaultRootWindow(display));
|
||||
if(xrrscreenconf == NULL)
|
||||
@@ -130,7 +123,7 @@ bool ffPrintResolutionXrandrBackend(FFinstance* instance)
|
||||
return false;
|
||||
|
||||
int numberOfMonitors;
|
||||
XRRMonitorInfo* monitors = ffXRRGetMonitors(display, RootWindow(display, 0), False, &numberOfMonitors);
|
||||
XRRMonitorInfo* monitors = ffXRRGetMonitors(display, DefaultRootWindow(display), False, &numberOfMonitors);
|
||||
if(monitors == NULL)
|
||||
{
|
||||
xCloseDisplay(xrandr, display);
|
||||
|
||||
Reference in new issue
Block a user