mirror of
https://github.com/MidnightCommander/mc
synced 2025-03-31 04:02:57 +03:00
Changed widget order in editor and viewer dialogs.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
e3f85ff6d0
commit
9b82c05fca
@ -203,7 +203,6 @@ edit_file (const char *_file, int line)
|
||||
{
|
||||
static int made_directory = 0;
|
||||
Dlg_head *edit_dlg;
|
||||
WButtonBar *edit_bar;
|
||||
|
||||
if (!made_directory) {
|
||||
char *dir = concat_dir_and_file (home_dir, EDIT_DIR);
|
||||
@ -221,22 +220,21 @@ edit_file (const char *_file, int line)
|
||||
create_dlg (0, 0, LINES, COLS, NULL, edit_dialog_callback,
|
||||
"[Internal File Editor]", NULL, DLG_WANT_TAB);
|
||||
|
||||
init_widget (&(wedit->widget), 0, 0, LINES - 1, COLS,
|
||||
edit_callback, edit_event);
|
||||
|
||||
widget_want_cursor (wedit->widget, 1);
|
||||
|
||||
edit_bar = buttonbar_new (1);
|
||||
add_widget (edit_dlg, edit_bar);
|
||||
|
||||
add_widget (edit_dlg, wedit);
|
||||
|
||||
edit_dlg->execute = edit_command_execute;
|
||||
edit_dlg->get_shortcut = edit_get_shortcut;
|
||||
edit_menubar = menubar_new (0, 0, COLS, NULL);
|
||||
add_widget (edit_dlg, edit_menubar);
|
||||
edit_init_menu (edit_menubar);
|
||||
|
||||
|
||||
init_widget (&(wedit->widget), 0, 0, LINES - 1, COLS,
|
||||
edit_callback, edit_event);
|
||||
widget_want_cursor (wedit->widget, 1);
|
||||
|
||||
add_widget (edit_dlg, wedit);
|
||||
|
||||
add_widget (edit_dlg, buttonbar_new (1));
|
||||
|
||||
run_dlg (edit_dlg);
|
||||
|
||||
destroy_dlg (edit_dlg);
|
||||
|
@ -263,7 +263,6 @@ mcview_viewer (const char *command, const char *file, int *move_dir_p, int start
|
||||
{
|
||||
gboolean succeeded;
|
||||
mcview_t *lc_mcview;
|
||||
WButtonBar *bar;
|
||||
Dlg_head *view_dlg;
|
||||
|
||||
/* Create dialog and widgets, put them on the dialog */
|
||||
@ -273,10 +272,8 @@ mcview_viewer (const char *command, const char *file, int *move_dir_p, int start
|
||||
|
||||
lc_mcview = mcview_new (0, 0, COLS, LINES - 1, 0);
|
||||
|
||||
bar = buttonbar_new (1);
|
||||
|
||||
add_widget (view_dlg, bar);
|
||||
add_widget (view_dlg, lc_mcview);
|
||||
add_widget (view_dlg, buttonbar_new (1));
|
||||
|
||||
succeeded = mcview_load (lc_mcview, command, file, start_line);
|
||||
if (succeeded) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user