X-Git-Url: http://git.silcnet.org/gitweb/?a=blobdiff_plain;f=apps%2Fsilcer%2Fsrc%2Fsilcerbasewin.hh;fp=apps%2Fsilcer%2Fsrc%2Fsilcerbasewin.hh;h=0000000000000000000000000000000000000000;hb=72c2de619079457f7a68100eb13385275a424a23;hp=824aaa21e18c7db7e4a0b0336fc790873522be7d;hpb=e7b6c157b80152bf9fb9266e6bdd93f9fb0db776;p=runtime.git diff --git a/apps/silcer/src/silcerbasewin.hh b/apps/silcer/src/silcerbasewin.hh deleted file mode 100644 index 824aaa21..00000000 --- a/apps/silcer/src/silcerbasewin.hh +++ /dev/null @@ -1,196 +0,0 @@ -/* - - silcerbasewin.hh - - Author: Pekka Riikonen - - Copyright (C) 2001 Pekka Riikonen - - This program 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; version 2 of the License. - - This program 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. - -*/ - -#ifndef SILCERBASEWIN_HH -#define SILCERBASEWIN_HH - -#include "silcer_gladehelper.hh" - -#include "silcincludes.h" -#include "silcclient.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace SigC; - -class SilcerBaseWindow : public SigC::Object -{ -public: - SilcerBaseWindow(const char *widgetname); - virtual ~SilcerBaseWindow(); - - void show() { _thisWindow->show(); } - void hide() { _thisWindow->hide(); } - virtual void close(); - // Object extender - virtual void set_dynamic(); - // Destruction signal - Signal0 > evtDestroy; - -protected: - SilcerBaseWindow(); - // FIXME: Should make this function properly copy - SilcerBaseWindow& operator=(const SilcerBaseWindow&) { return *this;} - SilcerBaseWindow(const SilcerBaseWindow&) {} - -public: - // Helper functions - - Gtk::Button *getButton(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::CheckButton *getCheckButton(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::CTree *getCTree(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Entry *getEntry(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::EventBox *getEventBox(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Frame *getFrame(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::HBox *getHBox(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gnome::Entry *getGEntry(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Label *getLabel(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::MenuItem *getMenuItem(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::OptionMenu *getOptionMenu(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gnome::Pixmap *getPixmap(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::PixmapMenuItem *getPixmapMenuItem(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Text *getText(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::VBox *getVBox(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - template T *getWidget(const char *name) - { return SilcerGetWidget(_thisGH, name); } - -protected: - Gtk::Window *_thisWindow; - -private: - GladeXML *_thisGH; -}; - -class SilcerBaseDialog : public SilcerBaseWindow -{ -public: - SilcerBaseDialog(const char *widgetname, gboolean close_hides = false); - virtual ~SilcerBaseDialog() {} - -protected: - Gnome::Dialog *_thisDialog; - gboolean on_Dialog_close(); -}; - -class SilcerBaseWidget : public SigC::Object -{ -public: - SilcerBaseWidget(const char* widgetname, const char* filename); - virtual ~SilcerBaseWidget(); - void show() { _thisWidget->show(); } - void hide() { _thisWidget->hide(); } - Gtk::Widget* get_this_widget() { return _thisWidget; } - virtual void close(); - // Object extender - virtual void set_dynamic(); - // Destruction signal - Signal0 > evtDestroy; -protected: - SilcerBaseWidget(); - // FIXME: Should make this function properly copy - SilcerBaseWidget& operator=(const SilcerBaseWidget&) { return *this;} - SilcerBaseWidget(const SilcerBaseWidget&) {} -public: - // Helper functions - - Gtk::Button *getButton(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::CheckButton *getCheckButton(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Entry *getEntry(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Label *getLabel(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::MenuItem *getMenuItem(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::OptionMenu *getOptionMenu(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::PixmapMenuItem *getPixmapMenuItem(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - Gtk::Text *getText(const char *name) - { return SilcerGetWidget(_thisGH, name); } - - template T *getWidget(const char *name) - { return SilcerGetWidget(_thisGH, name); } - -protected: - Gtk::Widget *_thisWidget; - -private: - GladeXML *_thisGH; -}; - -#endif /* SILCERBASEWIN_HH */