]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Remove functionality by refresh dump image. Using method grabWidget instead of grabWi...
authornds <nds@opencascade.com>
Wed, 27 Feb 2008 05:27:12 +0000 (05:27 +0000)
committernds <nds@opencascade.com>
Wed, 27 Feb 2008 05:27:12 +0000 (05:27 +0000)
src/Plot2d/Plot2d_ViewModel.cxx
src/Plot2d/Plot2d_ViewWindow.cxx
src/Plot2d/Plot2d_ViewWindow.h

index 7906d70526c2e32b2b3a3d8dbd3aae51ac03d6f1..fae67f5cf875d6899c572d4030616f53d6f390ad 100755 (executable)
@@ -81,7 +81,6 @@ void Plot2d_Viewer::contextMenuPopup(QMenu* thePopup)
         thePopup->addSeparator();
       thePopup->addAction("Show toolbar", this, SLOT(onShowToolbar()));
     }
-    aView->RefreshDumpImage();
   }
 }
 
index cb550532f4fc7bdedcf231b7e2cb8450fda9068d..ed6ec0cdfa3fafc318ef3995b94f6ad3ebf007ff 100755 (executable)
@@ -59,7 +59,6 @@ Plot2d_ViewWindow::Plot2d_ViewWindow( SUIT_Desktop* theDesktop, Plot2d_Viewer* t
 : SUIT_ViewWindow( theDesktop )
 {
   myModel = theModel;
-  myDumpImage = QImage();
 }
 
 /*!
@@ -443,15 +442,6 @@ void Plot2d_ViewWindow::setVisualParameters( const QString& parameters )
   myViewFrame->setVisualParameters( parameters );
 }
 
-/*!
-  \brief Grab the view window to the internal image.
-*/
-void Plot2d_ViewWindow::RefreshDumpImage()
-{
-  QPixmap px = QPixmap::grabWindow( myViewFrame->winId() );
-  myDumpImage = px.toImage();
-}
-
 /*!
   \brief Called when the scale mode for the horizontal axis is changed.
 */
@@ -605,12 +595,8 @@ void Plot2d_ViewWindow::onDumpView()
 */
 QImage Plot2d_ViewWindow::dumpView()
 {
-  if ( getToolBar()->underMouse() || myDumpImage.isNull() ) {
-    QPixmap px = QPixmap::grabWindow( myViewFrame->winId() );
-    return px.toImage();
-  }
-  
-  return myDumpImage;
+  QPixmap px = QPixmap::grabWidget( myViewFrame );
+  return px.toImage();
 }
 
 /*!
index 0908cc67a49602054fb2d98250461933100f8854..e3fc5c8b4806d883d2c75a04162c900f0ea9defc 100755 (executable)
@@ -62,8 +62,6 @@ public:
 
   virtual QString   getVisualParameters();
   virtual void      setVisualParameters( const QString& );
-  
-  virtual void      RefreshDumpImage();
 
 public slots:
   void              onChangeHorMode();