Salome HOME
Merge from OCC_development_generic_2006
[modules/superv.git] / src / SUPERVGUI / SUPERVGUI_CanvasView.cxx
index c33671658d7ee0419d38d0ac5c85d2243ea95aca..f2b54a7bb360728b6d53d5c3303afd59ec2b1aef 100644 (file)
@@ -8,8 +8,6 @@
 //  Author : Natalia KOPNOVA
 //  Module : SUPERV
 
-using namespace std;
-
 #include "SUPERVGUI.h"
 #include "SUPERVGUI_CanvasView.h"
 #include "SUPERVGUI_Main.h"
@@ -19,6 +17,8 @@ using namespace std;
 #include "SUPERVGUI_CanvasNodePrs.h"
 #include "SUPERVGUI_Clipboard.h"
 
+#include "SUPERVGUI_ArrayView.h" //for tooltip testing
+
 #include "SUIT_MessageBox.h"
 
 #include <qpixmap.h>
@@ -160,6 +160,9 @@ SUPERVGUI_CanvasView::SUPERVGUI_CanvasView(SUPERVGUI_Canvas* theCanvas, SUPERVGU
     myPopup->insertSeparator();
     myShowToolBarItem = myPopup->insertItem( tr( "MEN_SHOW_TOOLBAR" ), myMain, SLOT( onShowToolbar() ) );
   }
+
+  // mkr : PAL8237
+  connect(this, SIGNAL(objectCreated()), myMain, SLOT(onObjectCreatedDeleted()));
 }
  
 
@@ -439,6 +442,10 @@ void SUPERVGUI_CanvasView::contentsMouseMoveEvent(QMouseEvent* theEvent)
     setHilighted(0);
   }
 
+  // QToolTip for title and label for SUPERVGUI_CanvasNode
+  SUPERVGUI_ToolTip* aTT = new SUPERVGUI_ToolTip(this);
+  aTT->maybeTip(p);
+
   busy = false;
 }
 
@@ -677,6 +684,8 @@ void SUPERVGUI_CanvasView::endSketch(SUPERVGUI_CanvasPort* thePort)
     SUPERVGUI_CanvasLink* aLink = new SUPERVGUI_CanvasLink(canvas(), myMain, aLinkEngine);
     aLink->show();
 
+    emit objectCreated(); // mkr : PAL8237
+
     canvas()->update();
     myIsLinkCreating = false;