]> Creatis software - cpPlugins.git/blob - lib/cpExtensions/Interaction/SphereWidget.h
11ce916c814bc236c29c3345b67b0fe8b0ff4e04
[cpPlugins.git] / lib / cpExtensions / Interaction / SphereWidget.h
1 #ifndef __CPEXTENSIONS__INTERACTION__SphereWidget__H__
2 #define __CPEXTENSIONS__INTERACTION__SphereWidget__H__
3
4 #include <cpExtensions/cpExtensions_Export.h>
5 #include <cpExtensions/Interaction/BaseInteractorStyle.h>
6 #include <vtkSphereWidget.h>
7
8 namespace cpExtensions
9 {
10   namespace Interaction
11   {
12     /**
13      */
14     class cpExtensions_EXPORT SphereWidget
15       : public vtkSphereWidget
16     {
17     public:
18       typedef SphereWidget Self;
19       vtkTypeMacro( SphereWidget, vtkSphereWidget );
20
21       typedef cpExtensions::Interaction::BaseInteractorStyle TBaseStyle;
22       typedef TBaseStyle::TMouseCommand TMouseCommand;
23       typedef TBaseStyle::TKeyCommand TKeyCommand;
24
25     public:
26       static Self* New( );
27
28       virtual void SetInteractor( vtkRenderWindowInteractor* rwi );
29
30       
31
32     protected:
33       SphereWidget( );
34       virtual ~SphereWidget( );
35
36       static void _Click(
37         void* data, const TBaseStyle::ButtonID& button,
38         int* idx, double* pos, bool alt, bool ctr, bool sft
39         );
40       static void _DoubleClick(
41         void* data, const TBaseStyle::ButtonID& button,
42         int* idx, double* pos, bool alt, bool ctr, bool sft
43         );
44       static void _KeyPress(void* data, const char& key);
45        
46     private:
47       // Purposely not implemented
48       SphereWidget( const Self& );
49       Self& operator=( const Self& );
50     };
51
52   } // ecapseman
53
54 } // ecapseman
55
56 #endif // __CPEXTENSIONS__INTERACTION__SphereWidget__H__
57
58 // eof - $RCSfile$