Fawkes API  Fawkes Development Version
ConfigAddDialog Class Reference

Dialog to add a config entry. More...

#include "config_add_dialog.h"

List of all members.

Public Member Functions

 ConfigAddDialog (Gtk::Entry *ent_path, Gtk::Entry *ent_value, Gtk::ComboBox *cob_bool_value, Gtk::Notebook *type_pages, Gtk::ComboBox *cmb_type, Gtk::CheckButton *chb_is_default)
 Constructor.
 ConfigAddDialog (BaseObjectType *cobject, const Glib::RefPtr< Gtk::Builder > &builder)
 Constructor.
virtual ~ConfigAddDialog ()
 Destructor.
void init (const Glib::ustring &path)
 Initialize the dialog.
Glib::ustring get_path () const
 Get the path of the new entry.
Glib::ustring get_type () const
 Get the type of the new entry.
Glib::ustring get_value () const
 Get the value of the new entry.
bool get_is_default () const
 Get the default flag of the new entry.

Protected Member Functions

void on_my_changed ()
 Swiches the (invisible) pages to add either a bool or a different type value.

Protected Attributes

Gtk::Entry * m_ent_path
 The Gtk::Entry that contains the path of the new entry.
Gtk::Entry * m_ent_value
 The Gtk::Entry that contains the value of the new entry.
Gtk::ComboBox * m_cob_bool_value
 A combo box to select TRUE or FALSE.
Gtk::Notebook * m_type_pages
 A Gtk::Notebook element to switch between boolean values and the rest.
Gtk::ComboBox * m_cmb_type
 The Gtk::ComboBox to select the type of the new entry.
Gtk::CheckButton * m_chb_is_default
 The Gtk::CheckButton to set the default flag.

Detailed Description

Dialog to add a config entry.

Author:
Daniel Beck

Constructor & Destructor Documentation

ConfigAddDialog::ConfigAddDialog ( Gtk::Entry *  ent_path,
Gtk::Entry *  ent_value,
Gtk::ComboBox *  cob_bool_value,
Gtk::Notebook *  type_pages,
Gtk::ComboBox *  cmb_type,
Gtk::CheckButton *  chb_is_default 
)

Constructor.

Parameters:
ent_pathentry field for path
ent_valueentry field for value
cob_bool_valuecombo box for bool values
type_pagespages for different types
cmb_typecombo box for type
chb_is_defaultcheck button for default values

Definition at line 63 of file config_add_dialog.cpp.

References m_ent_path, m_cmb_type, m_ent_value, m_cob_bool_value, m_type_pages, m_chb_is_default, and on_my_changed().

ConfigAddDialog::ConfigAddDialog ( BaseObjectType *  cobject,
const Glib::RefPtr< Gtk::Builder > &  builder 
)

Constructor.

Parameters:
cobjectpointer to base object type
builderGtk builder

Definition at line 84 of file config_add_dialog.cpp.

References m_ent_path, m_cmb_type, m_ent_value, m_cob_bool_value, m_type_pages, m_chb_is_default, and on_my_changed().

ConfigAddDialog::~ConfigAddDialog ( ) [virtual]

Destructor.

Definition at line 99 of file config_add_dialog.cpp.


Member Function Documentation

bool ConfigAddDialog::get_is_default ( ) const

Get the default flag of the new entry.

Returns:
if true add to default config database

Definition at line 163 of file config_add_dialog.cpp.

References m_chb_is_default.

Glib::ustring ConfigAddDialog::get_path ( ) const

Get the path of the new entry.

Returns:
the path of the new entry

Definition at line 120 of file config_add_dialog.cpp.

References m_ent_path.

Glib::ustring ConfigAddDialog::get_type ( ) const

Get the type of the new entry.

Returns:
the type of the new entry

Definition at line 129 of file config_add_dialog.cpp.

References m_cmb_type.

Referenced by get_value(), and on_my_changed().

Glib::ustring ConfigAddDialog::get_value ( ) const

Get the value of the new entry.

Returns:
the value of the new entry

Definition at line 144 of file config_add_dialog.cpp.

References get_type(), m_ent_value, and m_cob_bool_value.

void ConfigAddDialog::init ( const Glib::ustring &  path)

Initialize the dialog.

Parameters:
paththe config path of the selected row

Definition at line 107 of file config_add_dialog.cpp.

References m_ent_path, m_ent_value, m_cmb_type, m_cob_bool_value, and m_chb_is_default.

void ConfigAddDialog::on_my_changed ( ) [protected]

Swiches the (invisible) pages to add either a bool or a different type value.

Definition at line 172 of file config_add_dialog.cpp.

References m_type_pages, and get_type().

Referenced by ConfigAddDialog().


Member Data Documentation

The Gtk::CheckButton to set the default flag.

Definition at line 56 of file config_add_dialog.h.

Referenced by ConfigAddDialog(), init(), and get_is_default().

The Gtk::ComboBox to select the type of the new entry.

Definition at line 55 of file config_add_dialog.h.

Referenced by ConfigAddDialog(), init(), and get_type().

A combo box to select TRUE or FALSE.

Definition at line 53 of file config_add_dialog.h.

Referenced by ConfigAddDialog(), init(), and get_value().

The Gtk::Entry that contains the path of the new entry.

Definition at line 51 of file config_add_dialog.h.

Referenced by ConfigAddDialog(), init(), and get_path().

The Gtk::Entry that contains the value of the new entry.

Definition at line 52 of file config_add_dialog.h.

Referenced by ConfigAddDialog(), init(), and get_value().

A Gtk::Notebook element to switch between boolean values and the rest.

Definition at line 54 of file config_add_dialog.h.

Referenced by ConfigAddDialog(), and on_my_changed().


The documentation for this class was generated from the following files: