mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-18 10:16:51 +00:00
Use FRAME_OUTER_WINDOW instead of ifdef X_TOOLKIT/else/endif
This commit is contained in:
parent
f554a9b4f8
commit
2436a4e491
@ -1,3 +1,11 @@
|
||||
2003-02-07 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
* xterm.c (x_text_icon, x_raise_frame, x_lower_frame)
|
||||
(x_make_frame_invisible, x_wm_set_icon_position): Use
|
||||
FRAME_OUTER_WINDOW instead of ifdef X_TOOLKIT/else/endif.
|
||||
|
||||
* xfns.c (x_set_name, x_set_title): Ditto.
|
||||
|
||||
2003-02-04 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* keyboard.c (echo_now): Update before_command_echo_length.
|
||||
|
32
src/xfns.c
32
src/xfns.c
@ -2552,22 +2552,15 @@ x_set_name (f, name, explicit)
|
||||
icon.format = 8;
|
||||
icon.nitems = bytes;
|
||||
}
|
||||
#ifdef USE_X_TOOLKIT
|
||||
XSetWMName (FRAME_X_DISPLAY (f),
|
||||
XtWindow (f->output_data.x->widget), &text);
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), XtWindow (f->output_data.x->widget),
|
||||
&icon);
|
||||
#else /* not USE_X_TOOLKIT */
|
||||
#ifdef USE_GTK
|
||||
gtk_window_set_title (GTK_WINDOW (FRAME_GTK_OUTER_WIDGET (f)),
|
||||
SDATA (name));
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f),
|
||||
&icon);
|
||||
#else /* not USE_GTK */
|
||||
XSetWMName (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), &text);
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), &icon);
|
||||
XSetWMName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), &text);
|
||||
#endif /* not USE_GTK */
|
||||
#endif /* not USE_X_TOOLKIT */
|
||||
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), &icon);
|
||||
|
||||
if (!NILP (f->icon_name)
|
||||
&& icon.value != (unsigned char *) SDATA (f->icon_name))
|
||||
xfree (icon.value);
|
||||
@ -2666,22 +2659,17 @@ x_set_title (f, name, old_name)
|
||||
icon.format = 8;
|
||||
icon.nitems = bytes;
|
||||
}
|
||||
#ifdef USE_X_TOOLKIT
|
||||
XSetWMName (FRAME_X_DISPLAY (f),
|
||||
XtWindow (f->output_data.x->widget), &text);
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), XtWindow (f->output_data.x->widget),
|
||||
&icon);
|
||||
#else /* not USE_X_TOOLKIT */
|
||||
|
||||
#ifdef USE_GTK
|
||||
gtk_window_set_title (GTK_WINDOW (FRAME_GTK_OUTER_WIDGET (f)),
|
||||
SDATA (name));
|
||||
#else /* not USE_GTK */
|
||||
XSetWMName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), &text);
|
||||
#endif /* not USE_GTK */
|
||||
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f),
|
||||
&icon);
|
||||
#else /* not USE_GTK */
|
||||
XSetWMName (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), &text);
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), &icon);
|
||||
#endif /* not USE_GTK */
|
||||
#endif /* not USE_X_TOOLKIT */
|
||||
|
||||
if (!NILP (f->icon_name)
|
||||
&& icon.value != (unsigned char *) SDATA (f->icon_name))
|
||||
xfree (icon.value);
|
||||
|
33
src/xterm.c
33
src/xterm.c
@ -12432,15 +12432,10 @@ x_text_icon (f, icon_name)
|
||||
text.encoding = XA_STRING;
|
||||
text.format = 8;
|
||||
text.nitems = strlen (icon_name);
|
||||
#ifdef USE_X_TOOLKIT
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), XtWindow (f->output_data.x->widget),
|
||||
&text);
|
||||
#else /* not USE_X_TOOLKIT */
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), &text);
|
||||
#endif /* not USE_X_TOOLKIT */
|
||||
XSetWMIconName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), &text);
|
||||
}
|
||||
#else /* not HAVE_X11R4 */
|
||||
XSetIconName (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), icon_name);
|
||||
XSetIconName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), icon_name);
|
||||
#endif /* not HAVE_X11R4 */
|
||||
|
||||
if (f->output_data.x->icon_bitmap > 0)
|
||||
@ -13624,11 +13619,7 @@ x_raise_frame (f)
|
||||
if (f->async_visible)
|
||||
{
|
||||
BLOCK_INPUT;
|
||||
#ifdef USE_X_TOOLKIT
|
||||
XRaiseWindow (FRAME_X_DISPLAY (f), XtWindow (f->output_data.x->widget));
|
||||
#else /* not USE_X_TOOLKIT */
|
||||
XRaiseWindow (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f));
|
||||
#endif /* not USE_X_TOOLKIT */
|
||||
XRaiseWindow (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f));
|
||||
XFlush (FRAME_X_DISPLAY (f));
|
||||
UNBLOCK_INPUT;
|
||||
}
|
||||
@ -13643,11 +13634,7 @@ x_lower_frame (f)
|
||||
if (f->async_visible)
|
||||
{
|
||||
BLOCK_INPUT;
|
||||
#ifdef USE_X_TOOLKIT
|
||||
XLowerWindow (FRAME_X_DISPLAY (f), XtWindow (f->output_data.x->widget));
|
||||
#else /* not USE_X_TOOLKIT */
|
||||
XLowerWindow (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f));
|
||||
#endif /* not USE_X_TOOLKIT */
|
||||
XLowerWindow (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f));
|
||||
XFlush (FRAME_X_DISPLAY (f));
|
||||
UNBLOCK_INPUT;
|
||||
}
|
||||
@ -13837,12 +13824,8 @@ x_make_frame_invisible (f)
|
||||
{
|
||||
Window window;
|
||||
|
||||
#ifdef USE_X_TOOLKIT
|
||||
/* Use the frame's outermost window, not the one we normally draw on. */
|
||||
window = XtWindow (f->output_data.x->widget);
|
||||
#else /* not USE_X_TOOLKIT */
|
||||
window = FRAME_X_WINDOW (f);
|
||||
#endif /* not USE_X_TOOLKIT */
|
||||
window = FRAME_OUTER_WINDOW (f);
|
||||
|
||||
/* Don't keep the highlight on an invisible frame. */
|
||||
if (FRAME_X_DISPLAY_INFO (f)->x_highlight_frame == f)
|
||||
@ -14413,11 +14396,7 @@ x_wm_set_icon_position (f, icon_x, icon_y)
|
||||
struct frame *f;
|
||||
int icon_x, icon_y;
|
||||
{
|
||||
#ifdef USE_X_TOOLKIT
|
||||
Window window = XtWindow (f->output_data.x->widget);
|
||||
#else
|
||||
Window window = FRAME_X_WINDOW (f);
|
||||
#endif
|
||||
Window window = FRAME_OUTER_WINDOW (f);
|
||||
|
||||
f->output_data.x->wm_hints.flags |= IconPositionHint;
|
||||
f->output_data.x->wm_hints.icon_x = icon_x;
|
||||
|
Loading…
Reference in New Issue
Block a user