1
1

Optimization: ret rid of select_item() call

...after go to the found file or directory.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Этот коммит содержится в:
Andrew Borodin 2010-11-05 15:53:01 +03:00
родитель f5a93bf74c
Коммит 885b1b4f82

Просмотреть файл

@ -1511,27 +1511,24 @@ do_find (void)
if (v == B_ENTER) if (v == B_ENTER)
{ {
if (dirname || filename) if (dirname != NULL)
{
if (dirname)
{ {
do_cd (dirname, cd_exact); do_cd (dirname, cd_exact);
if (filename) if (filename != NULL)
try_to_select (current_panel, filename + (content ? try_to_select (current_panel,
(strchr (filename + 4, ':') - filename + (content != NULL
filename + 1) : 4)); ? strchr (filename + 4, ':') - filename + 1 : 4));
} }
else if (filename) else if (filename != NULL)
do_cd (filename, cd_exact); do_cd (filename, cd_exact);
select_item (current_panel);
}
g_free (dirname); g_free (dirname);
g_free (filename); g_free (filename);
break; break;
} }
g_free (content); g_free (content);
dir_and_file_set = dirname && filename; dir_and_file_set = (dirname != NULL) && (filename != NULL);
g_free (dirname); g_free (dirname);
g_free (filename); g_free (filename);