[Uml-devel] KDE/kdesdk/umbrello/umbrello

Ralf Habacker ralf.habacker at gmail.com
Sun Apr 1 09:19:04 UTC 2012


SVN commit 1287804 by habacker:

Removed get prefix of some getters to reduce difference to soc-umbrello branch.

 M  +2 -2      clipboard/umlclipboard.cpp  
 M  +2 -2      controller/umlwidgetcontroller.cpp  
 M  +14 -14    umlscene.cpp  
 M  +3 -3      umlscene.h  
 M  +1 -1      widgets/widget_factory.cpp  


--- trunk/KDE/kdesdk/umbrello/umbrello/clipboard/umlclipboard.cpp #1287803:1287804
@@ -79,14 +79,14 @@
         m_type = clip4;
         UMLView *view = UMLApp::app()->currentView();
         view->umlScene()->checkSelections();
-        if(!view->umlScene()->getSelectedWidgets(m_WidgetList)) {
+        if(!view->umlScene()->selectedWidgets(m_WidgetList)) {
             return 0;
         }
         //if there is no selected widget then there is no copy action
         if (!m_WidgetList.count()) {
             return 0;
         }
-        m_AssociationList = view->umlScene()->getSelectedAssocs();
+        m_AssociationList = view->umlScene()->selectedAssocs();
         view->umlScene()->copyAsImage(png);
 
     } else { //if the copy action is being performed from the ListView
--- trunk/KDE/kdesdk/umbrello/umbrello/controller/umlwidgetcontroller.cpp #1287803:1287804
@@ -248,7 +248,7 @@
 
     // Move any selected associations.
 
-    foreach(AssociationWidget* aw, m_widget->m_scene->getSelectedAssocs()) {
+    foreach(AssociationWidget* aw, m_widget->m_scene->selectedAssocs()) {
         if (aw->getSelected()) {
             aw->moveEntireAssoc(diffX, diffY);
         }
@@ -628,7 +628,7 @@
 {
     if (m_widget->m_scene->getSelectCount() > 0) {
         m_selectedWidgetsList.clear();
-        m_widget->m_scene->getSelectedWidgets(m_selectedWidgetsList, false);
+        m_widget->m_scene->selectedWidgets(m_selectedWidgetsList, false);
 
         updateSelectionBounds(1, 1);
     }
--- trunk/KDE/kdesdk/umbrello/umbrello/umlscene.cpp #1287803:1287804
@@ -291,7 +291,7 @@
 /**
  * Returns the position of the diagram.
  */
-UMLScenePoint UMLScene::getPos() const
+UMLScenePoint UMLScene::pos() const
 {
     return m_Pos;
 }
@@ -1404,7 +1404,7 @@
         temp->setLineColor(color);
         temp->setUsesDiagramLineColor(false);
     }
-    AssociationWidgetList assoclist = getSelectedAssocs();
+    AssociationWidgetList assoclist = selectedAssocs();
     foreach(AssociationWidget *aw , assoclist) {
         aw->setLineColor(color);
         aw->setUsesDiagramLineColor(false);
@@ -1421,7 +1421,7 @@
         temp->setLineWidth(width);
         temp->setUsesDiagramLineWidth(false);
     }
-    AssociationWidgetList assoclist = getSelectedAssocs();
+    AssociationWidgetList assoclist = selectedAssocs();
     foreach(AssociationWidget *aw , assoclist) {
         aw->setLineWidth(width);
         aw->setUsesDiagramLineWidth(false);
@@ -1749,7 +1749,7 @@
     foreach(UMLWidget* widget, m_SelectedList) {
         widget->setSelected(false);
     }
-    AssociationWidgetList selectedAssociationsList = getSelectedAssocs();
+    AssociationWidgetList selectedAssociationsList = selectedAssocs();
 
     foreach(AssociationWidget* association, selectedAssociationsList) {
         association->setSelected(false);
@@ -1899,7 +1899,7 @@
  * @param WidgetList The UMLWidgetList to fill.
  * @param filterText Don't append the text, unless their role is tr_Floating
  */
-bool UMLScene::getSelectedWidgets(UMLWidgetList &WidgetList, bool filterText /*= true*/)
+bool UMLScene::selectedWidgets(UMLWidgetList &WidgetList, bool filterText /*= true*/)
 {
     foreach(UMLWidget* temp, m_SelectedList) {
         if (filterText && temp->baseType() == WidgetBase::wt_Text) {
@@ -1916,7 +1916,7 @@
 /**
  * Returns a list with all the selected associations from the diagram
  */
-AssociationWidgetList UMLScene::getSelectedAssocs()
+AssociationWidgetList UMLScene::selectedAssocs()
 {
     AssociationWidgetList assocWidgetList;
 
@@ -4326,7 +4326,7 @@
 void UMLScene::alignLeft()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
 
@@ -4344,7 +4344,7 @@
 void UMLScene::alignRight()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
     int biggestX = getBiggestX(widgetList);
@@ -4361,7 +4361,7 @@
 void UMLScene::alignTop()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
 
@@ -4379,7 +4379,7 @@
 void UMLScene::alignBottom()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
     int biggestY = getBiggestY(widgetList);
@@ -4396,7 +4396,7 @@
 void UMLScene::alignVerticalMiddle()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
 
@@ -4416,7 +4416,7 @@
 void UMLScene::alignHorizontalMiddle()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
 
@@ -4436,7 +4436,7 @@
 void UMLScene::alignVerticalDistribute()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
 
@@ -4467,7 +4467,7 @@
 void UMLScene::alignHorizontalDistribute()
 {
     UMLWidgetList widgetList;
-    getSelectedWidgets(widgetList);
+    selectedWidgets(widgetList);
     if (widgetList.isEmpty())
         return;
 
--- trunk/KDE/kdesdk/umbrello/umbrello/umlscene.h #1287803:1287804
@@ -110,7 +110,7 @@
     Uml::IDType getID() const;
     void setID(Uml::IDType id);
 
-    UMLScenePoint getPos() const;
+    UMLScenePoint pos() const;
     void setPos(const UMLScenePoint &pos);
 
     const QColor& fillColor() const;
@@ -245,9 +245,9 @@
 
     void activate();
 
-    AssociationWidgetList getSelectedAssocs();
+    AssociationWidgetList selectedAssocs();
 
-    bool getSelectedWidgets(UMLWidgetList& WidgetList, bool filterText = true);
+    bool selectedWidgets(UMLWidgetList& WidgetList, bool filterText = true);
 
     void activateAfterLoad( bool bUseLog = false );
 
--- trunk/KDE/kdesdk/umbrello/umbrello/widgets/widget_factory.cpp #1287803:1287804
@@ -66,7 +66,7 @@
  */
 UMLWidget *createWidget(UMLScene *scene, UMLObject *o)
 {
-    QPoint pos = scene->getPos();
+    QPoint pos = scene->pos();
     int y = pos.y();
     Uml::DiagramType diagramType = scene->type();
     UMLObject::ObjectType type = o->baseType();




More information about the umbrello-devel mailing list