Merge branch '1750_view_next_prev_file'
* 1750_view_next_prev_file: Sync argument name of mcview_viewer() function in header and in source files. Ticket #1750: fix of view next/prev file in viewer.
Этот коммит содержится в:
Коммит
45d8208ff6
@ -307,10 +307,6 @@ mcview_execute_cmd (mcview_t * view, int command, int key)
|
||||
case CK_ViewMoveRight:
|
||||
mcview_move_right (view, 1);
|
||||
break;
|
||||
case CK_ViewQuit:
|
||||
if (mcview_ok_to_quit (view))
|
||||
view->want_to_quit = TRUE;
|
||||
break;
|
||||
case CK_ViewSearch:
|
||||
view->search_type = MC_SEARCH_T_REGEX;
|
||||
mcview_search_cmd (view);
|
||||
@ -357,23 +353,22 @@ mcview_execute_cmd (mcview_t * view, int command, int key)
|
||||
view->dpy_start = view->marks[view->marker];
|
||||
view->dirty++;
|
||||
break;
|
||||
case CK_ViewNextFile:
|
||||
/* Use to indicate parent that we want to see the next/previous file */
|
||||
/* Does not work in panel mode */
|
||||
if (!mcview_is_in_panel (view))
|
||||
view->move_dir = 1;
|
||||
break;
|
||||
case CK_ViewPrevFile:
|
||||
/* Use to indicate parent that we want to see the next/previous file */
|
||||
/* Does not work in panel mode */
|
||||
if (!mcview_is_in_panel (view))
|
||||
view->move_dir = -1;
|
||||
break;
|
||||
case CK_SelectCodepage:
|
||||
mcview_select_encoding (view);
|
||||
view->dirty++;
|
||||
mcview_update (view);
|
||||
break;
|
||||
case CK_ViewNextFile:
|
||||
case CK_ViewPrevFile:
|
||||
/* Use to indicate parent that we want to see the next/previous file */
|
||||
/* Does not work in panel mode */
|
||||
if (!mcview_is_in_panel (view))
|
||||
view->move_dir = (command == CK_ViewNextFile) ? 1 : -1;
|
||||
/* fallthrough */
|
||||
case CK_ViewQuit:
|
||||
if (mcview_ok_to_quit (view))
|
||||
view->want_to_quit = TRUE;
|
||||
break;
|
||||
default :
|
||||
res = MSG_NOT_HANDLED;
|
||||
}
|
||||
|
@ -38,12 +38,12 @@ extern struct mcview_struct *mcview_new (int, int, int, int, int);
|
||||
|
||||
|
||||
/* Shows {file} or the output of {command} in the internal viewer,
|
||||
* starting in line {start_line}. {ret_move_direction} may be NULL or
|
||||
* starting in line {start_line}. {move_dir_p} may be NULL or
|
||||
* point to a variable that will receive the direction in which the user
|
||||
* wants to move (-1 = previous file, 1 = next file, 0 = do nothing).
|
||||
*/
|
||||
extern int mcview_viewer (const char *command, const char *file,
|
||||
int *ret_move_direction, int start_line);
|
||||
int *move_dir_p, int start_line);
|
||||
|
||||
extern gboolean mcview_load (struct mcview_struct *, const char *, const char *, int);
|
||||
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user