1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2025-01-30 18:49:31 +00:00

Fix build with specific option combination (#1918)

Fixes incorrect member accessing left behind after #1910.
This commit is contained in:
Fernando Apesteguía 2024-05-15 20:18:11 +02:00 committed by GitHub
parent 2d50767216
commit c635df8689
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 5 additions and 4 deletions

View File

@ -31,6 +31,7 @@ extern "C" {
} }
#include <config.h> #include <config.h>
#include "geometry.h"
#ifdef BUILD_MOUSE_EVENTS #ifdef BUILD_MOUSE_EVENTS
#include "mouse-events.h" #include "mouse-events.h"

View File

@ -77,7 +77,7 @@ bool use_xpmdb_setting::set_up(lua::state &l) {
if (!out_to_x.get(l)) return false; if (!out_to_x.get(l)) return false;
window.back_buffer = window.back_buffer =
XCreatePixmap(display, window.window, window.width + 1, window.height + 1, XCreatePixmap(display, window.window, window.geometry.get_width() + 1, window.geometry.get_height() + 1,
DefaultDepth(display, screen)); DefaultDepth(display, screen));
if (window.back_buffer != None) { if (window.back_buffer != None) {
window.drawable = window.back_buffer; window.drawable = window.back_buffer;

View File

@ -1219,10 +1219,10 @@ void xdbe_swap_buffers() {
void xpmdb_swap_buffers(void) { void xpmdb_swap_buffers(void) {
if (use_xpmdb.get(*state)) { if (use_xpmdb.get(*state)) {
XCopyArea(display, window.back_buffer, window.window, window.gc, 0, 0, XCopyArea(display, window.back_buffer, window.window, window.gc, 0, 0,
window.width, window.height, 0, 0); window.geometry.get_width(), window.geometry.get_height(), 0, 0);
XSetForeground(display, window.gc, 0); XSetForeground(display, window.gc, 0);
XFillRectangle(display, window.drawable, window.gc, 0, 0, window.width, XFillRectangle(display, window.drawable, window.gc, 0, 0, window.geometry.get_width(),
window.height); window.geometry.get_height());
XFlush(display); XFlush(display);
} }
} }