[Uml-devel] branches/work/soc-umbrello/umbrello

Andi Fischer andi.fischer at hispeed.ch
Sun Apr 1 20:17:25 UTC 2012


SVN commit 1287860 by fischer:

Differences to trunk reduced.

 M  +7 -6      umlscene.cpp  
 M  +2 -2      umlscene.h  


--- branches/work/soc-umbrello/umbrello/umlscene.cpp #1287859:1287860
@@ -271,7 +271,7 @@
 /**
  * Returns the position of the diagram.
  */
-QPointF UMLScene::pos() const
+UMLScenePoint UMLScene::pos() const
 {
     return m_Pos;
 }
@@ -279,7 +279,7 @@
 /**
  * Sets the position of the diagram.
  */
-void UMLScene::setPos(const QPointF &pos)
+void UMLScene::setPos(const UMLScenePoint &pos)
 {
     m_Pos = pos;
 }
@@ -684,6 +684,7 @@
  */
 void UMLScene::slotObjectCreated(UMLObject* o)
 {
+    DEBUG(DBG_SRC) << "view=" << name() << " / object=" << o->name();
     m_bPaste = false;
     //check to see if we want the message
     //may be wanted by someone else e.g. list view
@@ -921,7 +922,7 @@
  * @return The widget thats line was clicked on.
  *  Returns 0 if no line was clicked on.
  */
-ObjectWidget * UMLScene::onWidgetLine(const QPointF &point) const
+ObjectWidget * UMLScene::onWidgetLine(const UMLScenePoint &point) const
 {
     QGraphicsItem* itemAtPoint = itemAt(point);
     DEBUG(DBG_SRC) << Q_FUNC_INFO << itemAtPoint;
@@ -940,7 +941,7 @@
  * @return The widget thats destruction box was clicked on.
  *  Returns 0 if no destruction box was clicked on.
  */
-ObjectWidget * UMLScene::onWidgetDestructionBox(const QPointF &point) const
+ObjectWidget * UMLScene::onWidgetDestructionBox(const UMLScenePoint &point) const
 {
     foreach(UMLWidget* obj,  m_WidgetList) {
         ObjectWidget *ow = dynamic_cast<ObjectWidget*>(obj);
@@ -977,7 +978,7 @@
  * Returns NULL if the point is not inside any widget.
  * Does not use or modify the m_pOnWidget member.
  */
-UMLWidget *UMLScene::widgetAt(const QPointF& p)
+UMLWidget *UMLScene::widgetAt(const UMLScenePoint& p)
 {
     qreal metric = 99990.0;
     UMLWidget  *retWid = 0;
@@ -1937,7 +1938,7 @@
             return true;
         }
         // CHECK
-        // Handling of wt_Message:
+        // Handling of WidgetBase::wt_Message:
         MessageWidget *pMessage = static_cast<MessageWidget *>(pWidget);
         if (pMessage == NULL) {
             DEBUG(DBG_SRC) << "pMessage is NULL";
--- branches/work/soc-umbrello/umbrello/umlscene.h #1287859:1287860
@@ -388,7 +388,7 @@
     void forceUpdateWidgetFontMetrics(QPainter *painter);
 
     int m_nCollaborationId;  ///< Used for creating unique name of collaboration messages.
-    QPointF m_Pos;
+    UMLScenePoint m_Pos;
     bool m_bCreateObject;
     bool m_bDrawSelectedOnly;
     bool m_bPaste;
@@ -413,7 +413,7 @@
     IDChangeLog * m_pIDChangesLog;  ///< LocalID Changes Log for paste actions
     bool m_isActivated;             ///< True if the view was activated after the serialization(load).
     bool m_bPopupShowing;           ///< Status of a popupmenu on view. True - a popup is on view.
-    QPointF m_PastePoint;           ///< The offset at which to paste the clipboard.
+    UMLScenePoint m_PastePoint;     ///< The offset at which to paste the clipboard.
     UMLDoc* m_doc;                 ///< Pointer to the UMLDoc.
     UMLViewImageExporter* m_pImageExporter;  ///< Used to export the view.
     LayoutGrid*  m_layoutGrid;      ///< layout grid in the background




More information about the umbrello-devel mailing list