X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=packages%2Fwx%2Fsrc%2FbbwxCommandButton.h;h=ccbb0e0757c213cb7751d26271faa1686bb385eb;hb=5196156e0ab3bdf5ea8205d9cbccf558ca3004ad;hp=91964e258760a390ab74f28fc83681204bab5621;hpb=6575a389b71b1b85c79e4444885becb76ecf16e4;p=bbtk.git diff --git a/packages/wx/src/bbwxCommandButton.h b/packages/wx/src/bbwxCommandButton.h index 91964e2..ccbb0e0 100644 --- a/packages/wx/src/bbwxCommandButton.h +++ b/packages/wx/src/bbwxCommandButton.h @@ -2,8 +2,8 @@ Program: bbtk Module: $RCSfile: bbwxCommandButton.h,v $ Language: C++ - Date: $Date: 2008/10/17 08:18:32 $ - Version: $Revision: 1.6 $ + Date: $Date: 2008/12/12 08:55:23 $ + Version: $Revision: 1.8 $ =========================================================================*/ /* --------------------------------------------------------------------- @@ -36,49 +36,29 @@ */ /** * \file - * \brief Pattern for the definition of a new type of Node (header) + * \brief */ /** - * \class bbtk::NodePatern - * \brief Pattern for the definition of a new type of Node + * \class CommandButton + * \brief */ -#ifdef _USE_WXWIDGETS_ +#ifdef USE_WXWIDGETS #ifndef __bbwxCommandButton_h_INCLUDED_H__ #define __bbwxCommandButton_h_INCLUDED_H__ #include "bbtkWxBlackBox.h" - +#include "bbwx_EXPORT.h" namespace bbwx { - class CommandButton; //-------------------------------------------------------------------------- - class CommandButtonWidget : public wxPanel - { - public: - CommandButtonWidget(CommandButton* box, wxWindow *parent, - wxString title); - ~CommandButtonWidget(); - void OnCommandButton( wxEvent& ); - void SetLabel(wxString title); - void SetColour(wxColour color); - - private: - CommandButton* mBox; - wxButton *mwxCommandButton; - }; - - //-------------------------------------------------------------------------- - //-------------------------------------------------------------------------- - //-------------------------------------------------------------------------- - - class /*BBTK_EXPORT*/ CommandButton : public bbtk::WxBlackBox + class bbwx_EXPORT CommandButton : public bbtk::WxBlackBox { friend class CommandButtonWidget; BBTK_BLACK_BOX_INTERFACE(CommandButton,bbtk::WxBlackBox); @@ -89,7 +69,7 @@ namespace bbwx BBTK_PROCESS(Process); void Process(); BBTK_CREATE_WIDGET(CreateWidget); - void CreateWidget(); + void CreateWidget(wxWindow*); protected: virtual void bbUserConstructor(); @@ -98,14 +78,14 @@ namespace bbwx void UpdateColour(); void UpdateLabel(); }; - + //================================================================= // UserBlackBox description BBTK_BEGIN_DESCRIBE_BLACK_BOX(CommandButton,bbtk::WxBlackBox); BBTK_NAME("CommandButton"); BBTK_AUTHOR("eduardo.davila@creatis.insa-lyon.fr"); BBTK_DESCRIPTION("Button which executes bbi commands"); - + typedef std::vector vectorcolour; BBTK_INPUT(CommandButton,In,"Commands to be executed separated by commas (;). Each single quote (') is replaced by a double quote (\").",std::string,""); @@ -114,10 +94,10 @@ namespace bbwx // BBTK_OUTPUT(CommandButton,Out,"..Out..",int); BBTK_END_DESCRIBE_BLACK_BOX(CommandButton); //================================================================= - - + + }//namespace bbwx - + #endif // __bbwxCommandButton_h_INCLUDED_H__ - -#endif //_USE_WXWIDGETS_ + +#endif //USE_WXWIDGETS