Use globalconf.timestamp

This makes us use globalconf.timestamp instead of XCB_CURRENT_TIME in the places
where it makes sense.

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2010-08-12 14:52:23 +02:00
parent 5225683d9b
commit 4862212c14
4 changed files with 6 additions and 6 deletions

View File

@ -301,7 +301,7 @@ client_unfocus(client_t *c)
* the WM_TAKE_FOCUS protocol. * the WM_TAKE_FOCUS protocol.
*/ */
xcb_set_input_focus(globalconf.connection, XCB_INPUT_FOCUS_PARENT, xcb_set_input_focus(globalconf.connection, XCB_INPUT_FOCUS_PARENT,
root_win, XCB_CURRENT_TIME); root_win, globalconf.timestamp);
client_unfocus_update(c); client_unfocus_update(c);
} }
@ -330,7 +330,7 @@ client_set_focus(client_t *c, bool set_input_focus)
bool takefocus = client_hasproto(c, WM_TAKE_FOCUS); bool takefocus = client_hasproto(c, WM_TAKE_FOCUS);
if(set_input_focus) if(set_input_focus)
xcb_set_input_focus(globalconf.connection, XCB_INPUT_FOCUS_PARENT, xcb_set_input_focus(globalconf.connection, XCB_INPUT_FOCUS_PARENT,
c->window, XCB_CURRENT_TIME); c->window, globalconf.timestamp);
if(takefocus) if(takefocus)
window_takefocus(c->window); window_takefocus(c->window);
} }
@ -1350,7 +1350,7 @@ client_kill(client_t *c)
ev.response_type = XCB_CLIENT_MESSAGE; ev.response_type = XCB_CLIENT_MESSAGE;
ev.window = c->window; ev.window = c->window;
ev.format = 32; ev.format = 32;
ev.data.data32[1] = XCB_CURRENT_TIME; ev.data.data32[1] = globalconf.timestamp;
ev.type = WM_PROTOCOLS; ev.type = WM_PROTOCOLS;
ev.data.data32[0] = WM_DELETE_WINDOW; ev.data.data32[0] = WM_DELETE_WINDOW;

View File

@ -52,7 +52,7 @@ luaA_selection_get(lua_State *L)
} }
xcb_convert_selection(globalconf.connection, selection_window, xcb_convert_selection(globalconf.connection, selection_window,
XCB_ATOM_PRIMARY, UTF8_STRING, XSEL_DATA, XCB_CURRENT_TIME); XCB_ATOM_PRIMARY, UTF8_STRING, XSEL_DATA, globalconf.timestamp);
xcb_flush(globalconf.connection); xcb_flush(globalconf.connection);
xcb_generic_event_t *event; xcb_generic_event_t *event;

View File

@ -348,7 +348,7 @@ luaA_spawn(lua_State *L)
sn_launcher_context_set_name(context, "awesome"); sn_launcher_context_set_name(context, "awesome");
sn_launcher_context_set_description(context, "awesome spawn"); sn_launcher_context_set_description(context, "awesome spawn");
sn_launcher_context_set_binary_name(context, cmdname); sn_launcher_context_set_binary_name(context, cmdname);
sn_launcher_context_initiate(context, "awesome", cmdname, XCB_CURRENT_TIME); sn_launcher_context_initiate(context, "awesome", cmdname, globalconf.timestamp);
p_delete(&cmdname); p_delete(&cmdname);
/* app will have AWESOME_SPAWN_TIMEOUT seconds to complete, /* app will have AWESOME_SPAWN_TIMEOUT seconds to complete,

View File

@ -207,7 +207,7 @@ window_takefocus(xcb_window_t win)
ev.response_type = XCB_CLIENT_MESSAGE; ev.response_type = XCB_CLIENT_MESSAGE;
ev.window = win; ev.window = win;
ev.format = 32; ev.format = 32;
ev.data.data32[1] = XCB_CURRENT_TIME; ev.data.data32[1] = globalconf.timestamp;
ev.type = WM_PROTOCOLS; ev.type = WM_PROTOCOLS;
ev.data.data32[0] = WM_TAKE_FOCUS; ev.data.data32[0] = WM_TAKE_FOCUS;