diff options
Diffstat (limited to 'source')
-rw-r--r-- | source/dialogs/window.c | 16 | ||||
-rw-r--r-- | source/i3-support.c | 4 | ||||
-rw-r--r-- | source/view.c | 2 |
3 files changed, 11 insertions, 11 deletions
diff --git a/source/dialogs/window.c b/source/dialogs/window.c index b4189f7e..ccdf9824 100644 --- a/source/dialogs/window.c +++ b/source/dialogs/window.c @@ -79,7 +79,7 @@ typedef struct // window lists typedef struct { - Window *array; + xcb_window_t *array; client **data; int len; } winlist; @@ -95,7 +95,7 @@ static winlist* winlist_new () { winlist *l = g_malloc ( sizeof ( winlist ) ); l->len = 0; - l->array = g_malloc_n ( WINLIST + 1, sizeof ( Window ) ); + l->array = g_malloc_n ( WINLIST + 1, sizeof ( xcb_window_t ) ); l->data = g_malloc_n ( WINLIST + 1, sizeof ( client* ) ); return l; } @@ -109,10 +109,10 @@ static winlist* winlist_new () * * @returns 0 if failed, 1 is successful. */ -static int winlist_append ( winlist *l, Window w, client *d ) +static int winlist_append ( winlist *l, xcb_window_t w, client *d ) { if ( l->len > 0 && !( l->len % WINLIST ) ) { - l->array = g_realloc ( l->array, sizeof ( Window ) * ( l->len + WINLIST + 1 ) ); + l->array = g_realloc ( l->array, sizeof ( xcb_window_t ) * ( l->len + WINLIST + 1 ) ); l->data = g_realloc ( l->data, sizeof ( client* ) * ( l->len + WINLIST + 1 ) ); } // Make clang-check happy. @@ -163,7 +163,7 @@ static void winlist_free ( winlist *l ) * * @returns -1 if failed, index is successful. */ -static int winlist_find ( winlist *l, Window w ) +static int winlist_find ( winlist *l, xcb_window_t w ) { // iterate backwards. Theory is: windows most often accessed will be // nearer the end. Testing with kcachegrind seems to support this... @@ -239,7 +239,7 @@ static int client_has_window_type ( client *c, xcb_atom_t type ) static client* window_client ( xcb_connection_t *xcb_connection, xcb_window_t win ) { - if ( win == None ) { + if ( win == XCB_WINDOW_NONE ) { return NULL; } @@ -453,7 +453,7 @@ static void _window_mode_load_data ( Mode *sw, unsigned int cd ) // build the actual list for ( i = 0; i < ( pd->ids->len ); i++ ) { - Window w = pd->ids->array[i]; + xcb_window_t w = pd->ids->array[i]; client *c; if ( ( c = window_client ( xcb_connection, w ) ) ) { @@ -540,7 +540,7 @@ static ModeMode window_mode_result ( Mode *sw, int mretv, G_GNUC_UNUSED char **i else{ xcb_ewmh_request_change_active_window ( &xcb_ewmh, xcb_screen_nbr, rmpd->ids->array[selected_line], XCB_EWMH_CLIENT_SOURCE_TYPE_OTHER , - XCB_CURRENT_TIME, None); + XCB_CURRENT_TIME, XCB_WINDOW_NONE); xcb_flush(xcb_connection); } } diff --git a/source/i3-support.c b/source/i3-support.c index 9b932678..937bc74f 100644 --- a/source/i3-support.c +++ b/source/i3-support.c @@ -48,7 +48,7 @@ char *i3_socket_path = NULL; extern xcb_screen_t *xcb_screen; -void i3_support_focus_window ( Window id ) +void i3_support_focus_window ( xcb_window_t id ) { i3_ipc_header_t head; int s; @@ -132,7 +132,7 @@ void i3_support_free_internals ( void ) #else -void i3_support_focus_window ( G_GNUC_UNUSED Window id ) +void i3_support_focus_window ( G_GNUC_UNUSED xcb_window_t id ) { fprintf ( stderr, "Trying to control i3, when i3 support is not enabled.\n" ); abort (); diff --git a/source/view.c b/source/view.c index 7a59ae23..3baeb40f 100644 --- a/source/view.c +++ b/source/view.c @@ -485,7 +485,7 @@ static void check_is_ascii ( thread_state *t, G_GNUC_UNUSED gpointer user_data ) g_mutex_unlock ( t->mutex ); } -static Window __create_window ( xcb_connection_t *xcb_connection, xcb_screen_t *xcb_screen, MenuFlags menu_flags ) +static xcb_window_t __create_window ( xcb_connection_t *xcb_connection, xcb_screen_t *xcb_screen, MenuFlags menu_flags ) { uint32_t selmask = XCB_CW_BACK_PIXEL | XCB_CW_BORDER_PIXEL | XCB_CW_EVENT_MASK | XCB_CW_COLORMAP; uint32_t selval[] = |