Changed widget order in editor and viewer dialogs.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Этот коммит содержится в:
родитель
e3f85ff6d0
Коммит
9b82c05fca
@ -203,7 +203,6 @@ edit_file (const char *_file, int line)
|
|||||||
{
|
{
|
||||||
static int made_directory = 0;
|
static int made_directory = 0;
|
||||||
Dlg_head *edit_dlg;
|
Dlg_head *edit_dlg;
|
||||||
WButtonBar *edit_bar;
|
|
||||||
|
|
||||||
if (!made_directory) {
|
if (!made_directory) {
|
||||||
char *dir = concat_dir_and_file (home_dir, EDIT_DIR);
|
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,
|
create_dlg (0, 0, LINES, COLS, NULL, edit_dialog_callback,
|
||||||
"[Internal File Editor]", NULL, DLG_WANT_TAB);
|
"[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->execute = edit_command_execute;
|
||||||
edit_dlg->get_shortcut = edit_get_shortcut;
|
edit_dlg->get_shortcut = edit_get_shortcut;
|
||||||
edit_menubar = menubar_new (0, 0, COLS, NULL);
|
edit_menubar = menubar_new (0, 0, COLS, NULL);
|
||||||
add_widget (edit_dlg, edit_menubar);
|
add_widget (edit_dlg, edit_menubar);
|
||||||
edit_init_menu (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);
|
run_dlg (edit_dlg);
|
||||||
|
|
||||||
destroy_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;
|
gboolean succeeded;
|
||||||
mcview_t *lc_mcview;
|
mcview_t *lc_mcview;
|
||||||
WButtonBar *bar;
|
|
||||||
Dlg_head *view_dlg;
|
Dlg_head *view_dlg;
|
||||||
|
|
||||||
/* Create dialog and widgets, put them on the dialog */
|
/* 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);
|
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, lc_mcview);
|
||||||
|
add_widget (view_dlg, buttonbar_new (1));
|
||||||
|
|
||||||
succeeded = mcview_load (lc_mcview, command, file, start_line);
|
succeeded = mcview_load (lc_mcview, command, file, start_line);
|
||||||
if (succeeded) {
|
if (succeeded) {
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user