]> Creatis software - creaImageIO.git/blob - src2/creaImageIOWxGimmickReaderDialog.h
Implemented calls from/to the interface to several methods.
[creaImageIO.git] / src2 / creaImageIOWxGimmickReaderDialog.h
1 #ifndef __creaImageIOWxGimmickReaderDialog_h_INCLUDED__
2 #define __creaImageIOWxGimmickReaderDialog_h_INCLUDED__
3
4 #ifdef USE_WXWIDGETS
5
6 #include <creaImageIOWxGimmickView.h>
7 #include <creaWx.h>
8
9 namespace creaImageIO
10 {
11   /**
12    * \ingroup GUI
13    */
14   //=====================================================================
15  //=====================================================================
16   class /*CREAIMAGEIO_EXPORT*/ WxGimmickReaderDialog : public wxDialog
17   {
18   public:
19     WxGimmickReaderDialog();    
20     WxGimmickReaderDialog(wxWindow *parent, 
21                           const wxWindowID id,
22                           wxString title,
23                           const wxPoint& pos, 
24                           const wxSize& size,
25                           int image_min_type = GIMMICK_2D_IMAGE_SELECTION,
26                           int image_max_type = GIMMICK_3D_IMAGE_SELECTION,
27                           int threads = 0);
28     
29     Gimmick* GetGimmick() { return mGimmick; }
30     //    typedef WxGimmick ViewType;
31     typedef WxGimmickView::EventType EventType;
32
33     ~WxGimmickReaderDialog();
34
35
36         //===============================================================================================
37         //Image Selection
38         //===============================================================================================
39     vtkImageData* GetSelectedImage(int dim) 
40         { return mView->GetSelectedImage(dim); }
41     void GetSelectedImages(std::vector<vtkImageData*>& s, int dim)
42     { mView->GetSelectedImages(s, dim); }
43
44
45     void GetSelectedFiles(std::vector<std::string>& s) 
46     { mView->GetSelectedFiles(s); }
47     
48     void OnSelChanged(EventType& event);
49     void OnContextualMenu(EventType& event);
50     void OnMenuTest(wxCommandEvent& event);
51         //    void OnValid(wxCommandEvent& event);
52     //    void OnButtonOk(wxCommandEvent& event);
53     //    void OnButtonCancel(wxCommandEvent& event);
54
55     DECLARE_EVENT_TABLE();
56   private :
57     
58     Gimmick*       mGimmick;
59     WxGimmickView* mView;
60
61     wxButton* mOkButton;
62     wxButton* mCancelButton;
63
64     enum 
65       {
66         TVID = 1
67         //      OKID = 2,
68         //      CANCELID = 3
69       };
70
71   }; // class WxGimmickReaderDialog
72   //=====================================================================
73
74   
75 } // EO namespace creaImageIO
76
77
78 #endif // USE_WIDGETS
79 // EOF
80 #endif