diff options
| author | Jason Rumney | 2008-06-09 12:59:07 +0000 |
|---|---|---|
| committer | Jason Rumney | 2008-06-09 12:59:07 +0000 |
| commit | 02246cb835ab3cff40c5069c4860d1b1318be8be (patch) | |
| tree | 2e8c5703e0b2029ba3174aadd5b77490d6429ea5 /src | |
| parent | 3a408e5854572a5d8ea068c1fd1a981e4f8a37a2 (diff) | |
| download | emacs-02246cb835ab3cff40c5069c4860d1b1318be8be.tar.gz emacs-02246cb835ab3cff40c5069c4860d1b1318be8be.zip | |
(enum button_type, widget_value, local_heap, local_alloc):
(local_free, malloc_widget_value, free_widget_value):
(MENU_ITEMS_ITEM_NAME, MENU_ITEMS_ITEM_ENABLE, MENU_ITEMS_ITEM_VALUE):
(MENU_ITEMS_ITEM_EQUIV_KEY, MENU_ITEMS_ITEM_DEFINITION):
(MENU_ITEMS_ITEM_TYPE, MENU_ITEMS_ITEM_SELECTED, MENU_ITEMS_ITEM_HELP):
(MENU_ITEMS_ITEM_LENGTH, enum menu_item_idx): Remove defs.
(menu_items, menu_items_allocated, menu_items_used):
(menu_items_n_panes, menu_items_submenu_depth): Remove global vars.
(init_menu_items, finish_menu_items, discard_menu_items):
(grow_menu_items, push_submenu_start, push_submenu_end):
(push_left_right_boundary, push_menu_pane, push_menu_item,
(keymap_panes, single_keymap_panes, list_of_panes, list_of_items):
(free_menubar_widget_tree_value, parse_single_submenu):
(update_submenu_strings): Remove functions.
(xmalloc_widget_value): Remove and declare extern.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 33 | ||||
| -rw-r--r-- | src/w32menu.c | 27 |
2 files changed, 33 insertions, 27 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 9218f13193b..b0b036a821e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,36 @@ | |||
| 1 | 2008-06-09 Jason Rumney <jasonr@gnu.org> | ||
| 2 | |||
| 3 | Changes to w32 files related to the move of common menu code | ||
| 4 | to menu.c on 2008-06-08 by Chong Yidong. | ||
| 5 | |||
| 6 | * menu.c [HAVE_NTGUI]: Include w32term.h, move widget related | ||
| 7 | defs to w32gui.h. | ||
| 8 | (single_keymap_panes, push_menu_item, push_menu_pane): Make | ||
| 9 | globally visible. | ||
| 10 | |||
| 11 | * w32menu.c (enum button_type, widget_value, local_heap, local_alloc): | ||
| 12 | (local_free, malloc_widget_value, free_widget_value): | ||
| 13 | (MENU_ITEMS_ITEM_NAME, MENU_ITEMS_ITEM_ENABLE, MENU_ITEMS_ITEM_VALUE): | ||
| 14 | (MENU_ITEMS_ITEM_EQUIV_KEY, MENU_ITEMS_ITEM_DEFINITION): | ||
| 15 | (MENU_ITEMS_ITEM_TYPE, MENU_ITEMS_ITEM_SELECTED, MENU_ITEMS_ITEM_HELP): | ||
| 16 | (MENU_ITEMS_ITEM_LENGTH, enum menu_item_idx): Remove defs. | ||
| 17 | (menu_items, menu_items_allocated, menu_items_used): | ||
| 18 | (menu_items_n_panes, menu_items_submenu_depth): Remove global vars. | ||
| 19 | (init_menu_items, finish_menu_items, discard_menu_items): | ||
| 20 | (grow_menu_items, push_submenu_start, push_submenu_end): | ||
| 21 | (push_left_right_boundary, push_menu_pane, push_menu_item, | ||
| 22 | (keymap_panes, single_keymap_panes, list_of_panes, list_of_items): | ||
| 23 | (free_menubar_widget_tree_value, parse_single_submenu): | ||
| 24 | (update_submenu_strings): Remove functions. | ||
| 25 | (xmalloc_widget_value): Remove and declare extern. | ||
| 26 | |||
| 27 | * makefile.w32-in ($(SRC)/menu.$(O)): New target. | ||
| 28 | (OBJ1): Build it. | ||
| 29 | |||
| 30 | * w32gui.h (widget_value, XtPointer, Boolean, enum button_type): | ||
| 31 | (local_heap, local_alloc, local_free, malloc_widget_value): | ||
| 32 | (free_widget_value): Define here. | ||
| 33 | |||
| 1 | 2008-06-09 Kenichi Handa <handa@m17n.org> | 34 | 2008-06-09 Kenichi Handa <handa@m17n.org> |
| 2 | 35 | ||
| 3 | * font.h (Qascii_0): Extern it. | 36 | * font.h (Qascii_0): Extern it. |
diff --git a/src/w32menu.c b/src/w32menu.c index a689d472e71..a2d87abc67a 100644 --- a/src/w32menu.c +++ b/src/w32menu.c | |||
| @@ -620,33 +620,6 @@ menubar_selection_callback (FRAME_PTR f, void * client_data) | |||
| 620 | f->output_data.w32->menubar_active = 0; | 620 | f->output_data.w32->menubar_active = 0; |
| 621 | } | 621 | } |
| 622 | 622 | ||
| 623 | /* This recursively calls free_widget_value on the tree of widgets. | ||
| 624 | It must free all data that was malloc'ed for these widget_values. | ||
| 625 | In Emacs, many slots are pointers into the data of Lisp_Strings, and | ||
| 626 | must be left alone. */ | ||
| 627 | |||
| 628 | void | ||
| 629 | free_menubar_widget_value_tree (wv) | ||
| 630 | widget_value *wv; | ||
| 631 | { | ||
| 632 | if (! wv) return; | ||
| 633 | |||
| 634 | wv->name = wv->value = wv->key = (char *) 0xDEADBEEF; | ||
| 635 | |||
| 636 | if (wv->contents && (wv->contents != (widget_value*)1)) | ||
| 637 | { | ||
| 638 | free_menubar_widget_value_tree (wv->contents); | ||
| 639 | wv->contents = (widget_value *) 0xDEADBEEF; | ||
| 640 | } | ||
| 641 | if (wv->next) | ||
| 642 | { | ||
| 643 | free_menubar_widget_value_tree (wv->next); | ||
| 644 | wv->next = (widget_value *) 0xDEADBEEF; | ||
| 645 | } | ||
| 646 | BLOCK_INPUT; | ||
| 647 | free_widget_value (wv); | ||
| 648 | UNBLOCK_INPUT; | ||
| 649 | } | ||
| 650 | 623 | ||
| 651 | /* Set up data i menu_items for a menu bar item | 624 | /* Set up data i menu_items for a menu bar item |
| 652 | whose event type is ITEM_KEY (with string ITEM_NAME) | 625 | whose event type is ITEM_KEY (with string ITEM_NAME) |