* boxes.c (display_init): Associate correct help topic.

(sort_box): Likewise.
(set_panel_filter): Likewise.
* option.c (init_configure): Likewise.
* menu.c (menubar_handle_key): Show help dependent on the active
menu.
This commit is contained in:
Pavel Roskin 2001-08-06 22:22:04 +00:00
parent 1e23c4fb68
commit d05bfe1f01
5 changed files with 40 additions and 5 deletions

View File

@ -1,3 +1,12 @@
2001-08-06 Pavel Roskin <proski@gnu.org>
* boxes.c (display_init): Associate correct help topic.
(sort_box): Likewise.
(set_panel_filter): Likewise.
* option.c (init_configure): Likewise.
* menu.c (menubar_handle_key): Show help dependent on the active
menu.
2001-08-06 Andrew V. Samoilov <kai@cmail.ru> 2001-08-06 Andrew V. Samoilov <kai@cmail.ru>
* mad.c (mad_strdup): Return NULL if NULL is passed. * mad.c (mad_strdup): Return NULL if NULL is passed.

View File

@ -187,7 +187,7 @@ display_init (int radio_sel, char *init_text,
i18n_displays_flag = 1; i18n_displays_flag = 1;
} }
dd = create_dlg (0, 0, DISPLAY_Y, DISPLAY_X, dialog_colors, dd = create_dlg (0, 0, DISPLAY_Y, DISPLAY_X, dialog_colors,
display_callback, "[Left and Right Menus]", "display", display_callback, "[Listing Mode...]", "display",
DLG_CENTER | DLG_GRID); DLG_CENTER | DLG_GRID);
x_set_dialog_title (dd, _("Listing mode")); x_set_dialog_title (dd, _("Listing mode"));
@ -330,7 +330,7 @@ sort_box (sortfn *sort_fn, int *reverse, int *case_sensitive)
} }
dd = create_dlg (0, 0, SORT_Y, SORT_X, dialog_colors, common_dialog_callback, dd = create_dlg (0, 0, SORT_Y, SORT_X, dialog_colors, common_dialog_callback,
"[Left and Right Menus]", "sort", DLG_CENTER | DLG_GRID); "[Sort Order...]", "sort", DLG_CENTER | DLG_GRID);
x_set_dialog_title (dd, sort_title); x_set_dialog_title (dd, sort_title);

View File

@ -449,7 +449,9 @@ void set_panel_filter (WPanel *p)
x = p->filter ? p->filter : easy_patterns ? "*" : "."; x = p->filter ? p->filter : easy_patterns ? "*" : ".";
reg_exp = input_dialog (_(" Filter "), _(" Set expression for filtering filenames"), x); reg_exp = input_dialog_help (_(" Filter "),
_(" Set expression for filtering filenames"),
"[Filter...]", x);
if (!reg_exp) if (!reg_exp)
return; return;
set_panel_filter_to (p, reg_exp); set_panel_filter_to (p, reg_exp);

View File

@ -16,13 +16,14 @@
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <config.h> #include <config.h>
#include "tty.h"
#include <string.h> #include <string.h>
#include <stdarg.h> #include <stdarg.h>
#include <sys/types.h> #include <sys/types.h>
#include <ctype.h> #include <ctype.h>
#include "global.h" #include "global.h"
#include "tty.h"
#include "menu.h" #include "menu.h"
#include "help.h"
#include "dialog.h" #include "dialog.h"
#include "color.h" #include "color.h"
#include "main.h" #include "main.h"
@ -269,6 +270,29 @@ static int menubar_handle_key (WMenu *menubar, int key)
return 1; return 1;
} }
if (key == KEY_F(1)) {
if (menubar->dropped) {
switch (menubar->selected) {
case 1:
interactive_display (NULL, "[File Menu]");
break;
case 2:
interactive_display (NULL, "[Command Menu]");
break;
case 3:
interactive_display (NULL, "[Options Menu]");
break;
default:
interactive_display (NULL, "[Left and Right Menus]");
break;
}
} else {
interactive_display (NULL, "[Menu Bar]");
}
menubar_draw (menubar);
return 1;
}
if (key == KEY_LEFT || key == XCTRL('b')){ if (key == KEY_LEFT || key == XCTRL('b')){
menubar_left (menubar); menubar_left (menubar);
return 1; return 1;

View File

@ -193,7 +193,7 @@ static void init_configure (void)
} }
conf_dlg = create_dlg (0, 0, 20, first_width + second_width + 9, conf_dlg = create_dlg (0, 0, 20, first_width + second_width + 9,
dialog_colors, configure_callback, "[Options Menu]", dialog_colors, configure_callback, "[Configuration]",
"option", DLG_CENTER | DLG_GRID); "option", DLG_CENTER | DLG_GRID);
x_set_dialog_title (conf_dlg, _("Configure options")); x_set_dialog_title (conf_dlg, _("Configure options"));