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

Andi Fischer andi.fischer at hispeed.ch
Sun May 1 16:53:52 UTC 2011


SVN commit 1230040 by fischer:

Krazy issues about operators that should be 'const' fixed.

 M  +2 -4      clipboard/idchangelog.cpp  
 M  +2 -2      clipboard/idchangelog.h  
 M  +3 -3      widgets/associationwidget.cpp  
 M  +3 -4      widgets/associationwidget.h  
 M  +2 -2      widgets/umlwidget.cpp  
 M  +2 -2      widgets/umlwidget.h  


--- trunk/KDE/kdesdk/umbrello/umbrello/clipboard/idchangelog.cpp #1230039:1230040
@@ -4,14 +4,12 @@
  *   the Free Software Foundation; either version 2 of the License, or     *
  *   (at your option) any later version.                                   *
  *                                                                         *
- *   copyright (C) 2002-2008                                               *
+ *   copyright (C) 2002-2011                                               *
  *   Umbrello UML Modeller Authors <uml-devel at uml.sf.net>                  *
  ***************************************************************************/
 
 #include "idchangelog.h"
 
-#include <kdebug.h>
-
 /**
  * Constructor.
  */
@@ -50,7 +48,7 @@
 /**
  * Overloaded '==' operator.
  */
-bool IDChangeLog::operator==(const IDChangeLog& Other)
+bool IDChangeLog::operator==(const IDChangeLog& Other) const
 {
     Q_UNUSED(Other);
     /*It needs to be Implemented*/
--- trunk/KDE/kdesdk/umbrello/umbrello/clipboard/idchangelog.h #1230039:1230040
@@ -4,7 +4,7 @@
  *   the Free Software Foundation; either version 2 of the License, or     *
  *   (at your option) any later version.                                   *
  *                                                                         *
- *   copyright (C) 2002-2008                                               *
+ *   copyright (C) 2002-2011                                               *
  *   Umbrello UML Modeller Authors <uml-devel at uml.sf.net>                  *
  ***************************************************************************/
 
@@ -34,7 +34,7 @@
 
     IDChangeLog& operator=(const IDChangeLog& Other);
 
-    bool operator==(const IDChangeLog& Other);
+    bool operator==(const IDChangeLog& Other) const;
 
     void addIDChange(Uml::IDType OldID, Uml::IDType NewID);
 
--- trunk/KDE/kdesdk/umbrello/umbrello/widgets/associationwidget.cpp #1230039:1230040
@@ -4,7 +4,7 @@
  *   the Free Software Foundation; either version 2 of the License, or     *
  *   (at your option) any later version.                                   *
  *                                                                         *
- *   copyright (C) 2002-2010                                               *
+ *   copyright (C) 2002-2011                                               *
  *   Umbrello UML Modeller Authors <uml-devel at uml.sf.net>                  *
  ***************************************************************************/
 
@@ -186,7 +186,7 @@
     return *this;
 }
 
-bool AssociationWidget::operator==(const AssociationWidget & Other)
+bool AssociationWidget::operator==(const AssociationWidget & Other) const
 {
     if( this == &Other )
         return true;
@@ -236,7 +236,7 @@
     return (getName() == Other.getName());
 }
 
-bool AssociationWidget::operator!=(AssociationWidget & Other)
+bool AssociationWidget::operator!=(AssociationWidget & Other) const
 {
     return !(*this == Other);
 }
--- trunk/KDE/kdesdk/umbrello/umbrello/widgets/associationwidget.h #1230039:1230040
@@ -1,11 +1,10 @@
 /***************************************************************************
- *                                                                         *
  *   This program is free software; you can redistribute it and/or modify  *
  *   it under the terms of the GNU General Public License as published by  *
  *   the Free Software Foundation; either version 2 of the License, or     *
  *   (at your option) any later version.                                   *
  *                                                                         *
- *   copyright (C) 2002-2006                                               *
+ *   copyright (C) 2002-2011                                               *
  *   Umbrello UML Modeller Authors <uml-devel at uml.sf.net>                  *
  ***************************************************************************/
 
@@ -99,12 +98,12 @@
     /**
      * Overrides the equality test operator.
      */
-    bool operator==(const AssociationWidget & Other);
+    bool operator==(const AssociationWidget & Other) const;
 
     /**
      * Overrides the != operator.
      */
-    bool operator!=(AssociationWidget & Other);
+    bool operator!=(AssociationWidget & Other) const;
 
     /**
      * Activates the AssociationWidget after a load.
--- trunk/KDE/kdesdk/umbrello/umbrello/widgets/umlwidget.cpp #1230039:1230040
@@ -4,7 +4,7 @@
  *   the Free Software Foundation; either version 2 of the License, or     *
  *   (at your option) any later version.                                   *
  *                                                                         *
- *   copyright (C) 2002-2010                                               *
+ *   copyright (C) 2002-2011                                               *
  *   Umbrello UML Modeller Authors <uml-devel at uml.sf.net>                  *
  ***************************************************************************/
 
@@ -122,7 +122,7 @@
     return *this;
 }
 
-bool UMLWidget::operator==(const UMLWidget& other)
+bool UMLWidget::operator==(const UMLWidget& other) const
 {
     if (this == &other)
         return true;
--- trunk/KDE/kdesdk/umbrello/umbrello/widgets/umlwidget.h #1230039:1230040
@@ -4,7 +4,7 @@
  *   the Free Software Foundation; either version 2 of the License, or     *
  *   (at your option) any later version.                                   *
  *                                                                         *
- *   copyright (C) 2002-2009                                               *
+ *   copyright (C) 2002-2011                                               *
  *   Umbrello UML Modeller Authors <uml-devel at uml.sf.net>                  *
  ***************************************************************************/
 
@@ -82,7 +82,7 @@
     /**
      * Overload '==' operator
      */
-    bool operator==(const UMLWidget& other);
+    bool operator==(const UMLWidget& other) const;
 
     /**
      * Calls the method with the same name in UMLWidgetController.




More information about the umbrello-devel mailing list