diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/xfns.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/xfns.c b/src/xfns.c index e55dc0bec44..bb3c6fbe3d7 100644 --- a/src/xfns.c +++ b/src/xfns.c @@ -1697,7 +1697,7 @@ x_set_menu_bar_lines (f, value, oldval) if (nlines) { FRAME_EXTERNAL_MENU_BAR (f) = 1; - if (f->output_data.x->menubar_widget == 0) + if (FRAME_X_P (f) && f->output_data.x->menubar_widget == 0) /* Make sure next redisplay shows the menu bar. */ XWINDOW (FRAME_SELECTED_WINDOW (f))->update_mode_line = Qt; } @@ -1706,7 +1706,8 @@ x_set_menu_bar_lines (f, value, oldval) if (FRAME_EXTERNAL_MENU_BAR (f) == 1) free_frame_menubar (f); FRAME_EXTERNAL_MENU_BAR (f) = 0; - f->output_data.x->menubar_widget = 0; + if (FRAME_X_P (f)) + f->output_data.x->menubar_widget = 0; } #else /* not USE_X_TOOLKIT */ FRAME_MENU_BAR_LINES (f) = nlines; |