Bug 112333 - unchecking show operation signature create new functions in sequence diagrams
Summary: unchecking show operation signature create new functions in sequence diagrams
Status: RESOLVED FIXED
Alias: None
Product: umbrello
Classification: Applications
Component: general (show other bugs)
Version: 1.4.1
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: Umbrello Development Group
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-09 23:03 UTC by mag
Modified: 2005-09-11 22:45 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mag 2005-09-09 23:03:46 UTC
Version:           1.4.1 (using KDE KDE 3.4.1)
Installed from:    Gentoo Packages
Compiler:          GCC 3.3.4 
OS:                Linux

Hi,

     When you uncheck the "show operation signature" on a sequence diagram, and you add a new synchronous message afterward with a function that has some parameters, the application create a new empty function in the class without any parameter and link to this one.

Expected behavior :

     There should be a link created to the function selected in the "select operation" dialog box, instead of creating a new function and linking to that one.
Comment 1 Oliver Kellogg 2005-09-11 22:45:01 UTC
SVN commit 459784 by okellogg:

SelectOpDlg constructor: Include signatures in the ops filled into m_pOpCB.
MessageWidget::getSeqNumAndOp(): Include signature in the op returned from the
  UMLOperation.
FloatingText::setText(): Filter out signature from the op returned from
  MessageWidget::getSeqNumAndOp() when UMLView::getShowOpSig() is false.
BUG:112333


 M  +1 -1      ChangeLog  
 M  +1 -6      umbrello/dialogs/selectopdlg.cpp  
 M  +4 -2      umbrello/floatingtext.cpp  
 M  +1 -6      umbrello/messagewidget.cpp  


--- branches/KDE/3.5/kdesdk/umbrello/ChangeLog #459783:459784
@@ -11,7 +11,7 @@
 * Bugs fixed / wishes implemented (see http://bugs.kde.org)
  57588  57672  58809  66461  67120  67719  72016  79433  87252  88117
  97162 105564 108223 109591 109636 110073 110216 110231 110379 111088
-111470 111502 111759 111768 112017 112293
+111470 111502 111759 111768 112017 112293 112333
 
 Version 1.4.2 (maintenance release)
 
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/dialogs/selectopdlg.cpp #459783:459784
@@ -64,14 +64,9 @@
     m_pOpBG -> setExclusive(true);
     m_pOpBG -> setButton(OP);
 
-    Uml::Signature_Type sigType;
-    if (m_pView->getShowOpSig())
-        sigType = Uml::st_SigNoScope;
-    else
-        sigType = Uml::st_NoSigNoScope;
     UMLOperationList list = c -> getOpList(true);
     for (UMLOperation *obj = list.first(); obj; obj=list.next()) {
-        m_pOpCB->insertItem( obj->toString(sigType) );
+        m_pOpCB->insertItem( obj->toString(Uml::st_SigNoScope) );
     }
     //disableResize();
     connect(m_pOpBG, SIGNAL(clicked(int)), this, SLOT(slotSelected(int)));
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/floatingtext.cpp #459783:459784
@@ -193,9 +193,11 @@
     if (m_Role == Uml::tr_Seq_Message || m_Role == Uml::tr_Seq_Message_Self) {
         QString seqNum, op;
         m_pLink->getSeqNumAndOp(seqNum, op);
-        if (seqNum.length() > 0 || op.length() > 0)
+        if (seqNum.length() > 0 || op.length() > 0) {
+            if (! m_pView->getShowOpSig())
+                op.replace( QRegExp("\\(.*\\)"), "()" );
             m_Text = seqNum.append(": ").append( op );
-        else
+        } else
             m_Text = t;
     } else
         m_Text = t;
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/messagewidget.cpp #459783:459784
@@ -506,12 +506,7 @@
     seqNum = m_SequenceNumber;
     UMLOperation *pOperation = getOperation();
     if (pOperation != NULL) {
-        Uml::Signature_Type sigType;
-        if (m_pView->getShowOpSig())
-            sigType = Uml::st_SigNoScope;
-        else
-            sigType = Uml::st_NoSigNoScope;
-        op = pOperation->toString(sigType);
+        op = pOperation->toString(Uml::st_SigNoScope);
     } else {
         op = m_CustomOp;
     }