00001 //--------------------------------------------------------------------------- 00002 // $RCSfile: TreeMultiItemWindow.h,v $ 00003 // $Source: /cvs/creatis/bbtk/kernel/src/ThirdParty/wx/treemultictrl/TreeMultiItemWindow.h,v $ 00004 // $Revision: 1.1 $ 00005 // $Date: 2008/03/28 13:42:18 $ 00006 //--------------------------------------------------------------------------- 00007 // Author: Jorgen Bodde 00008 // Copyright: (c) Jorgen Bodde 00009 // License: wxWidgets License 00010 //--------------------------------------------------------------------------- 00011 00012 #ifndef __TREEMULTIITEMWINDOW_HPP_ 00013 #define __TREEMULTIITEMWINDOW_HPP_ 00014 00015 #ifdef __GNUG__ 00016 #pragma interface "TreeMultiItemWindow.cpp" 00017 #endif 00018 00019 #ifndef WX_PRECOMP 00020 #include "wx/wx.h" 00021 #endif 00022 00023 #include <wx/dynarray.h> 00024 00025 #include "TreeMultiItemBase.h" 00026 00027 class TreeMultiItemWindow : public TreeMultiItemBase 00028 { 00029 private: 00032 wxWindow *_window; 00033 00035 int _topSpacing, _frontSpacing; 00036 00038 bool _span; 00039 00040 public: 00041 TreeMultiItemWindow(TreeMultiItemNode *parent, const wxString &name = wxEmptyString); 00042 virtual ~TreeMultiItemWindow(); 00043 00044 // IsClass method 00045 virtual TreeMultiItemWindow *IsTreeMultiItemWindow() const { 00046 return (TreeMultiItemWindow *)this; 00047 }; 00048 00052 void AssignWindow(wxWindow *wnd); 00053 00055 wxWindow *GetWindow() { 00056 return _window; 00057 }; 00058 00059 /* Sets front spacing */ 00060 void SetFrontSpacing(int frontSpacing) { 00061 _frontSpacing = frontSpacing; 00062 }; 00063 /* Gets front spacing */ 00064 int GetFrontSpacing() const { 00065 return _frontSpacing; 00066 }; 00067 /* Sets top spacing */ 00068 void SetTopSpacing(int topSpacing) { 00069 _topSpacing = topSpacing; 00070 }; 00071 /* Gets top spacing */ 00072 int GetTopSpacing() const { 00073 return _topSpacing; 00074 }; 00075 00076 /* Sets horizontal span, meaning when this is set the window 00077 attached may be resized horizontally when the window is resized */ 00078 void SetHorizontalSpan(bool span) { 00079 _span = span; 00080 }; 00081 00082 /* Sets horizontal span, meaning when this is set the window 00083 attached may be resized horizontally when the window is resized */ 00084 bool GetHorizontalSpan() const { 00085 return _span; 00086 }; 00087 00088 #if(CHECKBOXVIEW) 00089 00090 virtual void SetCheckboxState(int state); 00091 #endif 00092 }; 00093 00094 #endif 00095