From 9fdbcb95d487f88d6684f55405c72a6ec00a9047 Mon Sep 17 00:00:00 2001 From: Andrea Bernabei bernabei Date: Tue, 22 Apr 2008 14:54:39 +0000 Subject: [PATCH] Added support for tablet events --- src/meshlab/glarea.cpp | 9 +++++++++ src/meshlab/glarea.h | 4 ++++ src/meshlab/interfaces.h | 6 +++++- 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/src/meshlab/glarea.cpp b/src/meshlab/glarea.cpp index f90f50fc8..e3685c263 100644 --- a/src/meshlab/glarea.cpp +++ b/src/meshlab/glarea.cpp @@ -24,6 +24,9 @@ History $Log$ +Revision 1.142 2008/04/22 14:54:38 bernabei +Added support for tablet events + Revision 1.141 2008/04/04 10:07:12 cignoni Solved namespace ambiguities caused by the removal of a silly 'using namespace' in meshmodel.h @@ -649,6 +652,12 @@ void GLArea::mouseReleaseEvent(QMouseEvent*e) update(); } +//Processing of tablet events, interesting only for painting plugins +void GLArea::tabletEvent(QTabletEvent*e) +{ + if(iEdit && !suspendedEditor) iEdit->tabletEvent(currentEditor,e,*mm(),this); +} + void GLArea::wheelEvent(QWheelEvent*e) { const int WHEEL_STEP = 120; diff --git a/src/meshlab/glarea.h b/src/meshlab/glarea.h index 829b1b443..31638b65b 100644 --- a/src/meshlab/glarea.h +++ b/src/meshlab/glarea.h @@ -24,6 +24,9 @@ History $Log$ +Revision 1.85 2008/04/22 14:54:38 bernabei +Added support for tablet events + Revision 1.84 2008/04/04 10:07:10 cignoni Solved namespace ambiguities caused by the removal of a silly 'using namespace' in meshmodel.h @@ -387,6 +390,7 @@ protected: void mouseReleaseEvent(QMouseEvent *event); void mouseDoubleClickEvent ( QMouseEvent * event ) ; void wheelEvent(QWheelEvent*e); + void tabletEvent(QTabletEvent *e); bool drawSelection; void hideEvent(QHideEvent * event); diff --git a/src/meshlab/interfaces.h b/src/meshlab/interfaces.h index 2cb4b1134..3b0159a2e 100644 --- a/src/meshlab/interfaces.h +++ b/src/meshlab/interfaces.h @@ -23,6 +23,9 @@ /**************************************************************************** History $Log$ +Revision 1.76 2008/04/22 14:54:39 bernabei +Added support for tablet events + Revision 1.75 2008/04/18 17:36:37 cignoni added some filter classes (smoothing, normal, quality) @@ -278,7 +281,7 @@ public: // The FilterClass describes in which generic class of filters it fits. // This choice affect the submenu in which each filter will be placed - // For example filters that perform an action only on the selection will be placed in the Selection Class Ê + // For example filters that perform an action only on the selection will be placed in the Selection Class � virtual const FilterClass getClass(QAction *) { return MeshFilterInterface::Generic; } // The filters can have some additional requirements on the mesh capabiliteis. @@ -457,6 +460,7 @@ public: // virtual void wheelEvent (QAction *QWheelEvent*e, MeshModel &/*m*/, GLArea * ); virtual void keyReleaseEvent (QAction *, QKeyEvent *, MeshModel &/*m*/, GLArea *){}; virtual void keyPressEvent (QAction *, QKeyEvent *, MeshModel &/*m*/, GLArea *){}; + virtual void tabletEvent (QAction *, QTabletEvent *, MeshModel &/*m*/, GLArea *){}; };