[Uml-devel] kdesdk/umbrello/umbrello

Luis De la Parra Blum lparrab at gmx.net
Tue Mar 4 16:15:15 UTC 2003


CVS commit by luis: 

UMLObjects should notify the world when they are modified.
added signal and some emits.


  M +9 -0      concept.cpp   1.7
  M +3 -0      umlobject.h   1.3


--- kdesdk/umbrello/umbrello/umlobject.h  #1.2:1.3
@@ -200,4 +200,7 @@ public:
   /** Sets the value for m_bStatic. */
   void setStatic(const bool bStatic);
+  
+signals:
+        void modified();  
 
 protected:

--- kdesdk/umbrello/umbrello/concept.cpp  #1.6:1.7
@@ -44,4 +44,5 @@ bool UMLConcept::addAssociation(UMLAssoc
         m_AssocsList.append( assoc );
         return true;
+        emit modified();
 }
 ////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -57,4 +58,5 @@ int UMLConcept::removeAssociation(UMLObj
                 return -1;
         }
+        emit modified();
         return m_AssocsList.count();
 }
@@ -63,4 +65,5 @@ UMLObject* UMLConcept::addAttribute(QStr
         UMLAttribute *a = new UMLAttribute(this, name, id);
         m_AttsList.append(a);
+        emit modified();
         return a;
 }
@@ -72,4 +75,5 @@ bool UMLConcept::addAttribute(UMLAttribu
                 this -> insertChild( Att );
                 m_AttsList.append( Att );
+                emit modified();
                 return true;
         } else if( Log ) {
@@ -85,4 +89,5 @@ int UMLConcept::removeAttribute(UMLObjec
                 return -1;
         }
+        emit modified();
         return m_AttsList.count();
 }
@@ -119,4 +124,5 @@ UMLObject* UMLConcept::addOperation(QStr
         UMLOperation *o = new UMLOperation(this, name, id);
         m_OpsList.append(o);
+        emit modified();
         return o;
 }
@@ -124,4 +130,5 @@ UMLObject* UMLConcept::addOperation(QStr
 bool UMLConcept::addOperation(UMLOperation* Op) {
         m_OpsList.append( Op );
+        emit modified();
         return true;
 }
@@ -133,4 +140,5 @@ bool UMLConcept::addOperation(UMLOperati
                 this -> insertChild( Op );
                 m_OpsList.append( Op );
+                emit modified();
                 return true;
         } else if( Log ) {
@@ -146,4 +154,5 @@ int UMLConcept::removeOperation(UMLObjec
                 return -1;
         }
+        emit modified();
         return m_OpsList.count();
 }






More information about the umbrello-devel mailing list