#include <boost/filesystem.hpp>
-using namespace std;
-using namespace boost;
+using std::string;
+using boost::optional;
FilePickerCtrl::FilePickerCtrl(
wxString wildcard,
bool open,
bool warn_overwrite,
- std::string initial_path_key,
+ string initial_path_key,
optional<std::string> initial_filename,
- optional<filesystem::path> override_path
+ optional<boost::filesystem::path> override_path
)
: wxPanel (parent)
, _prompt (prompt)
#include <boost/filesystem.hpp>
-using namespace std;
-using namespace boost;
+using std::string;
+using boost::bind;
+using boost::optional;
-optional<filesystem::path> FilmNameLocationDialog::_directory;
+optional<boost::filesystem::path> FilmNameLocationDialog::_directory;
FilmNameLocationDialog::FilmNameLocationDialog (wxWindow* parent, wxString title, bool offer_templates)
}
-filesystem::path
+boost::filesystem::path
FilmNameLocationDialog::path () const
{
- filesystem::path p;
+ boost::filesystem::path p;
p /= wx_to_std (_folder->GetPath());
p /= wx_to_std (_name->GetValue());
return p;
bool
FilmNameLocationDialog::check_path ()
{
- if (filesystem::is_directory(path()) && !filesystem::is_empty(path())) {
+ if (boost::filesystem::is_directory(path()) && !boost::filesystem::is_empty(path())) {
if (!confirm_dialog (
this,
std_to_wx (
)) {
return false;
}
- } else if (filesystem::is_regular_file(path())) {
+ } else if (boost::filesystem::is_regular_file(path())) {
error_dialog (
this,
String::compose (wx_to_std(_("%1 already exists as a file, so you cannot use it for a film.")), path().c_str())