Windows compatibility

This commit is contained in:
ana 2011-12-23 13:02:59 +00:00
parent 6b53386081
commit 1192c0b6c1

View File

@ -159,6 +159,7 @@ bool EntityGUI::OnMousePress( QMouseEvent* pe, SUIT_Desktop* parent, SUIT_ViewWi
aSketcherDlg->OnPointSelected( modifiers, aPnt ); // "feed" the point to point construction dialog aSketcherDlg->OnPointSelected( modifiers, aPnt ); // "feed" the point to point construction dialog
} // acceptMouseEvent() } // acceptMouseEvent()
} }
#ifdef WITH_OPENCV
if ( QString( aDlg->metaObject()->className() ).compare( "EntityGUI_FeatureDetectorDlg" ) == 0 ) if ( QString( aDlg->metaObject()->className() ).compare( "EntityGUI_FeatureDetectorDlg" ) == 0 )
{ {
EntityGUI_FeatureDetectorDlg* aCornerDlg = (EntityGUI_FeatureDetectorDlg*) aDlg; EntityGUI_FeatureDetectorDlg* aCornerDlg = (EntityGUI_FeatureDetectorDlg*) aDlg;
@ -189,7 +190,9 @@ bool EntityGUI::OnMousePress( QMouseEvent* pe, SUIT_Desktop* parent, SUIT_ViewWi
} // acceptMouseEvent() } // acceptMouseEvent()
} }
#endif
} }
return false; return false;
} }
@ -201,6 +204,7 @@ bool EntityGUI::OnMouseRelease( QMouseEvent* pe, SUIT_Desktop* parent, SUIT_View
{ {
MESSAGE("EntityGUI::OnMouseRelease") MESSAGE("EntityGUI::OnMouseRelease")
QDialog* aDlg = getGeometryGUI()->GetActiveDialogBox(); QDialog* aDlg = getGeometryGUI()->GetActiveDialogBox();
#ifdef WITH_OPENCV
if ( aDlg && ( QString( aDlg->metaObject()->className() ).compare( "EntityGUI_FeatureDetectorDlg" ) == 0 ) && if ( aDlg && ( QString( aDlg->metaObject()->className() ).compare( "EntityGUI_FeatureDetectorDlg" ) == 0 ) &&
theViewWindow->getViewManager()->getType() == OCCViewer_Viewer::Type() && theViewWindow->getViewManager()->getType() == OCCViewer_Viewer::Type() &&
pe->modifiers() != Qt::ControlModifier ) pe->modifiers() != Qt::ControlModifier )
@ -217,9 +221,11 @@ bool EntityGUI::OnMouseRelease( QMouseEvent* pe, SUIT_Desktop* parent, SUIT_View
aCornerDlg->setEndPnt( aPnt ); aCornerDlg->setEndPnt( aPnt );
} }
} }
#endif
return false; return false;
} }
//======================================================================= //=======================================================================
// function : ConvertClickToPoint() // function : ConvertClickToPoint()
// purpose : Returns the point clicked in 3D view // purpose : Returns the point clicked in 3D view