-
Notifications
You must be signed in to change notification settings - Fork 0
/
ProjectMgrEditor.hpp
81 lines (54 loc) · 1.45 KB
/
ProjectMgrEditor.hpp
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
#ifndef WAYROUND_I2P_20241125_061830_587128
#define WAYROUND_I2P_20241125_061830_587128
#include <filesystem>
#include <iostream>
#include <gtkmm.h>
#include "forward_declarations.hpp"
#include "utils.hpp"
namespace wayround_i2p::ccedit
{
class ProjectMgrEditor
{
public:
static ProjectMgrEditor_shared create(
ProjectMgr_shared p_mgr,
std::string proj_name,
std::filesystem::path proj_path
);
protected:
ProjectMgrEditor(
ProjectMgr_shared p_mgr,
std::string proj_name,
std::filesystem::path proj_path
);
public:
~ProjectMgrEditor();
void show();
void destroy();
private:
ProjectMgr_shared p_mgr;
Controller_shared controller;
RunOnce destroyer;
ProjectMgrEditor_shared own_ptr;
std::string proj_name_orig;
std::filesystem::path proj_path_orig;
Gtk::Window win;
Gtk::Box main_box;
Gtk::Grid main_grid;
Gtk::Label name_label;
Gtk::Label path_label;
Gtk::Entry project_name;
Gtk::Entry project_path;
Gtk::Button btn_browse;
Gtk::Button btn_ok;
Gtk::Button btn_cancel;
Gtk::Box button_box;
void on_ok_click();
void on_cancel_click();
void on_browse_click();
void on_browse_click_finish(std::shared_ptr<Gio::AsyncResult> res);
void on_destroy_sig();
Glib::RefPtr<Gtk::FileDialog> select_dir_dialog;
};
} // namespace wayround_i2p::ccedit
#endif