Salome HOME
Fix problem with 'Glue all coincident edges' option
[modules/geom.git] / src / EntityGUI / EntityGUI_PictureImportDlg.cxx
index dbd02bd5b08b87f6bf6bc8e87525300fba92deb3..05aa79e18156ab1d98232053bb1d4fbeba7e8028 100644 (file)
@@ -39,8 +39,7 @@
 #include <TopoDS.hxx>
 
 #include <GEOMImpl_Types.hxx>
-
-#include <ShapeRec_FeatureDetector.hxx>
+// #include <ShapeRec_FeatureDetector.hxx>
 
 #include <QFileDialog>
 
@@ -55,11 +54,8 @@ EntityGUI_PictureImportDlg::EntityGUI_PictureImportDlg( GeometryGUI* theGeometry
                                     bool modal, Qt::WindowFlags fl )
   : GEOMBase_Skeleton( theGeometryGUI, parent, modal, fl )
 {
-//   QPixmap image0( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_LINE_2P" ) ) );
   setWindowTitle( tr( "GEOM_IMPORT_PICT_TITLE" ) );
   mainFrame()->GroupConstructors->setTitle( tr( "GEOM_PICTURE" ) );
-//   mainFrame()->RadioButton1->setIcon( image0 );
-//   mainFrame()->RadioButton2->setIcon( image2 );
 
   mainFrame()->RadioButton2->setAttribute(Qt::WA_DeleteOnClose);
   mainFrame()->RadioButton2->close();
@@ -182,11 +178,9 @@ bool EntityGUI_PictureImportDlg::execute( ObjectList& objects )
   if ( theImgFileName.isEmpty() )
     return res;
   
-  ShapeRec_FeatureDetector* aDetector = new ShapeRec_FeatureDetector( theImgFileName );
-    
-  int height            =  aDetector->GetImgHeight();
-  int width             =  aDetector->GetImgWidth();
-  
+  QPixmap* pixmap = new QPixmap(theImgFileName); 
+  int height            =  pixmap->height();
+  int width             =  pixmap->width();
   
   GEOM::GEOM_Object_var P1 = aBasicOperations->MakePointXYZ( -0.5*width, -0.5*height, 0 );
   GEOM::GEOM_Object_var P2 = aBasicOperations->MakePointXYZ( -0.5*width,  0.5*height, 0 );