diff options
author | Dominick Allen <djallen@librehumanitas.org> | 2024-09-28 20:32:18 -0500 |
---|---|---|
committer | Dominick Allen <djallen@librehumanitas.org> | 2024-09-28 20:32:18 -0500 |
commit | 6f44617d0a378d980de71e6a5e1d634bff95bbcb (patch) | |
tree | c0e87f9c9ef581d165c97dc7fb2553c383187453 /src/file_dialog.hpp | |
parent | 876c829512301e3f20161f05d7c193540e6d1710 (diff) |
Flesh out dialog.
Diffstat (limited to 'src/file_dialog.hpp')
-rw-r--r-- | src/file_dialog.hpp | 9 |
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}; |