1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-30 00:51:50 -08:00
Commit graph

72 commits

Author SHA1 Message Date
Eli Zaretskii
71d00ce4ae (grow_menu_items): Use larger_vector. 2007-10-13 12:11:14 +00:00
Miles Bader
aaf34461ff Merge from emacs--devo--0
Patches applied:

 * emacs--devo--0  (patch 846-851)

   - Update from CVS
   - Merge from emacs--rel--22

 * emacs--rel--22  (patch 88-92)

   - Update from CVS
   - Merge from gnus--rel--5.10

 * gnus--rel--5.10  (patch 242-244)

   - Update from CVS

Revision: emacs@sv.gnu.org/emacs--multi-tty--0--patch-31
2007-08-13 13:51:08 +00:00
YAMAMOTO Mitsuharu
cbc179a3fd (quit_dialog_event_loop) [TARGET_API_MAC_CARBON]:
New variable.
[TARGET_API_MAC_CARBON] (mac_handle_dialog_event): Set it if dialog
event loop should be quit.
[TARGET_API_MAC_CARBON] (create_and_show_dialog) [!MAC_OSX]:
Quit dialog event loop if quit_dialog_event_loop is set.
2007-08-06 08:25:30 +00:00
Miles Bader
9899d01a0c Merge from emacs--devo--0
Patches applied:

 * emacs--devo--0  (patch 824-838)

   - Update from CVS
   - Merge from emacs--rel--22
   - Remove lisp/erc/erc-nicklist.el
   - Update some .arch-inventory files
   - Fix void function definition error in cus-edit.el
   - Restore lisp/emacs-lisp/cl-loaddefs.el

 * emacs--rel--22  (patch 70-83)

   - Update from CVS
   - Remove lisp/erc/erc-nicklist.el
   - Update some .arch-inventory files
   - Indicate that emacs--devo--0--patch-834 does not need to be applied
   - Merge from gnus--rel--5.10
   - Restore lisp/emacs-lisp/cl-loaddefs.el

 * gnus--rel--5.10  (patch 239-241)

   - Merge from emacs--devo--0
   - Update from CVS

Revision: emacs@sv.gnu.org/emacs--multi-tty--0--patch-28
2007-07-31 05:50:45 +00:00
Miles Bader
9aecacd08a Merge from emacs--rel--22
Patches applied:

 * emacs--rel--22  (patch 70-73)

   - Update from CVS

2007-07-25  Glenn Morris  <rgm@gnu.org>

   * Relicense all FSF files to GPLv3 or later.

Revision: emacs@sv.gnu.org/emacs--devo--0--patch-828
2007-07-26 05:28:10 +00:00
Glenn Morris
684d6f5bcc Switch license to GPLv3 or later. 2007-07-25 05:19:07 +00:00
Miles Bader
7eb1e4534e Merge from emacs--devo--0
Patches applied:

 * emacs--devo--0  (patch 803-813)

   - Update from CVS
   - Merge from emacs--rel--22

 * emacs--rel--22  (patch 51-58)

   - Update from CVS
   - Merge from gnus--rel--5.10

 * gnus--rel--5.10  (patch 233-236)

   - Merge from emacs--devo--0
   - Update from CVS

Revision: emacs@sv.gnu.org/emacs--multi-tty--0--patch-25
2007-07-15 02:05:20 +00:00
YAMAMOTO Mitsuharu
512eb16107 (mac_dialog_modal_filter, Fx_popup_dialog) [MAC_OSX]:
Put special treatment for Fmessage_box, Fyes_or_no_p, and Fy_or_n_p
in #if 0 as it is not compatible with y-or-n-p-with-timeout.
(timer_check) [TARGET_API_MAC_CARBON]: Add extern.
[TARGET_API_MAC_CARBON] (mac_handle_dialog_event): Use QuitEventLoop
instead of QuitAppModalLoopForWindow.  Consolidate QuitEventLoop calls.
(pop_down_dialog) [TARGET_API_MAC_CARBON]: New function.
[TARGET_API_MAC_CARBON] (create_and_show_dialog): Use it for unwind.
Run timers during dialog popup.
(Fmenu_or_popup_active_p) [TARGET_API_MAC_CARBON]: Use popup_activated.
2007-06-22 09:05:55 +00:00
Miles Bader
262d5ce7c2 Merge from emacs--devo--0
Patches applied:

 * emacs--devo--0  (patch 793-802)

   - Update from CVS
   - Remove RCS keywords
   - Merge from emacs--rel--22

 * emacs--rel--22  (patch 42-50)

   - Update from CVS
   - Merge from gnus--rel--5.10
   - Gnus ChangeLog tweaks

 * gnus--rel--5.10  (patch 229-232)

   - Merge from emacs--devo--0, emacs--rel--22
   - ChangeLog tweak
   - Update from CVS

