[Uml-devel] branches/KDE/3.5/kdesdk/umbrello/umbrello
Oliver Kellogg
okellogg at users.sourceforge.net
Fri Aug 4 05:55:29 UTC 2006
SVN commit 569519 by okellogg:
getPackage(): Beautify.
M +3 -5 umlobject.cpp
M +2 -0 umlobject.h
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/umlobject.cpp #569518:569519
@@ -352,13 +352,11 @@
UMLPackageList pkgList;
QStringList pkgNames;
UMLPackage* pkg = m_pUMLPackage;
- while (1) {
+ do {
pkgList.prepend(pkg);
pkgNames.prepend(pkg->getName());
- if ((pkg = pkg->getUMLPackage()) == NULL ||
- pkgList.containsRef(pkg))
- break;
- }
+ pkg = pkg->getUMLPackage();
+ } while (pkg != NULL && !pkgList.containsRef(pkg));
if (separator.isEmpty())
separator = UMLApp::app()->activeLanguageScopeSeparator();
return pkgNames.join(separator);
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/umlobject.h #569518:569519
@@ -190,6 +190,8 @@
*
* @param separator Separator string for joining together the
* individual package prefixes (optional.)
+ * If no separator is given then the separator
+ * of the currently selected language is used.
* @return The UMLObject's enclosing package(s) as a text.
*/
QString getPackage(QString separator = QString::null);
More information about the umbrello-devel
mailing list