sgpemv2/src/configure_policy_dialog.hh

68 lines
2.0 KiB
C++
Raw Normal View History

// src/configure_policy_dialog.hh - Copyright 2005, 2006, University
// of Padova, dept. of Pure and Applied
// Mathematics
//
// This file is part of SGPEMv2.
//
// This is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 2 of the License, or
// (at your option) any later version.
//
// SGPEMv2 is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with SGPEMv2; if not, write to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#ifndef CONFIGURE_POLICY_DIALOG_HH
#define CONFIGURE_POLICY_DIALOG_HH 1
#include <sgpemv2/policy_parameters.hh>
#include <glibmm/ustring.h>
#include <gtkmm/box.h>
#include <gtkmm/frame.h>
#include <gtkmm/dialog.h>
#include <gtkmm/table.h>
#include <gtkmm/window.h>
namespace sgpem
{
class ConfigurePolicyDialog : public Gtk::Dialog
{
public:
ConfigurePolicyDialog(const Glib::ustring& title,
Gtk::Window& parent,
const Glib::ustring& description,
PolicyParameters& parameters);
protected:
Gtk::Frame* create_category(const Glib::ustring& type_name) const;
void parameter_int(const PolicyParameters::Parameter<int>& param, guint row);
void parameter_float(const PolicyParameters::Parameter<float>& param, guint row);
void parameter_string(const PolicyParameters::Parameter<Glib::ustring>& param, guint row);
private:
void on_okay();
PolicyParameters& _parameters;
Gtk::Table* _table_int;
Gtk::Table* _table_float;
Gtk::Table* _table_string;
};
} //~ namespace sgpem
#endif //~ CONFIGURE_POLICY_DIALOG_HH