forked from aseprite/aseprite
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnative_dialogs.h
More file actions
38 lines (31 loc) · 1.04 KB
/
native_dialogs.h
File metadata and controls
38 lines (31 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// SHE library
// Copyright (C) 2015 David Capello
//
// This file is released under the terms of the MIT license.
// Read LICENSE.txt for more information.
#ifndef SHE_NATIVE_DIALOGS_H_INCLUDED
#define SHE_NATIVE_DIALOGS_H_INCLUDED
#pragma once
#include <string>
namespace she {
class Display;
class FileDialog {
public:
virtual ~FileDialog() { }
virtual void dispose() = 0;
virtual void toOpenFile() = 0; // Configure the dialog to open a file
virtual void toSaveFile() = 0; // Configure the dialog to save a file
virtual void setTitle(const std::string& title) = 0;
virtual void setDefaultExtension(const std::string& extension) = 0;
virtual void addFilter(const std::string& extension, const std::string& description) = 0;
virtual std::string fileName() = 0;
virtual void setFileName(const std::string& filename) = 0;
virtual bool show(Display* parent) = 0;
};
class NativeDialogs {
public:
virtual ~NativeDialogs() { }
virtual FileDialog* createFileDialog() = 0;
};
} // namespace she
#endif