Revision: emacs@sv.gnu.org/emacs--multi-tty--0--patch-23
2007-06-16 22:33:42 +00:00
YAMAMOTO Mitsuharu
1bd0c76127 [TARGET_API_MAC_CARBON] (menu_target_item_handler):
Return immediately unless popup is activated.
2007-06-14 08:39:19 +00:00
Miles Bader
67f3ad67ee Merge from emacs--devo--0
Patches applied:

 * emacs--devo--0  (patch 781-792)

   - Update from CVS
   - Merge from gnus--rel--5.10
   - Merge from emacs--rel--22

 * emacs--rel--22  (patch 33-41)
 * gnus--rel--5.10  (patch 226-228)

   - Update from CVS

Revision: emacs@sv.gnu.org/emacs--multi-tty--0--patch-21
2007-06-11 01:00:07 +00:00
YAMAMOTO Mitsuharu
b52ee0bd9a [TARGET_API_MAC_CARBON] (menu_target_item_handler):
Don't call next handler.
[TARGET_API_MAC_CARBON] (install_menu_target_item_handler):
Remove argument.  Install handler to application.
(set_frame_menubar): Don't change deep_p.
(mac_menu_show):  Use FRAME_OUTER_TO_INNER_DIFF_X and
FRAME_OUTER_TO_INNER_DIFF_Y.
(DIALOG_BUTTON_COMMAND_ID_OFFSET, DIALOG_BUTTON_COMMAND_ID_P)
(DIALOG_BUTTON_COMMAND_ID_VALUE, DIALOG_BUTTON_MAKE_COMMAND_ID)
[HAVE_DIALOGS]: New macros.
[HAVE_DIALOGS] (mac_handle_dialog_event, create_and_show_dialog):
Use them.
(fill_menubar) [TARGET_API_MAC_CARBON]: Use CFString.
2007-06-07 08:44:33 +00:00
YAMAMOTO Mitsuharu
477f75a567 Replace MenuHandle and GetMenuHandle with MenuRef and
GetMenuRef, respectively.  Replace WindowPtr with WindowRef.
Replace ControlHandle with ControlRef.
(install_menu_quit_handler): Rename arg MENU_HANDLE to ROOT_MENU.
2007-06-06 08:33:01 +00:00
Dan Nicolaescu
80ca7302d8 * s/darwin.h (SYSTEM_PURESIZE_EXTRA): Define here.
* termhooks.h (union display_info): Add mac_display_info.

* term.c (init_tty): Only use terminal->kboard when MULTI_KBOARD
is defined.

* macterm.h (struct mac_display_info): Add terminal.

* w32term.c (w32_initialize): Make static.

* macterm.c (XTset_terminal_modes): Add a terminal parameter.
(XTreset_terminal_modes): Likewise.
(x_clear_frame): Add a frame parameter.
(note_mouse_movement): Get rif from the frame.
(mac_term_init): Initialize the terminal.
(mac_initialize): Make static and move terminal initialization ...
(mac_create_terminal): ... in this new function.

* macmenu.c: Reorder includes.
(Fx_popup_menu): Use terminal specific mouse_position_hook.

* macfns.c (x_set_mouse_color): Get rif from the frame.
(x_set_tool_bar_lines): Don't use updating_frame.
(mac_window): Add 2 new parameters for consistency with other
systems.
(Fx_create_frame): Fix doc string. Rename the parameter.
(Fx_create_frame): Set the frame parameters following what is done
in X11 and w32.
(Fx_open_connection): Remove window-system check.
(start_hourglass): Likewise.
(x_create_tip_frame): Get the keyboard from the terminal.

* w32fns.c (Fx_create_frame): Use kboard from the terminal.

* term/mac-win.el: Provide mac-win.
(mac-initialized): New variable.
(mac-initialize-window-system): New function. Move global setup
here.
(handle-args-function-alist, frame-creation-function-alist):
(window-system-initialization-alist): Add mac entries.

