diff options
| author | Jason Rumney | 2007-02-22 22:49:41 +0000 |
|---|---|---|
| committer | Jason Rumney | 2007-02-22 22:49:41 +0000 |
| commit | b2a916a0f4be7baad98e2498c2ef7618f39e51b9 (patch) | |
| tree | b8ee60dc6b3842b74c4829a67dd6c85475272f96 | |
| parent | fbc232f4e2e0e7581c57316999623a82f2b5b0ce (diff) | |
| download | emacs-b2a916a0f4be7baad98e2498c2ef7618f39e51b9.tar.gz emacs-b2a916a0f4be7baad98e2498c2ef7618f39e51b9.zip | |
(current_popup_menu): Make available globally.
(menubar_selection_callback): Free menu strings before pushing the
menu event into the keyboard buffer. Remove menu_command_in_progress.
| -rw-r--r-- | src/w32menu.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/w32menu.c b/src/w32menu.c index a3bd82a0d7d..b977b90e52d 100644 --- a/src/w32menu.c +++ b/src/w32menu.c | |||
| @@ -129,7 +129,7 @@ typedef struct _widget_value | |||
| 129 | #define FALSE 0 | 129 | #define FALSE 0 |
| 130 | #endif /* no TRUE */ | 130 | #endif /* no TRUE */ |
| 131 | 131 | ||
| 132 | static HMENU current_popup_menu; | 132 | HMENU current_popup_menu; |
| 133 | 133 | ||
| 134 | void syms_of_w32menu (); | 134 | void syms_of_w32menu (); |
| 135 | void globals_of_w32menu (); | 135 | void globals_of_w32menu (); |
| @@ -1067,11 +1067,10 @@ menubar_selection_callback (FRAME_PTR f, void * client_data) | |||
| 1067 | buf.kind = MENU_BAR_EVENT; | 1067 | buf.kind = MENU_BAR_EVENT; |
| 1068 | buf.frame_or_window = frame; | 1068 | buf.frame_or_window = frame; |
| 1069 | buf.arg = entry; | 1069 | buf.arg = entry; |
| 1070 | kbd_buffer_store_event (&buf); | ||
| 1071 | |||
| 1072 | /* Free memory used by owner-drawn and help-echo strings. */ | 1070 | /* Free memory used by owner-drawn and help-echo strings. */ |
| 1073 | w32_free_menu_strings (FRAME_W32_WINDOW (f)); | 1071 | w32_free_menu_strings (FRAME_W32_WINDOW (f)); |
| 1074 | f->output_data.w32->menu_command_in_progress = 0; | 1072 | kbd_buffer_store_event (&buf); |
| 1073 | |||
| 1075 | f->output_data.w32->menubar_active = 0; | 1074 | f->output_data.w32->menubar_active = 0; |
| 1076 | return; | 1075 | return; |
| 1077 | } | 1076 | } |
| @@ -1080,7 +1079,6 @@ menubar_selection_callback (FRAME_PTR f, void * client_data) | |||
| 1080 | } | 1079 | } |
| 1081 | /* Free memory used by owner-drawn and help-echo strings. */ | 1080 | /* Free memory used by owner-drawn and help-echo strings. */ |
| 1082 | w32_free_menu_strings (FRAME_W32_WINDOW (f)); | 1081 | w32_free_menu_strings (FRAME_W32_WINDOW (f)); |
| 1083 | f->output_data.w32->menu_command_in_progress = 0; | ||
| 1084 | f->output_data.w32->menubar_active = 0; | 1082 | f->output_data.w32->menubar_active = 0; |
| 1085 | } | 1083 | } |
| 1086 | 1084 | ||