]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Move dumpImage() method to public section - needed by SalomePyQt module
authorvsr <vsr@opencascade.com>
Tue, 21 Jun 2005 09:20:39 +0000 (09:20 +0000)
committervsr <vsr@opencascade.com>
Tue, 21 Jun 2005 09:20:39 +0000 (09:20 +0000)
src/SUIT/SUIT_ViewWindow.cxx
src/SUIT/SUIT_ViewWindow.h

index f7060156b509d637099dd12d86f1d28069f7adeb..7886b415bfbb19adff3cec5d40e9d812be3d9d6f 100755 (executable)
@@ -62,7 +62,7 @@ bool SUIT_ViewWindow::event( QEvent* e )
       if ( !img.isNull() ) {
         // get file name
         QString fileName = myManager->study()->application()->getFileName( false, QString::null, tr( "TLT_IMAGE_FILES" ), tr( "TLT_DUMP_VIEW" ), 0 );
-        if ( fileName ) {
+        if ( !fileName.isEmpty() ) {
           QString fmt = SUIT_Tools::extension( fileName ).upper();
           if ( fmt.isEmpty() ) fmt = QString( "BMP" ); // default format
          if ( fmt == "JPG" )  fmt = "JPEG";
index 115f1fc4c3d28d75c4a22d22f4725a08a53655ea..5cfcb4e1d5e9feb32b1e35b44cf6aaf4eeb70bed 100755 (executable)
@@ -29,6 +29,8 @@ public:
 
   bool              event(QEvent*);
 
+  virtual QImage    dumpView() { return QImage(); }
+
 public slots:
   virtual void      onDumpView();
 
@@ -47,8 +49,6 @@ protected:
   void              closeEvent(QCloseEvent* theEvent);
   virtual void      contextMenuEvent( QContextMenuEvent * e );
 
-  virtual QImage    dumpView() { return QImage(); }
-
   SUIT_Desktop*     myDesktop;
   SUIT_ViewManager* myManager;
 };