Version: 1.4.0-beta1 (using KDE KDE 3.3.1) Compiler: g++ (GCC) 3.3.5 (Debian 1:3.3.5-5) OS: Linux Hello, I tested version 1.4.0-beta1 compiled from source tarball from 2005-01-15 05:07. I generated cpp source from a simple class diagram. In the generators language options I selected "functions are inline". The one function defined in my sample class was correctly generated inline in the header file. But there is still a function definition of the same function in the cpp file as if it were no inline function. This makes compilation impossible.
I would like to suggest this patch to fix this issue Index: umbrello/codegenerators/cppsourcecodeoperation.cpp =================================================================== --- umbrello/codegenerators/cppsourcecodeoperation.cpp (revision 434093) +++ umbrello/codegenerators/cppsourcecodeoperation.cpp (working copy) @@ -40,7 +40,7 @@ void CPPSourceCodeOperation::updateContent( ) { CPPCodeGenerationPolicy * policy = (CPPCodeGenerationPolicy*) getParentDocument()->getParentGenerator()->getPolicy(); - bool isInlineMethod = policy->getAccessorsAreInline( ); + bool isInlineMethod = policy->getOperationsAreInline(); if(!isInlineMethod) setText(""); // change whatever it is to ""; @@ -57,7 +57,7 @@ UMLClassifier * c = doc->getParentClassifier(); UMLOperation * o = getParentOperation(); bool isInterface = doc->parentIsInterface(); - bool isInlineMethod = policy->getAccessorsAreInline( ); + bool isInlineMethod = policy->getOperationsAreInline(); // first, the comment on the operation QString comment = o->getDoc(); Index: umbrello/codegenerators/cppheadercodeoperation.cpp =================================================================== --- umbrello/codegenerators/cppheadercodeoperation.cpp (revision 434093) +++ umbrello/codegenerators/cppheadercodeoperation.cpp (working copy) @@ -40,7 +40,7 @@ void CPPHeaderCodeOperation::updateContent( ) { CPPCodeGenerationPolicy * policy = (CPPCodeGenerationPolicy*) getParentDocument()->getParentGenerator()->getPolicy(); - bool isInlineMethod = policy->getAccessorsAreInline( ); + bool isInlineMethod = policy->getOperationsAreInline( ); if(isInlineMethod) setText(""); // change whatever it is to ""; @@ -95,6 +95,8 @@ paramStr += ", "; } + // set using the sterreotype if apropriated + // set start/end method text QString startText = methodReturnType+" "+methodName+" ("+paramStr+")";
SVN commit 434368 by okellogg: BUG:97188 - updateContent(): Backport fix by Paulo Sehn. M +1 -1 ChangeLog M +10 -0 THANKS M +1 -1 umbrello/codegenerators/cppheadercodeoperation.cpp M +1 -1 umbrello/codegenerators/cppsourcecodeoperation.cpp --- branches/KDE/3.4/kdesdk/umbrello/ChangeLog #434367:434368 @@ -1,7 +1,7 @@ Version 1.4.2 (maintenance release) * Bugs fixed from http://bugs.kde.org : -72016 103170 106356 106632 106673 107101 107551 +72016 97188 103170 106356 106632 106673 107101 107551 108688 Version 1.4.1 (maintenance release) --- branches/KDE/3.4/kdesdk/umbrello/THANKS #434367:434368 @@ -20,29 +20,39 @@ Zoltan Bartko <bartko.zoltan @pobox.sk> Luis De la Parra Blum <lparrab @gmx.net> Raymond Bosman <bosman @hetnet.nl> +Ben Burton <bab @debian.org> Albert Cervera <albertca @jazzfree.com> Albert Astals Cid <tsdgeos @terra.es> Vincent Decorges <vincent.decorges @eivd.ch> +Jean-Remy Falleri <jr.falleri @gmail.com> +Andi Fischer <andi.fischer @hispeed.ch> Pascal Fleury <fleury @users.sourceforge.net> +Gregorio Guidi <g.guidi @sns.it> Esben Mose Hansen <esben @despammed.com> +Olaf Hartig <OleBowle @gmx.de> Michel Hermier <michel.hermier @wanadoo.fr> +Paul Hensgen <phensgen @bigpond.net.au> David Hugh-Jones <hughjonesd @yahoo.co.uk> Pekka J