[Uml-devel] branches/KDE/3.5/kdesdk/umbrello/umbrello
Oliver Kellogg
okellogg at users.sourceforge.net
Sat Apr 14 13:47:53 UTC 2007
SVN commit 653885 by okellogg:
addWidget(): The paste code calls this also for MessageWidgets.
M +9 -6 umlview.cpp
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/umlview.cpp #653884:653885
@@ -1349,9 +1349,6 @@
}
void UMLView::activate() {
- if (!m_pDoc->loading()) {
- kError() << "UMLView::activate() called while not loading ?!?" << endl;
- }
UMLWidgetListIt it( m_WidgetList );
UMLWidget *obj;
@@ -1448,15 +1445,21 @@
if( !pWidget ) {
return false;
}
+ Widget_Type type = pWidget->getBaseType();
+ if (isPasteOperation) {
+ if (type == Uml::wt_Message)
+ m_MessageList.append(static_cast<MessageWidget*>(pWidget));
+ else
+ m_WidgetList.append(pWidget);
+ return true;
+ }
if (!isPasteOperation && findWidget(pWidget->getID())) {
kError() << "UMLView::addWidget: Not adding "
<< "(id=" << ID2STR(pWidget->getID())
- << "/type=" << pWidget->getBaseType()
- << "/name=" << pWidget->getName()
+ << "/type=" << type << "/name=" << pWidget->getName()
<< ") because it's already there" << endl;
return false;
}
- Widget_Type type = pWidget->getBaseType();
//kDebug() << "UMLView::addWidget called for basetype " << type << endl;
IDChangeLog * log = m_pDoc -> getChangeLog();
if( isPasteOperation && (!log || !m_pIDChangesLog)) {
More information about the umbrello-devel
mailing list