Lagrange
|
RAII Wrapper for fs::path obtained from a file dialog. More...
#include <lagrange/ui/utils/file_dialog.h>
Classes | |
struct | FileDialogPathImpl |
Shared handle to manage temporary filesystem file lifetime. More... | |
Public Member Functions | |
FileDialogPath (FileDialogPath &&other) | |
FileDialogPath & | operator= (FileDialogPath &&other) |
operator const fs::path & () const | |
Implicit fs::path conversion. | |
operator std::string () const | |
Implicit string conversion. | |
std::string | string () const |
Convert path to string. | |
bool | empty () const noexcept |
const fs::path & | path () const |
Return underlying path. | |
Static Public Member Functions | |
static FileDialogPath | make_input_path (const fs::path &path) |
Create FileDialogPath from Open File Dialog. | |
static FileDialogPath | make_output_path (const fs::path &path) |
Create FileDialogPath from Save File Dialog. | |
Protected Member Functions | |
FileDialogPath (const fs::path &path) | |
Protected Attributes | |
std::unique_ptr< FileDialogPathImpl > | m_impl |
RAII Wrapper for fs::path obtained from a file dialog.
If compiled for web under Emscripten: Removes the file from temporary browser filesystem when out of scope If created by create_output_path
: triggers download of the file when going out of scope