-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmessage.hpp
More file actions
50 lines (38 loc) · 1.27 KB
/
Copy pathmessage.hpp
File metadata and controls
50 lines (38 loc) · 1.27 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
39
40
41
42
43
44
45
46
47
48
49
50
#ifndef __compose_message_hpp
#define __compose_message_hpp
#include <gtkmm/treemodelcolumn.h>
#include <gtkmm/liststore.h>
#include <gtkmm/treemodelfilter.h>
#include <gtkmm/textbuffer.h>
namespace Compose {
class HeaderModelColumns : public Gtk::TreeModelColumnRecord {
public:
HeaderModelColumns();
Gtk::TreeModelColumn<Glib::ustring> m_name;
Gtk::TreeModelColumn<Glib::ustring> m_value;
Gtk::TreeModelColumn<bool> m_shown;
};
const HeaderModelColumns &header_model();
// Represents an email message
struct Message : public Glib::Object {
Message();
Glib::RefPtr<Gtk::TextBuffer> m_ref_body_buffer;
Glib::RefPtr<Gtk::ListStore> m_ref_headers;
Glib::RefPtr<Gtk::TreeModelFilter> m_ref_visible_headers;
void connect_header_edited(Glib::SignalProxy2<void,
const Glib::ustring &,
const Glib::ustring &>);
void set_header_visible(const Glib::ustring &, bool);
void set_headers_visible(bool);
private:
class visible_header_setter {
Glib::ustring m_name;
bool m_value;
public:
visible_header_setter(const Glib::ustring &name, bool value);
void operator ()(Gtk::TreeIter) const;
};
void on_header_edited(const Glib::ustring &, const Glib::ustring &);
};
}
#endif