Merge pull request #1945 from Airblader/feature-frame-class

Set a proper WM_CLASS on frame windows.
This commit is contained in:
Michael Stapelberg 2015-09-22 09:10:38 +02:00
commit a2aec4ee92
1 changed files with 8 additions and 0 deletions

View File

@ -145,6 +145,14 @@ void x_con_init(Con *con, uint16_t depth) {
Rect dims = {-15, -15, 10, 10};
con->frame = create_window(conn, dims, depth, visual, XCB_WINDOW_CLASS_INPUT_OUTPUT, XCURSOR_CURSOR_POINTER, false, mask, values);
xcb_change_property(conn,
XCB_PROP_MODE_REPLACE,
con->frame,
XCB_ATOM_WM_CLASS,
XCB_ATOM_STRING,
8,
(strlen("i3-frame") + 1) * 2,
"i3-frame\0i3-frame\0");
if (win_colormap != XCB_NONE)
xcb_free_colormap(conn, win_colormap);