diff --git a/src/browsedialog.cpp b/src/browsedialog.cpp index 4f24b70..69c188e 100644 --- a/src/browsedialog.cpp +++ b/src/browsedialog.cpp @@ -215,8 +215,6 @@ void BrowseDialog::paint() offsetY = gmenu2x->skinConfInt["topBarHeight"]+1; - beforeFileList(); - //Files & Directories gmenu2x->s->setClipRect(clipRect); for (i = firstElement; i < lastElement; i++) { diff --git a/src/browsedialog.h b/src/browsedialog.h index 2a6a357..b97d117 100644 --- a/src/browsedialog.h +++ b/src/browsedialog.h @@ -34,6 +34,16 @@ using std::vector; class BrowseDialog : protected Dialog { protected: + BrowseDialog(GMenu2X *gmenu2x, const string &title, const string &subtitle); + + void setPath(const string &path) { + fl->setPath(path); + } + + FileLister *fl; + unsigned int selected; + +private: enum Action { ACT_NONE, ACT_SELECT, @@ -46,28 +56,11 @@ protected: ACT_CONFIRM, }; - BrowseDialog(GMenu2X *gmenu2x, const string &title, const string &subtitle); - - virtual void beforeFileList() {}; - virtual void onChangeDir() {}; - - void setPath(const string &path) { - fl->setPath(path); - onChangeDir(); - } - - FileLister *fl; - unsigned int selected; - -private: - int selRow; bool close, result; string title; string subtitle; - IconButton *btnUp, *btnEnter, *btnConfirm; - SDL_Rect clipRect; SDL_Rect touchRect; @@ -92,7 +85,6 @@ private: void confirm(); public: - bool exec(); const std::string &getPath()