From: Jan Djärv Date: Sun, 13 Dec 2009 15:39:28 +0000 (+0000) Subject: Set the extended window manager hint for tooltip windows. X-Git-Tag: emacs-pretest-23.1.91~102 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=36acb2a70642e7395b3fa8f45291c7828718b392;p=emacs.git Set the extended window manager hint for tooltip windows. * xfns.c (x_create_tip_frame): Set the extended window manager hint for tooltip windows. * xterm.h (struct x_display_info): Add Xatom_net_window_type_tooltip and Xatom_net_window_type. * xterm.c (x_term_init): Initialize Xatom_net_window_type_tooltip and Xatom_net_window_type. --- diff --git a/src/ChangeLog b/src/ChangeLog index 692db938e61..a143e1d5739 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,16 @@ +2009-12-13 Pat Thoyts (tiny change) + + * xfns.c (x_create_tip_frame): Set the extended window manager hint for + tooltip windows. + 2009-12-13 Jan Djärv + * xterm.h (struct x_display_info): Add Xatom_net_window_type_tooltip and + Xatom_net_window_type. + + * xterm.c (x_term_init): Initialize Xatom_net_window_type_tooltip and + Xatom_net_window_type. + * xterm.c (my_log_handler): New function. (x_term_init): Set my_log_handler as log handler during gtk_init so we can filter out buggy messages. (bug #5120). diff --git a/src/xfns.c b/src/xfns.c index 27d0b025a24..b886a3ff674 100644 --- a/src/xfns.c +++ b/src/xfns.c @@ -4825,6 +4825,7 @@ x_create_tip_frame (dpyinfo, parms, text) { XSetWindowAttributes attrs; unsigned long mask; + Atom type = FRAME_X_DISPLAY_INFO (f)->Xatom_net_window_type_tooltip; BLOCK_INPUT; mask = CWBackPixel | CWOverrideRedirect | CWEventMask; @@ -4849,6 +4850,10 @@ x_create_tip_frame (dpyinfo, parms, text) f->border_width, CopyFromParent, InputOutput, CopyFromParent, mask, &attrs); + XChangeProperty (FRAME_X_DISPLAY (f), tip_window, + FRAME_X_DISPLAY_INFO (f)->Xatom_net_window_type, + XA_ATOM, 32, PropModeReplace, + (unsigned char *)&type, 1); UNBLOCK_INPUT; } diff --git a/src/xterm.c b/src/xterm.c index dee6190e755..7f9f6f3c05e 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -10445,7 +10445,11 @@ x_term_init (display_name, xrm_option, resource_name) = XInternAtom (dpyinfo->display, "_NET_WM_STATE_MAXIMIZED_VERT", False); dpyinfo->Xatom_net_wm_state_sticky = XInternAtom (dpyinfo->display, "_NET_WM_STATE_STICKY", False); - + dpyinfo->Xatom_net_window_type + = XInternAtom (dpyinfo->display, "_NET_WM_WINDOW_TYPE", False); + dpyinfo->Xatom_net_window_type_tooltip + = XInternAtom (dpyinfo->display, "_NET_WM_WINDOW_TYPE_TOOLTIP", False); + dpyinfo->cut_buffers_initialized = 0; dpyinfo->x_dnd_atoms_size = 8; diff --git a/src/xterm.h b/src/xterm.h index 1ad2a097016..6c6de8d901d 100644 --- a/src/xterm.h +++ b/src/xterm.h @@ -355,10 +355,12 @@ struct x_display_info size_t x_dnd_atoms_size; size_t x_dnd_atoms_length; - /* Extended window manager hints, Atoms supported by the window manager */ + /* Extended window manager hints, Atoms supported by the window manager and + atoms for settig the window type. */ Atom *net_supported_atoms; int nr_net_supported_atoms; Window net_supported_window; + Atom Xatom_net_window_type, Xatom_net_window_type_tooltip; /* Atoms dealing with maximization and fullscreen */ Atom Xatom_net_wm_state, Xatom_net_wm_state_fullscreen_atom,