]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Porting to qwt-5.0.1 and qt-4.2.3 products.
authornds <nds@opencascade.com>
Tue, 19 Jun 2007 06:49:13 +0000 (06:49 +0000)
committernds <nds@opencascade.com>
Tue, 19 Jun 2007 06:49:13 +0000 (06:49 +0000)
src/Plot2d/Plot2d_ViewFrame.cxx

index 630f72e879239b254ed6491bbaf78b02d5e9f3f1..de03ad90ab14c7613a3c0bcbae1c26f2fc2d47a3 100755 (executable)
@@ -209,7 +209,7 @@ Plot2d_ViewFrame::Plot2d_ViewFrame( QWidget* parent, const QString& title )
     QwtScaleMap yMap2 = myPlot->canvasMap( QwtPlot::yRight );
     myYDistance2 = yMap2.s2() - yMap2.s1();
   }
-  qApp->installEventFilter( this );
+  myPlot->canvas()->installEventFilter( this );
 }
 /*!
   Destructor
@@ -311,7 +311,6 @@ bool Plot2d_ViewFrame::eventFilter( QObject* watched, QEvent* e )
           QMouseEvent m( QEvent::MouseButtonPress, me->pos(), me->button(),
                           me->buttons(), me->modifiers() );
           plotMousePressed( m );
-          //return true;
         }
         break;
       }
@@ -321,7 +320,6 @@ bool Plot2d_ViewFrame::eventFilter( QObject* watched, QEvent* e )
           QMouseEvent m( QEvent::MouseButtonRelease, me->pos(), me->button(),
                          me->buttons(), me->modifiers() );
           plotMouseReleased( m );
-          //return true;
         }
         break;
       }
@@ -1694,7 +1692,6 @@ Plot2d_Plot2d::Plot2d_Plot2d( QWidget* parent )
   : QwtPlot( parent ),
     myIsPolished( false )
 {
-
   myPlotZoomer = new Plot2d_QwtPlotZoomer( QwtPlot::xBottom, QwtPlot::yLeft, canvas() );
   myPlotZoomer->setSelectionFlags( QwtPicker::DragSelection | QwtPicker::CornerToCorner );
   myPlotZoomer->setTrackerMode( QwtPicker::AlwaysOff );
@@ -1722,7 +1719,7 @@ Plot2d_Plot2d::Plot2d_Plot2d( QWidget* parent )
   myGrid->attach( this );
 
   setMouseTracking( false );
-  canvas()->setMouseTracking( false );
+  canvas()->setMouseTracking( true );
 
   myPlotZoomer->setEnabled( true );
 }