23 #ifndef __TOOLS_CONFIG_EDITOR_CONFIG_TREE_VIEW_H_ 24 #define __TOOLS_CONFIG_EDITOR_CONFIG_TREE_VIEW_H_ 31 class FawkesNetworkClient;
43 const Glib::RefPtr<Gtk::Builder>& builder);
48 void set_config_file(
const char* filename);
51 void remove_plugin( std::string config_path );
54 void set_value(
const char* path,
const char* type,
bool is_default,
bool value);
55 void set_value(
const char* path,
const char* type,
bool is_default,
int value);
56 void set_value(
const char* path,
const char* type,
bool is_default, uint value);
57 void set_value(
const char* path,
const char* type,
bool is_default,
float value);
58 void set_value(
const char* path,
const char* type,
bool is_default, std::string value);
60 virtual void on_button_press_event_custom(GdkEventButton* event);
61 virtual void on_menu_edit_selected();
62 virtual void on_menu_add_selected();
63 virtual void on_menu_remove_selected();
81 Gtk::TreeModelColumn<Glib::ustring>
node;
82 Gtk::TreeModelColumn<Glib::ustring>
path;
83 Gtk::TreeModelColumn<Glib::ustring>
type;
108 Gtk::TreeIter get_iter(
const char* path);
109 Gtk::TreeIter search_path(
const char* path );
111 bool edit_entry(
const Gtk::TreeIter& iter);
112 bool add_entry(
const Gtk::TreeIter& iter);
113 bool remove_entry(
const Gtk::TreeIter& iter);
Gtk::TreeModelColumn< bool > value_bool
bool config value
Dialog to add a config entry.
Simple Fawkes network client.
bool m_own_config
True if config was created by ConfigTreeView object.
Treeview widget for displaying/editing config entries.
Gtk::TreeModelColumn< uint > value_uint
unsigned int config value
Fawkes library namespace.
Gtk::TreeModelColumn< Glib::ustring > value_string
config value as string
Dialog to edit a config value.
Gtk::TreeModelColumn< Glib::ustring > type
config value type
ConfigAddDialog * m_dlg_add
A dialog to add a config entry.
ConfigEditDialog * m_dlg_edit
A dialog to edit a config entry.
Glib::RefPtr< Gtk::TreeStore > m_config_tree
Storage object.
fawkes::Configuration * m_config
The fawkes::Configuration that is displayed and editted.
Dialog to remove a config entry.
Gtk::Menu m_menu
A popup menu to edit the configuration.
Gtk::TreeModelColumn< Glib::ustring > node
node name
Column record class for the config TreeView.
ConfigRecord m_config_record
Column record object to access the columns of the storage object.
std::map< std::string, ConfigEditorPlugin * > m_plugins
A map of registered plugins: config-prefix => config editor plugin.
Gtk::TreeModelColumn< Glib::ustring > path
config path
Gtk::TreeModelColumn< int > value_int
int config value
Gtk::TreeModelColumn< float > value_float
float config value
ConfigRemoveDialog * m_dlg_remove
A dialog to remove a config entry.
Gtk::TreeModelColumn< bool > is_default
default flag
Base class for plugins for the Fawkes config editor.
Interface for configuration handling.