Mercurial > emacs
view oldXMenu/Post.c @ 47488:6ca0edea0a56
(dired-use-ls-dired): New variable.
(dired-directory): Document the rules better.
(dired-insert-headerline): Function deleted.
(dired-revert): Pass no args to dired-readin.
(dired-move-to-filename): First try using dired-filename property.
(dired-move-to-end-of-filename): Likewise.
(dired-why): Try to show the start of this page of warnings.
(dired-log): Insert the buffer name at start of page, not end.
(dired-log-summary): If just one failure, explain it in echo area.
(dired-internal-noselect): Always set dired-directory, when buffer is not new.
Pass dir-or-list, not dirname, to dired-mode.
Call dired-readin with no args.
Don't call dired-after-readin-hook here.
(dired-find-buffer-nocreate): Expand dirname.
Expand the dir from dired-directory to compare with dirname.
(dired-readin): Take no args. Get the directory from dired-directory.
Run dired-before-reading hook inside save-excursion.
Run dired-after-readin-hook here.
Don't make undo entries at all.
Call dired-readin-insert with no args.
Don't change indentation here.
Don't insert headerline here.
(dired-readin-insert): Take no args.
Get dir and file-list from dired-directory.
Call dired-insert-directory the new way.
Don't insert "wildcard" info here.
(dired-insert-directory): New arg FILE-LIST.
First arg now DIR, always just the directory.
This function fully handles setting up the buffer text:
update indentation, insert headerline and "wildcard" info.
Pass --dired arg if appropriate; put info in dired-filename props.
Don't expand file names here.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Sun, 15 Sep 2002 01:52:54 +0000 |
parents | 4a9ea0d1735b |
children | 23a1cea22d13 |
line wrap: on
line source
#include "copyright.h" /* $Header: /gd/gnu/cvsroot/emacs/oldXMenu/Post.c,v 1.1 1999/10/03 19:35:10 fx Exp $ */ /* Copyright Massachusetts Institute of Technology 1985 */ /* * XMenu: MIT Project Athena, X Window system menu package * * XMenuPost - Maps a given menu to the display and activates * the menu for user selection. The user is allowed to * specify the mouse button event mask that will be used * to identify a selection request. When a selection * request is received (i.e., when the specified mouse * event occurs) the data returned will be either the * data associated with the particular selection active * at the time of the selection request or NULL if no * selection was active. A menu selection is shown to * be active by placing a highlight box around the * selection as the mouse cursor enters its active * region. Inactive selections will not be highlighted. * As the mouse cursor moved from one menu pane * to another menu pane the pane being entered is raised * and activated and the pane being left is deactivated. * If an error occurs NULL will be returned with the * p_num set to POST_ERROR, s_num set to * NO_SELECTION and _XMErrorCode set to an * appropriate value. * Every time the routine returns successfully the * p_num and s_num indices will be set to indicate * the currently active pane and/or selection. If the * mouse was not in a selection window at the time * s_num will be set to NO_SELECTION. * * Author: Tony Della Fera, DEC * August, 1984 * */ #include "XMenuInt.h" char * XMenuPost(display, menu, p_num, s_num, x_pos, y_pos, event_mask) register Display *display; /* Previously opened display. */ register XMenu *menu; /* Menu to post. */ register int *p_num; /* Pane number selected. */ register int *s_num; /* Selection number selected. */ register int x_pos; /* X coordinate of menu position. */ register int y_pos; /* Y coordinate of menu position. */ int event_mask; /* Mouse button event mask. */ { register int stat; /* Routine call return status. */ char *data; /* Return data. */ /* * Set up initial pane and selection assumptions. */ /* * Make the procedure call. */ stat = XMenuActivate( display, menu, p_num, s_num, x_pos, y_pos, event_mask, &data, 0); /* * Check the return value and return accordingly. */ switch (stat) { case XM_FAILURE: *p_num = POST_ERROR; *s_num = NO_SELECTION; return(NULL); case XM_NO_SELECT: case XM_IA_SELECT: *s_num = NO_SELECTION; return(NULL); case XM_SUCCESS: default: return(data); } }