f->top_pos = pos_y;
}
- FRAME_TERMINAL (f)->set_frame_offset_hook (f, pos_x, pos_y, -1);
+ if (FRAME_TERMINAL (f)->set_frame_offset_hook)
+ FRAME_TERMINAL (f)->set_frame_offset_hook (f, pos_x, pos_y, -1);
}
if (!CONSP (keep_ratio) || !NILP (Fcar (keep_ratio)))
list2 (inhibit_horizontal ? Qt : Qnil,
inhibit_vertical ? Qt : Qnil));
- FRAME_TERMINAL (f)->set_window_size_hook (f,
- 0,
- new_text_width,
- new_text_height,
- 1);
+ if (FRAME_TERMINAL (f)->set_window_size_hook)
+ FRAME_TERMINAL (f)->set_window_size_hook (f,
+ 0,
+ new_text_width,
+ new_text_height,
+ 1);
f->resized_p = true;
return;
#else /* ! 0 */
/* Instead, apply it only to the frame we're pointing to. */
#ifdef HAVE_WINDOW_SYSTEM
- if (track && FRAME_WINDOW_P (f))
+ if (track && FRAME_WINDOW_P (f) && FRAME_TERMINAL (f)->get_focus_frame)
{
Lisp_Object focus, gfocus;
{
#ifdef HAVE_WINDOW_SYSTEM
struct frame *f = decode_window_system_frame (frame);
- if (f)
+ if (f && FRAME_TERMINAL (f)->focus_frame_hook)
FRAME_TERMINAL (f)->focus_frame_hook (f, !NILP (noactivate));
#endif
return Qnil;
if (FRAME_WINDOW_P (f))
{
#ifdef HAVE_WINDOW_SYSTEM
- FRAME_TERMINAL (f)->set_frame_offset_hook (f,
- XFIXNUM (x),
- XFIXNUM (y),
- 1);
+ if (FRAME_TERMINAL (f)->set_frame_offset_hook)
+ FRAME_TERMINAL (f)->set_frame_offset_hook (f,
+ XFIXNUM (x),
+ XFIXNUM (y),
+ 1);
#endif
}
f->win_gravity = NorthWestGravity;
/* Actually set that position, and convert to absolute. */
- FRAME_TERMINAL (f)->set_frame_offset_hook (f, leftpos, toppos, -1);
+ if (FRAME_TERMINAL (f)->set_frame_offset_hook)
+ FRAME_TERMINAL (f)->set_frame_offset_hook (f, leftpos, toppos, -1);
}
if (fullscreen_change)
if (! NILP (Fequal (font_object, oldval)))
return;
- FRAME_TERMINAL (f)->set_new_font_hook (f, font_object, fontset);
+ if (FRAME_TERMINAL (f)->set_new_font_hook)
+ FRAME_TERMINAL (f)->set_new_font_hook (f, font_object, fontset);
store_frame_param (f, Qfont, arg);
#ifdef HAVE_X_WINDOWS
store_frame_param (f, Qfont_parameter, font_param);
}
else
{
- FRAME_TERMINAL (f)->set_scroll_bar_default_width_hook (f);
+ if (FRAME_TERMINAL (f)->set_scroll_bar_default_width_hook)
+ FRAME_TERMINAL (f)->set_scroll_bar_default_width_hook (f);
if (FRAME_NATIVE_WINDOW (f))
adjust_frame_size (f, -1, -1, 3, 0, Qscroll_bar_width);
}
else
{
- FRAME_TERMINAL (f)->set_scroll_bar_default_height_hook (f);
+ if (FRAME_TERMINAL (f)->set_scroll_bar_default_height_hook)
+ FRAME_TERMINAL (f)->set_scroll_bar_default_height_hook (f);
if (FRAME_NATIVE_WINDOW (f))
adjust_frame_size (f, -1, -1, 3, 0, Qscroll_bar_height);
already wasted too much time by walking through the list with
display_mode_element, then we might need to optimize at a
higher level than this.) */
- if (! STRINGP (f->name)
- || SBYTES (f->name) != len
- || memcmp (title, SDATA (f->name), len) != 0)
+ if ((! STRINGP (f->name)
+ || SBYTES (f->name) != len
+ || memcmp (title, SDATA (f->name), len) != 0)
+ && FRAME_TERMINAL (f)->implicit_set_name_hook)
FRAME_TERMINAL (f)->implicit_set_name_hook (f,
make_string (title, len),
Qnil);
if (new_height != WINDOW_PIXEL_HEIGHT (w))
{
- FRAME_TERMINAL (f)->change_tool_bar_height_hook (f, new_height);
+ if (FRAME_TERMINAL (f)->change_tool_bar_height_hook)
+ FRAME_TERMINAL (f)->change_tool_bar_height_hook (f, new_height);
frame_default_tool_bar_height = new_height;
/* Always do that now. */
clear_glyph_matrix (w->desired_matrix);
if (change_height_p)
{
- FRAME_TERMINAL (f)->change_tool_bar_height_hook (f, new_height);
+ if (FRAME_TERMINAL (f)->change_tool_bar_height_hook)
+ FRAME_TERMINAL (f)->change_tool_bar_height_hook (f, new_height);
frame_default_tool_bar_height = new_height;
clear_glyph_matrix (w->desired_matrix);
f->n_tool_bar_rows = nrows;