mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 08:21:12 +02:00
gui/filebrowser.cpp: restore selection,
remove double paint on exec(), remember selected to restore on dir enter with OK button
This commit is contained in:
@@ -845,8 +845,12 @@ bool CFileBrowser::exec(const char * const dirname)
|
||||
std::replace(name.begin(), name.end(), '\\', '/');
|
||||
|
||||
paintHead();
|
||||
ChangeDir(name);
|
||||
paint();
|
||||
int selection = -1;
|
||||
if (name == Path)
|
||||
selection = selected;
|
||||
|
||||
ChangeDir(name, selection);
|
||||
//paint();
|
||||
paintFoot();
|
||||
|
||||
int oldselected = selected;
|
||||
@@ -1071,7 +1075,10 @@ bool CFileBrowser::exec(const char * const dirname)
|
||||
ChangeDir(filelist[selected].Url);
|
||||
else
|
||||
#endif
|
||||
{
|
||||
selections.push_back(selected);
|
||||
ChangeDir(filelist[selected].Name);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user