summaryrefslogtreecommitdiff
path: root/src/file_dialog.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/file_dialog.hpp')
-rw-r--r--src/file_dialog.hpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/file_dialog.hpp b/src/file_dialog.hpp
index 9709ec0..6a787b3 100644
--- a/src/file_dialog.hpp
+++ b/src/file_dialog.hpp
@@ -57,9 +57,7 @@ constexpr char DirEntryTypeToChar(DirEntryType entryType)
return entryLetter;
}
-using FilePickerResult = fud::Result<
- std::vector<DialogEntry>,
- fud::FudStatus>;
+using FilePickerResult = std::optional<std::vector<fud::String>>;
class FileDialog {
@@ -74,6 +72,10 @@ public:
return m_valid;
}
+ constexpr bool canceled() const {
+ return m_canceled;
+ }
+
private:
fud::FudStatus getDirectoryContents();
@@ -84,6 +86,7 @@ private:
std::vector<DialogEntry> m_directoryContents{};
bool m_valid{false};
+ bool m_canceled{false};
bool m_typeSelected{false};
bool m_nameSelectede{false};