2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-14 19:26:09 +00:00

FileBrowser: Move constructor definition into cpp file

Avoids requiring hecl.hpp to be included within the header.
This commit is contained in:
Lioncash
2019-09-05 18:57:23 -04:00
parent 8ff9e028c7
commit ba7a48764d
2 changed files with 5 additions and 2 deletions

View File

@@ -226,8 +226,7 @@ private:
public: public:
FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type, FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type,
std::function<void(bool, hecl::SystemStringView)> returnFunc) std::function<void(bool, hecl::SystemStringView)> returnFunc);
: FileBrowser(res, parentView, title, type, hecl::GetcwdStr(), returnFunc) {}
FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type, FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type,
hecl::SystemStringView initialPath, std::function<void(bool, hecl::SystemStringView)> returnFunc); hecl::SystemStringView initialPath, std::function<void(bool, hecl::SystemStringView)> returnFunc);
~FileBrowser() override; ~FileBrowser() override;

View File

@@ -43,6 +43,10 @@ std::vector<hecl::SystemString> FileBrowser::PathComponents(hecl::SystemStringVi
return ret; return ret;
} }
FileBrowser::FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type,
std::function<void(bool, hecl::SystemStringView)> returnFunc)
: FileBrowser(res, parentView, title, type, hecl::GetcwdStr(), std::move(returnFunc)) {}
FileBrowser::FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type, FileBrowser::FileBrowser(ViewResources& res, View& parentView, std::string_view title, Type type,
hecl::SystemStringView initialPath, hecl::SystemStringView initialPath,
std::function<void(bool, hecl::SystemStringView)> returnFunc) std::function<void(bool, hecl::SystemStringView)> returnFunc)