Mercurial > emacs
comparison src/xfns.c @ 5900:284c0d70a50a
(x_set_menu_bar_lines) [USE_X_TOOLKIT]: Dont Call XtDestroyWidget but
free_frame_menubar.
Undo previous changes.
author | Fred Pierresteguy <F.Pierresteguy@frcl.bull.fr> |
---|---|
date | Fri, 11 Feb 1994 13:56:38 +0000 |
parents | 4e8f26a0f2b7 |
children | ef777779bd80 |
comparison
equal
deleted
inserted
replaced
5899:4e8f26a0f2b7 | 5900:284c0d70a50a |
---|---|
72 | 72 |
73 /* The one and only application shell. Emacs screens are popup shells of this | 73 /* The one and only application shell. Emacs screens are popup shells of this |
74 application. */ | 74 application. */ |
75 Widget Xt_app_shell; | 75 Widget Xt_app_shell; |
76 | 76 |
77 extern void free_frame_menubar (); | |
77 #endif /* USE_X_TOOLKIT */ | 78 #endif /* USE_X_TOOLKIT */ |
78 | 79 |
79 #define min(a,b) ((a) < (b) ? (a) : (b)) | 80 #define min(a,b) ((a) < (b) ? (a) : (b)) |
80 #define max(a,b) ((a) > (b) ? (a) : (b)) | 81 #define max(a,b) ((a) > (b) ? (a) : (b)) |
81 | 82 |
1074 FRAME_MENU_BAR_LINES (f) = 0; | 1075 FRAME_MENU_BAR_LINES (f) = 0; |
1075 if (nlines) | 1076 if (nlines) |
1076 FRAME_EXTERNAL_MENU_BAR (f) = 1; | 1077 FRAME_EXTERNAL_MENU_BAR (f) = 1; |
1077 else | 1078 else |
1078 { | 1079 { |
1079 if (FRAME_EXTERNAL_MENU_BAR (f) == 1 | 1080 if (FRAME_EXTERNAL_MENU_BAR (f) == 1) |
1080 && f->display.x->menubar_widget) | 1081 free_frame_menubar (f); |
1081 XtDestroyWidget (f->display.x->menubar_widget); | |
1082 FRAME_EXTERNAL_MENU_BAR (f) = 0; | 1082 FRAME_EXTERNAL_MENU_BAR (f) = 0; |
1083 f->display.x->menubar_widget = 0; | 1083 f->display.x->menubar_widget = 0; |
1084 } | 1084 } |
1085 #else /* not USE_X_TOOLKIT */ | 1085 #else /* not USE_X_TOOLKIT */ |
1086 FRAME_MENU_BAR_LINES (f) = nlines; | 1086 FRAME_MENU_BAR_LINES (f) = nlines; |