* loadup.el: Load mac-win on a Mac.
2007-05-19 19:08:02 +00:00
YAMAMOTO Mitsuharu
0f6da68b85 (mac_dialog_show): Apply 2007-04-27 change for xmenu.c.
(Fx_popup_dialog) [MAC_OSX]: Likewise.
2007-05-01 08:17:19 +00:00
YAMAMOTO Mitsuharu
b28d7564a8 (mac_dialog_show): Apply 2007-04-27 change for xmenu.c.
(Fx_popup_dialog) [MAC_OSX]: Likewise.
2007-05-01 08:15:56 +00:00
YAMAMOTO Mitsuharu
a83c3e315f (popup_activated_flag): New variable.
(x_activate_menubar, mac_menu_show): Set it during menu tracking.
(popup_activated): New function.
2007-03-18 08:06:18 +00:00
YAMAMOTO Mitsuharu
356ce658c8 (mac_menu_show): Call unbind_to early. Use variable
`menu_item_selection' as in W32 version.
[TARGET_API_MAC_CARBON] (mac_handle_dialog_event): Add explicit
braces to avoid ambiguous `else'.
2007-02-23 08:25:58 +00:00
Glenn Morris
4e6835dbc4 Add 2007 to copyright years. 2007-01-21 04:57:37 +00:00
YAMAMOTO Mitsuharu
9a5a6add27 [TARGET_API_MAC_CARBON] (create_and_show_dialog):
Create movable modal window instead of movable alert window.
[TARGET_API_MAC_CARBON] (create_and_show_dialog) [!MAC_OSX]: Use
DeactivateControl instead of DisableControl.
2007-01-15 08:35:49 +00:00
YAMAMOTO Mitsuharu
28c96b4d92 [TARGET_API_MAC_CARBON] (create_and_show_dialog): Use
DisableControl for disabled items.  Set default button to first
enabled one.  Use icon of application in execution.
2007-01-14 07:58:02 +00:00
YAMAMOTO Mitsuharu
28eabd14f7 (HAVE_DIALOGS): Define if TARGET_API_MAC_CARBON.
(mac_handle_dialog_event, install_dialog_event_handler)
(create_and_show_dialog) [TARGET_API_MAC_CARBON]: New functions.
(DIALOG_LEFT_MARGIN, DIALOG_TOP_MARGIN, DIALOG_RIGHT_MARGIN)
(DIALOG_BOTTOM_MARGIN, DIALOG_MIN_INNER_WIDTH)
(DIALOG_MAX_INNER_WIDTH, DIALOG_BUTTON_BUTTON_HORIZONTAL_SPACE)
(DIALOG_BUTTON_BUTTON_VERTICAL_SPACE, DIALOG_BUTTON_MIN_WIDTH)
(DIALOG_TEXT_MIN_HEIGHT, DIALOG_TEXT_BUTTONS_VERTICAL_SPACE)
(DIALOG_ICON_WIDTH, DIALOG_ICON_HEIGHT, DIALOG_ICON_LEFT_MARGIN)
(DIALOG_ICON_TOP_MARGIN) [TARGET_API_MAC_CARBON]: New macros.
(mac_dialog) [TARGET_API_MAC_CARBON]: Remove function.
(mac_dialog_show) [TARGET_API_MAC_CARBON]: Use create_and_show_dialog.
2007-01-12 09:00:16 +00:00
YAMAMOTO Mitsuharu
7dcebea43a (mac_dialog_modal_filter) [MAC_OSX]: New function.
(Fx_popup_dialog) [MAC_OSX]: Use standard alert if called from
Fmessage_box, Fyes_or_no_p, or Fy_or_n_p.
[MAC_OS_X_VERSION_MAX_ALLOWED >= 1030] (menu_quit_handler): Use
mac_quit_char_key_p.
2007-01-09 08:53:48 +00:00
YAMAMOTO Mitsuharu
0aea47c1ee (Vshow_help_function) [TARGET_API_MAC_CARBON]: Add extern.
(restore_show_help_function, menu_target_item_handler)
[TARGET_API_MAC_CARBON]: New functions.
(install_menu_target_item_handler): New function.
(add_menu_item) [TARGET_API_MAC_CARBON]: Set help string as menu
item property.
2007-01-05 08:30:05 +00:00
YAMAMOTO Mitsuharu
74e537fb69 (menu_quit_handler, install_menu_quit_handler):
Replace `#ifdef HAVE_CANCELMENUTRACKING' with
`#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1030'.
(install_menu_quit_handler) [MAC_OS_X_VERSION_MAX_ALLOWED >= 1030
&& MAC_OS_X_VERSION_MIN_REQUIRED == 1020]: Check if
CancelMenuTracking is available.
2006-11-14 08:22:04 +00:00
Chong Yidong
c1f043a063 (Fmenu_or_popup_active_p): Define outside HAVE_MENUS. 2006-11-06 16:47:07 +00:00
Eli Zaretskii
0ec2e29e9b (Fmenu_or_popup_active_p): New function.
(syms_of_macmenu): Defsubr it.
2006-11-05 12:16:51 +00:00
YAMAMOTO Mitsuharu
37a39780ff (install_menu_quit_handler): Make variable `typesList'
static const.
(name_is_separator): Add const qualifier to arguments.
2006-10-31 08:32:08 +00:00
YAMAMOTO Mitsuharu
b0da976d49 (enum mac_menu_kind, min_menu_id): New enumerator and
menu ID for Apple menu.
(menubar_selection_callback): Remove function.
(find_and_call_menu_selection): New function from xmenu.c.
(x_activate_menubar): Use it.
(set_frame_menubar): Don't use f->output_data.mac->menubar_active.
2006-09-19 03:18:22 +00:00
YAMAMOTO Mitsuharu
0e9ffc04d9 * src/macmenu.c (Vmenu_updating_frame, syms_of_xmenu):
* src/w32menu.c (Vmenu_updating_frame, syms_of_xmenu): Apply
2006-09-08 change for xmenu.c.
2006-09-10 05:52:01 +00:00
YAMAMOTO Mitsuharu
0e530e3b36 (restore_menu_items, cleanup_popup_menu): Return a value. 2006-05-05 06:44:10 +00:00
YAMAMOTO Mitsuharu
f1d7196a17 (restore_menu_items, save_menu_items): New functions from xmenu.c.
(set_frame_menubar, digest_single_submenu): Apply 2006-04-18
changes for xmenu.c.
2006-04-21 07:56:47 +00:00
YAMAMOTO Mitsuharu
3e7f257019 (min_menu_id): Make element type explicit. 2006-04-12 08:07:48 +00:00
YAMAMOTO Mitsuharu
e2e206ae66 (enum mac_menu_kind): New enum.
(min_menu_id): New variable.
(POPUP_SUBMENU_ID, MIN_POPUP_SUBMENU_ID, MIN_MENU_ID)
(MIN_SUBMENU_ID): Remove defines.  All uses are replaced with
min_menu_id and enumerators in enum mac_menu_kind.
(fill_menu, dispose_menus, install_menu_quit_handler): New arg KIND.
All uses changed.  Add range check for menu ID.
(fill_menubar): Add range check for menu ID.
[HAVE_CANCELMENUTRACKING] (menu_quit_handler): Check error code of
GetEventParameter.
(set_frame_menubar, mac_menu_show): Call install_menu_quit_handler
for each menu kind.
2006-03-24 08:12:36 +00:00
YAMAMOTO Mitsuharu
e188aa29a9 (digest_single_submenu): Apply 2006-02-19 change for xmenu.c. 2006-02-22 07:59:34 +00:00
YAMAMOTO Mitsuharu
0f745bcf79 (popup_activated_flag, submenu_id)
(next_menubar_widget_id): Remove variables.
(initialize_frame_menubar): Remove function.
(pop_down_menu, mac_menu_show): Simplify save value.
(dispose_menus): New function.
(pop_down_menu, fill_menubar): Use it.
(fill_submenu): Remove function.  All uses changed to fill_menu.
(add_menu_item): Remove args SUBMENU and FORCE_DISABLE.  New arg
POS.  Don't call SetMenuItemHierarchicalID here.
(fill_menu): Add arg SUBMENU_ID.  Return submenu_id that is to be
used next.  Call SetMenuItemHierarchicalID here.
(fill_menubar): Add arg DEEP_P.  All uses changed.  Clean up menu
objects if needed.  Reuse existing menu bar titles if possible.
(set_frame_menubar): Don't clean up menu objects here.
2006-02-19 07:33:13 +00:00
YAMAMOTO Mitsuharu
f036d043ab (set_frame_menubar): Don't call DrawMenuBar. 2006-02-15 08:42:12 +00:00
Thien-Thi Nguyen
aaef169dc6 Update years in copyright notice; nfc. 2006-02-06 15:23:23 +00:00
YAMAMOTO Mitsuharu
4036ffb904 (Qmac_apple_event): Add extern.
(set_frame_menubar, mac_menu_show keymp_panes)
(single_keymap_panes, list_of_panes, list_of_item)
(single_menu_item): Add argument types to prototypes.
(mac_dialog_show) [HAVE_DIALOGS]: Likewise.
(struct skp): New struct (from xmenu.c).
(single_keymap_panes, single_menu_item, list_of_panes)
(list_of_item): Sync with xmenu.c.
(Fx_popup_menu, Fx_popup_dialog): Likewise.  Don't get window from
POSITION if it is mac-apple-event event.
(menubar_selection_callback): Don't use menu_command_in_progress.
(set_frame_menubar): First parse all submenus, then make
widget_value trees from them.  Don't allocate any widget_value
objects until we are done with the parsing.
(parse_single_submenu, digest_single_submenu): New functions.
(single_submenu): Function deleted, replaced by those two.
(install_menu_quit_handler) [HAVE_CANCELMENUTRACKING]: Don't
create or dispose of EventHandlerUPP.  Install hander to all submenus.
(mac_menu_show) [!HAVE_MULTILINGUAL_MENU]: Use ENCODE_MENU_STRING
instead of ENCODE_SYSTEM.
(free_frame_menubar, fill_submenu, fill_menu): Don't use NULL for
integer values.
[HAVE_DIALOGS] (mac_dialog_show): Sync with xdialog_show (in xmenu.c).
(add_menu_item) [TARGET_API_MAC_CARBON]: Use CFString functions to
format menu item string.  Don't use NULL for integer value.
2005-12-21 12:31:02 +00:00
Juri Linkov
c1d9dffd9a (Fx_popup_menu): Add `else' to set Vmenu_updating_frame to nil
only if position is nil.
2005-12-20 21:38:27 +00:00
Thien-Thi Nguyen
0b5538bd85 Update years in copyright notice; nfc. 2005-08-07 12:33:19 +00:00
YAMAMOTO Mitsuharu
50971a123a (Fx_popup_menu, Fx_popup_menu): Doc fixes. 2005-07-23 07:48:26 +00:00
Lute Kamstra
4fc5845fe8 Update FSF's address. 2005-07-04 16:49:24 +00:00
Kim F. Storm
89f2614d96 * composite.c (compose_chars_in_text):
* eval.c (do_autoload):
* macmenu.c (set_frame_menubar):
* process.c (read_process_output, exec_sentinel):
* xmenu.c (set_frame_menubar):
* xdisp.c (prepare_menu_bars, update_menu_bar, update_tool_bar):
* w32menu.c (set_frame_menubar):
Use record_unwind_save_match_data.
Rename restore_match_data to restore_search_regs.
2005-06-08 22:33:36 +00:00
Jan Djärv
f5f870c03c * macmenu.c (menu_quit_handler, install_menu_quit_handler): New
functions for popping down menus on C-g.
 (set_frame_menubar, mac_menu_show): Call install_menu_quit_handler.
2005-06-06 20:24:13 +00:00
Jan Djärv
b89875707c * macmenu.c (cleanup_popup_menu): New function.
(Fx_popup_menu): unwind protect cleanup_popup_menu in case
mac_menu_show Quit:s.
(mac_menu_show): Quit on cancel if not popped up on click (i.e.
a dialog).
2005-06-04 08:06:57 +00:00
Nick Roberts
16b1266812 (Fx_popup_dialog): Allow 3rd optional argument. 2005-05-24 08:45:35 +00:00
Nick Roberts
3f2975360c (Fx_popup_dialog): Add a third boolean argument to select frame title
("Question"/"Information").
(mac_dialog_show): Use it.
2005-05-24 08:42:23 +00:00
YAMAMOTO Mitsuharu
b78c807ab4 Don't include signal.h. 2005-05-13 08:43:18 +00:00
YAMAMOTO Mitsuharu
04b5475bff [TARGET_API_MAC_CARBON]: Don't include headers that are included via
Carbon.h.
2005-03-04 11:09:33 +00:00