00001
00002
00003 #ifndef _LIBGNOMEUIMM_APPBAR_H
00004 #define _LIBGNOMEUIMM_APPBAR_H
00005
00006
00007 #include <glibmm.h>
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #include <libgnomeui/gnome-appbar.h>
00035 #include <gtkmm/box.h>
00036 #include <gtkmm/progressbar.h>
00037
00038
00039 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00040 typedef struct _GnomeAppBar GnomeAppBar;
00041 typedef struct _GnomeAppBarClass GnomeAppBarClass;
00042 #endif
00043
00044
00045 namespace Gnome
00046 {
00047
00048 namespace UI
00049 { class AppBar_Class; }
00050
00051 }
00052 namespace Gnome
00053 {
00054
00055 namespace UI
00056 {
00057
00058
00064 enum PreferencesType
00065 {
00066 PREFERENCES_NEVER,
00067 PREFERENCES_USER,
00068 PREFERENCES_ALWAYS
00069 };
00070
00071 }
00072
00073 }
00074
00075
00076 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00077 namespace Glib
00078 {
00079
00080 template <>
00081 class Value<Gnome::UI::PreferencesType> : public Glib::Value_Enum<Gnome::UI::PreferencesType>
00082 {
00083 public:
00084 static GType value_type() G_GNUC_CONST;
00085 };
00086
00087 }
00088 #endif
00089
00090
00091 namespace Gnome
00092 {
00093
00094 namespace UI
00095 {
00096
00097
00098 class AppBar : public Gtk::HBox
00099 {
00100 public:
00101 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00102 typedef AppBar CppObjectType;
00103 typedef AppBar_Class CppClassType;
00104 typedef GnomeAppBar BaseObjectType;
00105 typedef GnomeAppBarClass BaseClassType;
00106 #endif
00107
00108 virtual ~AppBar();
00109
00110 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00111
00112 private:
00113 friend class AppBar_Class;
00114 static CppClassType appbar_class_;
00115
00116
00117 AppBar(const AppBar&);
00118 AppBar& operator=(const AppBar&);
00119
00120 protected:
00121 explicit AppBar(const Glib::ConstructParams& construct_params);
00122 explicit AppBar(GnomeAppBar* castitem);
00123
00124 #endif
00125
00126 public:
00127 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00128 static GType get_type() G_GNUC_CONST;
00129 static GType get_base_type() G_GNUC_CONST;
00130 #endif
00131
00133 GnomeAppBar* gobj() { return reinterpret_cast<GnomeAppBar*>(gobject_); }
00134
00136 const GnomeAppBar* gobj() const { return reinterpret_cast<GnomeAppBar*>(gobject_); }
00137
00138
00139 public:
00140
00141 #ifdef GLIBMM_VFUNCS_ENABLED
00142 #endif //GLIBMM_VFUNCS_ENABLED
00143
00144 protected:
00145
00146 #ifdef GLIBMM_VFUNCS_ENABLED
00147 #endif //GLIBMM_VFUNCS_ENABLED
00148
00149
00150 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00151 virtual void on_clear_prompt();
00152 virtual void on_user_response();
00153 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00154
00155
00156 private:
00157
00158 public:
00159
00160 explicit AppBar(bool has_progress = false, bool has_status = true, PreferencesType interactivity = PREFERENCES_NEVER);
00161
00162
00163 Gtk::ProgressBar* get_progress();
00164
00165
00166 Gtk::Widget* get_status();
00167
00168 const Gtk::Widget* get_status() const;
00169
00170
00171 void set_default(const Glib::ustring& default_status);
00172
00173 void set_status(const Glib::ustring& status);
00174
00175 void push(const Glib::ustring& status);
00176
00177 void pop();
00178
00179 void clear_stack();
00180
00181 void set_progress_percentage(gfloat percentage);
00182
00183 void refresh();
00184
00185 void prompt(const Glib::ustring& message, bool modal = true);
00186
00187 void clear_prompt();
00188
00189 Glib::ustring get_response() const;
00190
00191
00197 Glib::SignalProxy0< void > signal_clear_prompt();
00198
00199
00205 Glib::SignalProxy0< void > signal_user_response();
00206
00207
00208 };
00209
00210 }
00211 }
00212
00213
00214 namespace Glib
00215 {
00221 Gnome::UI::AppBar* wrap(GnomeAppBar* object, bool take_copy = false);
00222 }
00223
00224
00225 #endif
00226