From d088b819f9c6d7a0d46019b2b11ba60f869af71d Mon Sep 17 00:00:00 2001 From: Uli Schlachter Date: Wed, 17 Jun 2009 14:56:24 +0200 Subject: [PATCH] Remove globalconf.have_randr This variable didn't really have any effect on anything. It was only ever checked in a function that would never be called if this flag was false. Signed-off-by: Uli Schlachter Signed-off-by: Julien Danjou --- event.c | 5 +---- structs.h | 2 -- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/event.c b/event.c index a21845e2..7dc3a174 100644 --- a/event.c +++ b/event.c @@ -671,9 +671,6 @@ event_handle_randr_screen_change_notify(void *data __attribute__ ((unused)), xcb_connection_t *connection __attribute__ ((unused)), xcb_randr_screen_change_notify_event_t *ev) { - if(!globalconf.have_randr) - return -1; - /* Code of XRRUpdateConfiguration Xlib function ported to XCB * (only the code relevant to RRScreenChangeNotify) as the latter * doesn't provide this kind of function */ @@ -810,7 +807,7 @@ void a_xcb_set_event_handlers(void) /* check for randr extension */ randr_query = xcb_get_extension_data(globalconf.connection, &xcb_randr_id); - if((globalconf.have_randr = randr_query->present)) + if(randr_query->present) xcb_event_set_handler(&globalconf.evenths, randr_query->first_event + XCB_RANDR_SCREEN_CHANGE_NOTIFY, (xcb_generic_event_handler_t) event_handle_randr_screen_change_notify, diff --git a/structs.h b/structs.h index 3a11872f..4a69efa3 100644 --- a/structs.h +++ b/structs.h @@ -73,8 +73,6 @@ struct awesome_t button_array_t buttons; /** Modifiers masks */ uint16_t numlockmask, shiftlockmask, capslockmask, modeswitchmask; - /** Check for XRandR extension */ - bool have_randr; /** Check for XTest extension */ bool have_xtest; /** Clients list */