]> Creatis software - cpPlugins.git/blobdiff - lib/cpExtensions/Interaction/SeedWidget.h
More widgets added
[cpPlugins.git] / lib / cpExtensions / Interaction / SeedWidget.h
diff --git a/lib/cpExtensions/Interaction/SeedWidget.h b/lib/cpExtensions/Interaction/SeedWidget.h
new file mode 100644 (file)
index 0000000..526ac7e
--- /dev/null
@@ -0,0 +1,54 @@
+#ifndef __CPEXTENSIONS__INTERACTION__SEEDWIDGET__H__
+#define __CPEXTENSIONS__INTERACTION__SEEDWIDGET__H__
+
+#include <cpExtensions/cpExtensions_Export.h>
+#include <cpExtensions/Interaction/BaseInteractorStyle.h>
+#include <vtkSeedWidget.h>
+
+namespace cpExtensions
+{
+  namespace Interaction
+  {
+    /**
+     */
+    class cpExtensions_EXPORT SeedWidget
+      : public vtkSeedWidget
+    {
+    public:
+      typedef SeedWidget Self;
+      vtkTypeMacro( SeedWidget, vtkSeedWidget );
+
+      typedef cpExtensions::Interaction::BaseInteractorStyle TBaseStyle;
+      typedef TBaseStyle::TMouseCommand TMouseCommand;
+
+    public:
+      static Self* New( );
+
+      virtual void SetInteractor( vtkRenderWindowInteractor* rwi );
+
+    protected:
+      SeedWidget( );
+      virtual ~SeedWidget( );
+
+      static void _Click(
+        void* data, const TBaseStyle::ButtonID& button,
+        int* idx, double* pos, bool alt, bool ctr, bool sft
+        );
+      static void _DoubleClick(
+        void* data, const TBaseStyle::ButtonID& button,
+        int* idx, double* pos, bool alt, bool ctr, bool sft
+        );
+
+    private:
+      // Purposely not implemented
+      SeedWidget( const Self& );
+      Self& operator=( const Self& );
+    };
+
+  } // ecapseman
+
+} // ecapseman
+
+#endif // __CPEXTENSIONS__INTERACTION__SEEDWIDGET__H__
+
+// eof - $RCSfile$