Hello community,

here is the log from the commit of package umbrello for openSUSE:Factory 
checked in at 2015-10-24 10:29:18
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/umbrello (Old)
 and      /work/SRC/openSUSE:Factory/.umbrello.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "umbrello"

Changes:
--------
--- /work/SRC/openSUSE:Factory/umbrello/umbrello.changes        2015-10-03 
20:27:13.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.umbrello.new/umbrello.changes   2015-10-24 
10:29:29.000000000 +0200
@@ -1,0 +2,8 @@
+Sun Oct 11 13:48:05 UTC 2015 - [email protected]
+
+- Update to KDE Applications 15.08.2
+   * KDE Applications 15.08.2 
+   * https://www.kde.org/announcements/announce-applications-15.08.2.php
+
+
+-------------------------------------------------------------------

Old:
----
  umbrello-15.08.1.tar.xz

New:
----
  umbrello-15.08.2.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ umbrello.spec ++++++
--- /var/tmp/diff_new_pack.mRKAni/_old  2015-10-24 10:29:30.000000000 +0200
+++ /var/tmp/diff_new_pack.mRKAni/_new  2015-10-24 10:29:30.000000000 +0200
@@ -24,7 +24,7 @@
 License:        GPL-2.0 and GFDL-1.2
 Group:          Development/Tools/Other
 Url:            http://www.kde.org/
-Version:        15.08.1
+Version:        15.08.2
 Release:        0
 Source0:        %{name}-%{version}.tar.xz
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build

++++++ umbrello-15.08.1.tar.xz -> umbrello-15.08.2.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/CMakeLists.txt 
new/umbrello-15.08.2/CMakeLists.txt
--- old/umbrello-15.08.1/CMakeLists.txt 2015-09-10 00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/CMakeLists.txt 2015-10-09 02:00:55.000000000 +0200
@@ -3,7 +3,7 @@
 # KDE Application Version, managed by release script
 set (KDE_APPLICATIONS_VERSION_MAJOR "15")
 set (KDE_APPLICATIONS_VERSION_MINOR "08")
-set (KDE_APPLICATIONS_VERSION_MICRO "1")
+set (KDE_APPLICATIONS_VERSION_MICRO "2")
 
 set(UMBRELLO_VERSION_MAJOR "2")
 set(UMBRELLO_VERSION_MINOR "17")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/CMakeLists.txt 
new/umbrello-15.08.2/umbrello/CMakeLists.txt
--- old/umbrello-15.08.1/umbrello/CMakeLists.txt        2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/CMakeLists.txt        2015-10-09 
02:00:55.000000000 +0200
@@ -435,6 +435,8 @@
     port.cpp
     stereotype.cpp
     template.cpp
+    stereotypeswindow.cpp
+    stereotypesmodel.cpp
     toolbarstatearrow.cpp
     toolbarstateassociation.cpp
     toolbarstate.cpp
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/classifier.cpp 
new/umbrello-15.08.2/umbrello/classifier.cpp
--- old/umbrello-15.08.1/umbrello/classifier.cpp        2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/classifier.cpp        2015-10-09 
02:00:55.000000000 +0200
@@ -100,7 +100,7 @@
             newIcon = Icon_Utils::it_Datatype;
             break;
         case ot_Package:
-            UMLObject::setStereotypeCmd(QLatin1String("package"));
+            UMLObject::setStereotypeCmd(QString());
             UMLObject::m_bAbstract = false;
             newIcon = Icon_Utils::it_Package;
             break;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/codeimport/sqlimport.cpp 
new/umbrello-15.08.2/umbrello/codeimport/sqlimport.cpp
--- old/umbrello-15.08.1/umbrello/codeimport/sqlimport.cpp      2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/codeimport/sqlimport.cpp      2015-10-09 
02:00:55.000000000 +0200
@@ -290,6 +290,7 @@
  *  [ CONSTRAINT constraint_name ]
  *  { NOT NULL |
  *    NULL |
+ *    CHARACTER SET <format> |
  *    CHECK ( expression ) |
  *    DEFAULT default_expr |
  *    UNIQUE index_parameters |
@@ -311,6 +312,18 @@
     int index = m_srcIndex;
 
     while(token != QLatin1String(",") && token != QLatin1String(")")) {
+        if (token.toLower() == QLatin1String("character")) { // mysql
+            token = advance(); // set
+            if (token.toLower() == QLatin1String("set")) {
+                constraints.characterSet = advance(); // <value>
+                token = advance();
+            }
+            else {
+                m_srcIndex--; // take back
+                token = m_source[m_srcIndex];
+            }
+        }
+
         if (token.toLower() == QLatin1String("collate")) { // mysql
             constraints.collate = advance();
             token = advance();
@@ -440,6 +453,7 @@
         if (index == m_srcIndex) {
             log(m_parsedFiles.first(), QLatin1String("could not parse column 
constraint '") + token + QLatin1String("'"));
             token = advance();
+            index = m_srcIndex;
         }
     }
     return constraints;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/codeimport/sqlimport.h 
new/umbrello-15.08.2/umbrello/codeimport/sqlimport.h
--- old/umbrello-15.08.1/umbrello/codeimport/sqlimport.h        2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/codeimport/sqlimport.h        2015-10-09 
02:00:55.000000000 +0200
@@ -59,6 +59,7 @@
         QString collate;
         QString defaultValue;
         QString constraintName;
+        QString characterSet;
     };
 
     class TableConstraints {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/dialogs/notedialog.cpp 
new/umbrello-15.08.2/umbrello/dialogs/notedialog.cpp
--- old/umbrello-15.08.1/umbrello/dialogs/notedialog.cpp        2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/dialogs/notedialog.cpp        2015-10-09 
02:00:55.000000000 +0200
@@ -36,6 +36,7 @@
     QVBoxLayout *layout = new QVBoxLayout(frame);
     layout->addWidget(m_docWidget, 10);
     setMinimumSize(600, 250);
+    m_docWidget->setFocus();
 }
 
 /**
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/umbrello-15.08.1/umbrello/dialogs/widgets/documentationwidget.cpp 
new/umbrello-15.08.2/umbrello/dialogs/widgets/documentationwidget.cpp
--- old/umbrello-15.08.1/umbrello/dialogs/widgets/documentationwidget.cpp       
2015-09-10 00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/dialogs/widgets/documentationwidget.cpp       
2015-10-09 02:00:55.000000000 +0200
@@ -67,6 +67,8 @@
     m_editField->setLineWrapMode(QTextEdit::WidgetWidth);
     m_editField->setWordWrapMode(QTextOption::WordWrap);
     m_editField->setText(text);
+    setFocusProxy(m_editField);
+
     QHBoxLayout *layout = new QHBoxLayout(m_box);
     layout->addWidget(m_editField);
     layout->setMargin(fontMetrics().height());
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/docwindow.cpp 
new/umbrello-15.08.2/umbrello/docwindow.cpp
--- old/umbrello-15.08.1/umbrello/docwindow.cpp 2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/docwindow.cpp 2015-10-09 02:00:55.000000000 
+0200
@@ -91,6 +91,7 @@
     statusLayout->addWidget(m_modifiedWidget, 0, 5, 1, 1);
     m_docTE = new KTextEdit(this);
     m_docTE->setText(QString());
+    setFocusProxy(m_docTE);
     //m_docTE->setWordWrapMode(QTextEdit::WidgetWidth);
     QVBoxLayout* docLayout = new QVBoxLayout(this);
     docLayout->addLayout(statusLayout);
@@ -461,5 +462,6 @@
                 tab->setCurrentIndex(i);
         }
     }
+    m_docTE->setFocus();
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/umbrello-15.08.1/umbrello/org.kde.umbrello.appdata.xml 
new/umbrello-15.08.2/umbrello/org.kde.umbrello.appdata.xml
--- old/umbrello-15.08.1/umbrello/org.kde.umbrello.appdata.xml  1970-01-01 
01:00:00.000000000 +0100
+++ new/umbrello-15.08.2/umbrello/org.kde.umbrello.appdata.xml  2015-10-09 
02:00:55.000000000 +0200
@@ -0,0 +1,136 @@
+<?xml version="1.0" encoding="utf-8"?>
+<component type="desktop">
+  <id>org.kde.umbrello.desktop</id>
+  <metadata_license>CC0-1.0</metadata_license>
+  <project_license>GPL-2.0+</project_license>
+  <name>Umbrello</name>
+  <name xml:lang="ca">Umbrello</name>
+  <name xml:lang="cs">Umbrello</name>
+  <name xml:lang="de">Umbrello</name>
+  <name xml:lang="en-GB">Umbrello</name>
+  <name xml:lang="es">Umbrello</name>
+  <name xml:lang="et">Umbrello</name>
+  <name xml:lang="fi">Umbrello</name>
+  <name xml:lang="gl">Umbrello</name>
+  <name xml:lang="it">Umbrello</name>
+  <name xml:lang="nl">Umbrello</name>
+  <name xml:lang="pl">Umbrello</name>
+  <name xml:lang="pt">Umbrello</name>
+  <name xml:lang="pt-BR">Umbrello</name>
+  <name xml:lang="sk">Umbrello</name>
+  <name xml:lang="sl">Umbrello</name>
+  <name xml:lang="sv">Umbrello</name>
+  <name xml:lang="uk">Umbrello</name>
+  <name xml:lang="x-test">xxUmbrelloxx</name>
+  <summary>UML Modeller</summary>
+  <summary xml:lang="ca">Modelador UML</summary>
+  <summary xml:lang="cs">UML modelář</summary>
+  <summary xml:lang="de">UML-Modeller</summary>
+  <summary xml:lang="en-GB">UML Modeller</summary>
+  <summary xml:lang="es">Modelador UML</summary>
+  <summary xml:lang="et">UML-i modelleerimise rakendus</summary>
+  <summary xml:lang="fi">UML-mallinnusohjelma</summary>
+  <summary xml:lang="gl">Modelador de UML</summary>
+  <summary xml:lang="it">Modellatore UML</summary>
+  <summary xml:lang="nl">UML-modeller</summary>
+  <summary xml:lang="pl">Program do modelowania UML</summary>
+  <summary xml:lang="pt">Modelador de UML</summary>
+  <summary xml:lang="pt-BR">Modelador de UML</summary>
+  <summary xml:lang="sk">Modelár UML</summary>
+  <summary xml:lang="sl">Modelirnik UML</summary>
+  <summary xml:lang="sv">UML-modellering</summary>
+  <summary xml:lang="uk">Засіб моделювання UML</summary>
+  <summary xml:lang="x-test">xxUML Modellerxx</summary>
+  <description>
+    <p>
+      Umbrello is a Unified Modelling Language (UML) modelling tool and code 
generator.
+      It can create diagrams of software and other systems in the 
industry-standard UML format, and can also generate code from UML diagrams
+      in a variety of programming languages.
+    </p>
+    <p xml:lang="ca">L'Umbrello és una eina de modelatge de Llenguatge 
Unificat de Modelatge (UML) i generador de codi. Pot crear diagrames de 
programari i altres sistemes en el format UML estàndard de la indústria, i 
també pot generar codi des de diagrames UML en diversos llenguatges de 
programació.</p>
+    <p xml:lang="en-GB">Umbrello is a Unified Modelling Language (UML) 
modelling tool and code generator. It can create diagrams of software and other 
systems in the industry-standard UML format, and can also generate code from 
UML diagrams in a variety of programming languages.</p>
+    <p xml:lang="es">Umbrello es una herramienta de modelado y de generación 
de código para el lenguaje unificado de modelado (UML). Puede crear diagramas 
de software y de otros sistemas en el formato estándar de la industria UML, 
además de generar código a partir de diagramas UML en diversos lenguajes de 
programación.</p>
+    <p xml:lang="et">Umbrello on unifitseeritud modelleerimiskeele UML 
modelleerimistööriist ja koodi genereerija. See võib luua tarkvara ja muude 
süsteemide skeeme standardses UML-vormingus, samuti genereerida UML-skeemide 
põhjal koodi mitmes programmeerimiskeeles.</p>
+    <p xml:lang="fi">Umbrello on UML-mallinnusohjelma. Umbrellolla voi luoda 
kaavioita ohjelmistoista ja muista järjestelmistä käyttäen standardia 
UML-muotoa. Sillä voi myös luoda koodin UML-kaavioiden perusteella useille 
ohjelmointikielille.</p>
+    <p xml:lang="gl">Umbrello é unha ferramenta de modelaxe e xerador de 
código baseado na linguaxe de modelaxe UML. Pode crear diagramas de software e 
doutros sistemas usando o formato estándar da industria, UML, e pode tamén 
xerar código a partir de diagramas UML en varios linguaxes de programación.</p>
+    <p xml:lang="it">Umbrello è uno strumento per diagrammi UML e un 
generatore di codice. Può creare diagrammi di software e altri sistemi nello 
standard industriale UML, e può anche generare codice partendo dai diagrammi 
UML in diversi linguaggi di programmazione.</p>
+    <p xml:lang="nl">Umbrello is een Unified Modelling Language (UML) 
hulpmiddel voor modellering en generator van code. Het kan diagrammen van 
software en andere systemen maken  in het industrie-standaard UML-formaat en 
kan ook code genereren uit UML diagrammen in een verscheidenheid van 
programmeertalen.</p>
+    <p xml:lang="pl">Umbrello jest Unified Modelling Language (UML) (z ang. 
Językiem do Jednolitego Modelowania)  i generatorem kodu. Może tworzyć diagramy 
oprogramowania i innych systemów w formacie standardu przemysłowego UML, a 
także generować kod z diagramów UML w wielu językach programowania.</p>
+    <p xml:lang="pt">O Umbrello é uma ferramenta de modelação em UML (Unified 
Modelling Language) e gerador de código. Poderá criar diagramas de aplicações e 
outros sistemas, usando o formato-padrão da indústria UML, podendo também gerar 
código a partir de diagramas UML, numa grande variedade de linguagens de 
programação.</p>
+    <p xml:lang="pt-BR">Umbrello é uma ferramenta de modelação de UML (Unified 
Modelling Language) e gerador de código. Ele pode criar diagramas de softwares 
e outros sistemas, usando o formato de UML padrão da indústria, assim como 
gerar código a partir de diagramas UML, em uma grande variedade de linguagens 
de programação.</p>
+    <p xml:lang="sk">Umbrello je nástroj na modelovania v UML a generátor 
kódu. Dokáže vytvárať diagramy softvéru a iných systémov v priemyselnom 
štandarde UML a tiež generovať kód z UML diagramov v množstve programovacích 
jazykov.</p>
+    <p xml:lang="sl">Umbrello je orodje za modeliranje v poenotenem jeziku za 
modeliranje (UML) in ustvarjalnik kode. Ustvari lahko diagrame programov in 
drugih sistemov v industrijski standardizirani obliki UML, iz diagramov UML pa 
lahko ustvari tudi kodo v različnih programskih jezikih.</p>
+    <p xml:lang="sv">Umbrello är ett modelleringsverktyg för Unified Modelling 
Language och kodgenerator. Det kan skapa diagram av programvara och andra 
system med industristandardformatet UML, och kan också skapa kod från 
UML-diagram på ett antal olika programspråk.</p>
+    <p xml:lang="uk">Umbrello — засіб моделювання уніфікованою мовою 
моделювання (UML) та інструмент для створення шаблонів коду. Програма здатна 
створювати діаграми систем програмного забезпечення та інших систем у 
стандартному форматі UML та реалізовувати діаграми UML у програмному коді 
багатьма мовами програмування.</p>
+    <p xml:lang="x-test">xxUmbrello is a Unified Modelling Language (UML) 
modelling tool and code generator. It can create diagrams of software and other 
systems in the industry-standard UML format, and can also generate code from 
UML diagrams in a variety of programming languages.xx</p>
+    <p>Features:</p>
+    <p xml:lang="ca">Característiques:</p>
+    <p xml:lang="cs">Vlastnosti:</p>
+    <p xml:lang="de">Funktionen:</p>
+    <p xml:lang="en-GB">Features:</p>
+    <p xml:lang="es">Funciones:</p>
+    <p xml:lang="et">Omadused:</p>
+    <p xml:lang="fi">Ominaisuuksia:</p>
+    <p xml:lang="gl">Funcionalidades:</p>
+    <p xml:lang="it">Funzionalità:</p>
+    <p xml:lang="nl">Kenmerken:</p>
+    <p xml:lang="pl">Możliwości:</p>
+    <p xml:lang="pt">Funcionalidades:</p>
+    <p xml:lang="pt-BR">Funcionalidades:</p>
+    <p xml:lang="sk">Funkcie:</p>
+    <p xml:lang="sl">Zmožnosti:</p>
+    <p xml:lang="sv">Funktioner:</p>
+    <p xml:lang="uk">Можливості:</p>
+    <p xml:lang="x-test">xxFeatures:xx</p>
+    <ul>
+      <li>Supported formats: XMI</li>
+      <li xml:lang="ca">Formats acceptats: XMI</li>
+      <li xml:lang="cs">Podporované formáty: XMI</li>
+      <li xml:lang="de">Unterstützte Formate: XMI</li>
+      <li xml:lang="en-GB">Supported formats: XMI</li>
+      <li xml:lang="es">Formatos permitidos: XMI</li>
+      <li xml:lang="et">Toetatud vormingud: XMI</li>
+      <li xml:lang="fi">Tukee XMI-tiedostomuotoa</li>
+      <li xml:lang="gl">Formatos compatíbeis: XMI.</li>
+      <li xml:lang="it">Formati supportati: XMI</li>
+      <li xml:lang="nl">Ondersteunde formaten: XMI</li>
+      <li xml:lang="pl">Obsługiwane formaty: XMI</li>
+      <li xml:lang="pt">Formatos suportados: XMI</li>
+      <li xml:lang="pt-BR">Formatos suportados: XMI</li>
+      <li xml:lang="sk">Podporované formáty: XMI</li>
+      <li xml:lang="sl">Podprte oblike: XMI</li>
+      <li xml:lang="sv">Format som stöds: XMI</li>
+      <li xml:lang="uk">Підтримувані формати: XMI</li>
+      <li xml:lang="x-test">xxSupported formats: XMIxx</li>
+      <li>Several type of diagrams supported: use case, class, sequence, 
collaboration, state, activity, component, deployment, entity relationship</li>
+      <li xml:lang="ca">Es permeten diversos tipus de diagrames: cas d'ús, 
classe, seqüència, col·laboració, estat, activitat, component, desplegament, 
entitat relació</li>
+      <li xml:lang="en-GB">Several type of diagrams supported: use case, 
class, sequence, collaboration, state, activity, component, deployment, entity 
relationship</li>
+      <li xml:lang="es">Permite usar varios tipos de diagramas: casos de uso, 
clase, secuencia, colaboración, estado, actividad, componente, despliegue y 
relación de entidades</li>
+      <li xml:lang="et">Toetatud on mitut tüüpi skeemid: kasutus, klass, 
järgnevus, koostöö, olek, tegevus, komponent, evitus, olem-seos</li>
+      <li xml:lang="fi">Tukee monenlaisia kaavioita: käyttötapauskaavio, 
luokkakaavio, sekvenssikaavio, yhteistyökaavio, tilakaavio, aktiviteettikaavio, 
komponenttikaavio, sijoittelukaavio, käsitekaavio</li>
+      <li xml:lang="gl">Permite traballar con varios tipos de diagramas: caso 
de uso, clase, secuencia, colaboración, estado, actividade, compoñente, 
distribución, e entidade-relación.</li>
+      <li xml:lang="it">Diversi tipi di diagrammi supportati: casi d'uso, 
classe, sequenza, collaborazione, stato, attività, componente, dispiegamento, 
relazione tra entità</li>
+      <li xml:lang="nl">Verschillende typen diagrammen worden ondersteund: use 
case, klassen, volgorde, samenwerking, status, activiteit, component, 
deployment, relaties tussen eenheden</li>
+      <li xml:lang="pl">Kilka obsługiwanych rodzajów diagramów: przypadki 
użycia, klasy, sekwencje, kolaboracje, stany, aktywności, składniki, 
zastosowanie, współzależności obiektów</li>
+      <li xml:lang="pt">Diversos tipos de diagramas suportados: casos de uso, 
classe, sequência, colaboração, estado, actividade, componente, entrada em 
produção, entidade-associação</li>
+      <li xml:lang="pt-BR">Há suporte para diversos tipos de diagramas: casos 
de uso, classe, sequência, colaboração, estado, atividade, componente, 
distribuição, relacionamento de entidade</li>
+      <li xml:lang="sk">Podporovaných je niekoľko typov diagramov: prípady 
použitia, triedy, sekvencie, stavy, aktivity, nasadenie, vzžahy entít</li>
+      <li xml:lang="sl">Podprte so številne vrste diagramov: primer uporabe, 
razred, zaporedje, sodelovanje, stanje, dejavnost, sestavni del, namestitev, 
odvisnost entitete</li>
+      <li xml:lang="sv">Flera diagramtyper stöds: användningsfall, klass, 
sekvens, samarbete, tillstånd, aktivitet, komponent, utplacering, 
objektsamband</li>
+      <li xml:lang="uk">Підтримка декількох типів діаграм: випадків 
використання, класів, послідовності, співпраці, станів, компонент, розміщення 
та взаємозв’язку компонентів.</li>
+      <li xml:lang="x-test">xxSeveral type of diagrams supported: use case, 
class, sequence, collaboration, state, activity, component, deployment, entity 
relationshipxx</li>
+    </ul>
+  </description>
+  <url type="homepage">http://umbrello.kde.org</url>
+  <url 
type="bugtracker">https://bugs.kde.org/enter_bug.cgi?format=guided&amp;product=umbrello</url>
+  <url 
type="help">http://docs.kde.org/stable/en/kdesdk/umbrello/index.html</url>
+  <screenshots>
+    <screenshot type="default">
+      <image>http://kde.org/images/screenshots/umbrello.png</image>
+    </screenshot>
+  </screenshots>
+  <project_group>KDE</project_group>
+  <provides>
+    <binary>umbrello</binary>
+  </provides>
+</component>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/stereotype.cpp 
new/umbrello-15.08.2/umbrello/stereotype.cpp
--- old/umbrello-15.08.1/umbrello/stereotype.cpp        2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/stereotype.cpp        2015-10-09 
02:00:55.000000000 +0200
@@ -59,6 +59,7 @@
  */
 UMLStereotype::~UMLStereotype()
 {
+    //Q_ASSERT(m_refCount == 0);
 }
 
 /**
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/stereotypesmodel.cpp 
new/umbrello-15.08.2/umbrello/stereotypesmodel.cpp
--- old/umbrello-15.08.1/umbrello/stereotypesmodel.cpp  1970-01-01 
01:00:00.000000000 +0100
+++ new/umbrello-15.08.2/umbrello/stereotypesmodel.cpp  2015-10-09 
02:00:55.000000000 +0200
@@ -0,0 +1,124 @@
+/***************************************************************************
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) any later version.                                   *
+ *                                                                         *
+ *   copyright (C) 2015                                                    *
+ *   Umbrello UML Modeller Authors <[email protected]>                *
+ ***************************************************************************/
+
+#include "stereotypesmodel.h"
+
+// app includes
+#include "stereotype.h"
+#include "uml.h"
+#include "umldoc.h"
+
+// kde includes
+#include <KLocalizedString>
+
+// qt includes
+#include <QtDebug>
+
+// TODO: remove in 2.18
+#define I18N(a) QLatin1String(a)
+
+StereotypesModel::StereotypesModel(UMLStereotypeList *stereotypes)
+  : m_count(0),
+    m_stereotypes(stereotypes)
+{
+}
+
+int StereotypesModel::rowCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+
+    int count = m_stereotypes->count();
+    return count;
+}
+
+int StereotypesModel::columnCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+
+    return 2;
+}
+
+QVariant StereotypesModel::headerData(int section, Qt::Orientation 
orientation, int role) const
+{
+    if (section < 0)
+        return QVariant();
+
+    if (role != Qt::DisplayRole)
+        return QVariant();
+
+    if (orientation == Qt::Vertical)
+        return section + 1;
+    if (section == 0)
+        return QVariant(I18N("Name"));
+    else if (section == 1)
+        return QVariant(I18N("Usage"));
+    else return QVariant();
+}
+
+QVariant StereotypesModel::data(const QModelIndex & index, int role) const
+{
+    if (role == Qt::UserRole && index.column() == 0) {
+        QVariant v;
+        v.setValue(m_stereotypes->at(index.row()));
+        return v;
+    }
+
+    if (role != Qt::DisplayRole)
+        return QVariant();
+
+    int cCount = columnCount(index);
+    if (index.column() >= cCount)
+        return QVariant();
+
+    UMLStereotype *s = m_stereotypes->at(index.row());
+    if (cCount == 1) {
+        QString a = s->name() + QString(QLatin1String(" 
(%1)")).arg(s->refCount());
+        return a;
+      }
+
+    // table view
+    if (index.column() == 0)
+        return s->name();
+    else
+        return s->refCount();
+}
+
+bool StereotypesModel::addStereotype(UMLStereotype *stereotype)
+{
+    if (m_stereotypes->contains(stereotype))
+        return false;
+    int index = m_stereotypes->count();
+    beginInsertRows(QModelIndex(), index, index);
+    m_stereotypes->append(stereotype);
+    endInsertRows();
+    return true;
+}
+
+bool StereotypesModel::removeStereotype(UMLStereotype *stereotype)
+{
+    if (!m_stereotypes->contains(stereotype))
+        return false;
+    int index = m_stereotypes->indexOf(stereotype);
+    beginRemoveRows(QModelIndex(), index, index);
+    m_stereotypes->removeAll(stereotype);
+    endRemoveRows();
+    return true;
+}
+
+void StereotypesModel::emitDataChanged(const QModelIndex &index)
+{
+    emit dataChanged(index, index);
+}
+
+void StereotypesModel::emitDataChanged(int index)
+{
+    QModelIndex mi = createIndex(index,0);
+    emit dataChanged(mi, mi);
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/stereotypesmodel.h 
new/umbrello-15.08.2/umbrello/stereotypesmodel.h
--- old/umbrello-15.08.1/umbrello/stereotypesmodel.h    1970-01-01 
01:00:00.000000000 +0100
+++ new/umbrello-15.08.2/umbrello/stereotypesmodel.h    2015-10-09 
02:00:55.000000000 +0200
@@ -0,0 +1,47 @@
+/***************************************************************************
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) any later version.                                   *
+ *                                                                         *
+ *   copyright (C) 2015                                                    *
+ *   Umbrello UML Modeller Authors <[email protected]>                *
+ ***************************************************************************/
+
+#ifndef STEREOTYPESMODEL_H
+#define STEREOTYPESMODEL_H
+
+// app includes
+#include "umlstereotypelist.h"
+
+// qt includes
+#include <QAbstractTableModel>
+
+class UMLStereotype;
+
+Q_DECLARE_METATYPE(UMLStereotype*);
+
+class StereotypesModel : public QAbstractTableModel
+{
+    Q_OBJECT
+public:
+    StereotypesModel(UMLStereotypeList *stereotypes);
+
+    int rowCount(const QModelIndex &parent) const;
+    int columnCount(const QModelIndex &parent) const;
+
+    QVariant headerData(int section, Qt::Orientation orientation, int role = 
Qt::DisplayRole) const;
+    QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const;
+
+    bool addStereotype(UMLStereotype *stereotype);
+    bool removeStereotype(UMLStereotype *stereotype);
+
+    void emitDataChanged(const QModelIndex &index);
+    void emitDataChanged(int index);
+
+protected:
+    int m_count;
+    UMLStereotypeList *m_stereotypes;
+};
+
+#endif // STEREOTYPESMODEL_H
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/stereotypeswindow.cpp 
new/umbrello-15.08.2/umbrello/stereotypeswindow.cpp
--- old/umbrello-15.08.1/umbrello/stereotypeswindow.cpp 1970-01-01 
01:00:00.000000000 +0100
+++ new/umbrello-15.08.2/umbrello/stereotypeswindow.cpp 2015-10-09 
02:00:55.000000000 +0200
@@ -0,0 +1,75 @@
+/***************************************************************************
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) any later version.                                   *
+ *                                                                         *
+ *   copyright (C) 2015                                                    *
+ *   Umbrello UML Modeller Authors <[email protected]>                *
+ ***************************************************************************/
+
+#include "stereotypeswindow.h"
+
+// app includes
+#include "stereotype.h"
+#include "stereotypesmodel.h"
+#include "uml.h"
+#include "umldoc.h"
+
+// kde includes
+#include <KLocalizedString>
+
+// qt includes
+#include <QHeaderView>
+#include <QTableView>
+#include <QSortFilterProxyModel>
+#include <QtDebug>
+
+// TODO: remove in 2.18
+#define I18N(a) QLatin1String(a)
+
+StereotypesWindow::StereotypesWindow(QWidget *parent)
+    : QDockWidget(I18N("&Stereotypes"), parent)
+{
+    setObjectName(QLatin1String("StereotypesWindow"));
+
+    QSortFilterProxyModel *proxy = new QSortFilterProxyModel;
+    proxy->setSourceModel(UMLApp::app()->document()->stereotypesModel());
+    proxy->setSortCaseSensitivity(Qt::CaseInsensitive);
+    m_stereotypesTree = new QTableView;
+    m_stereotypesTree->setModel(proxy);
+    m_stereotypesTree->setSortingEnabled(true);
+    m_stereotypesTree->verticalHeader()->setDefaultSectionSize(20);
+    m_stereotypesTree->verticalHeader()->setVisible(false);
+#if QT_VERSION >= 0x050000
+    
m_stereotypesTree->horizontalHeader()->setSectionResizeMode(QHeaderView::Stretch);
+#else
+    m_stereotypesTree->horizontalHeader()->setResizeMode(QHeaderView::Stretch);
+#endif
+    setWidget(m_stereotypesTree);
+
+    connect(m_stereotypesTree, SIGNAL(doubleClicked(QModelIndex)), this, 
SLOT(slotStereotypesDoubleClicked(QModelIndex)));
+}
+
+StereotypesWindow::~StereotypesWindow()
+{
+    delete m_stereotypesTree;
+}
+
+void StereotypesWindow::modified()
+{
+    UMLStereotype *o = static_cast<UMLStereotype*>(QObject::sender());
+    if (!o)
+        return;
+    int index = UMLApp::app()->document()->stereotypes().indexOf(o);
+    UMLApp::app()->document()->stereotypesModel()->emitDataChanged(index);
+}
+
+void StereotypesWindow::slotStereotypesDoubleClicked(QModelIndex index)
+{
+    QVariant v = UMLApp::app()->document()->stereotypesModel()->data(index, 
Qt::UserRole);
+    if (v.canConvert<UMLStereotype*>()) {
+        UMLStereotype *s = v.value<UMLStereotype*>();
+        s->showPropertiesDialog(this);
+    }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/stereotypeswindow.h 
new/umbrello-15.08.2/umbrello/stereotypeswindow.h
--- old/umbrello-15.08.1/umbrello/stereotypeswindow.h   1970-01-01 
01:00:00.000000000 +0100
+++ new/umbrello-15.08.2/umbrello/stereotypeswindow.h   2015-10-09 
02:00:55.000000000 +0200
@@ -0,0 +1,38 @@
+/***************************************************************************
+ *   This program is free software; you can redistribute it and/or modify  *
+ *   it under the terms of the GNU General Public License as published by  *
+ *   the Free Software Foundation; either version 2 of the License, or     *
+ *   (at your option) any later version.                                   *
+ *                                                                         *
+ *   copyright (C) 2015                                                    *
+ *   Umbrello UML Modeller Authors <[email protected]>                *
+ ***************************************************************************/
+
+#ifndef STEREOTYPESWINDOW_H
+#define STEREOTYPESWINDOW_H
+
+#include <QDockWidget>
+#include <QModelIndex>
+
+class QTableView;
+
+class StereotypesWindow : public QDockWidget
+{
+    Q_OBJECT
+public:
+    explicit StereotypesWindow(QWidget *parent = 0);
+    ~StereotypesWindow();
+
+signals:
+
+public slots:
+    void modified();
+
+protected slots:
+    void slotStereotypesDoubleClicked(QModelIndex index);
+
+protected:
+    QTableView *m_stereotypesTree;
+};
+
+#endif // STEREOTYPESWINDOW_H
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umbrelloui.rc 
new/umbrello-15.08.2/umbrello/umbrelloui.rc
--- old/umbrello-15.08.1/umbrello/umbrelloui.rc 2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/umbrelloui.rc 2015-10-09 02:00:55.000000000 
+0200
@@ -85,6 +85,7 @@
     <Action name="view_show_doc"/>
     <Action name="view_show_undo"/>
     <Action name="view_show_bird"/>
+    <Action name="view_show_stereotypes"/>
   </Menu>
 </MenuBar>
 <ToolBar name="mainToolBar" fullWidth="true" newline="true">
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/uml.cpp 
new/umbrello-15.08.2/umbrello/uml.cpp
--- old/umbrello-15.08.1/umbrello/uml.cpp       2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/uml.cpp       2015-10-09 02:00:55.000000000 
+0200
@@ -240,15 +240,15 @@
     delete m_clipTimer;
     delete m_copyTimer;
     delete m_commoncodegenpolicy;
-    delete m_d;
-    delete m_doc;
     delete m_imageExporterAll;
-    delete m_listView;
     delete m_printer;
     delete m_policyext;
     delete m_pUndoStack;
     delete m_refactoringAssist;
     delete m_xhtmlGenerator;
+    delete m_listView;
+    delete m_doc;
+    delete m_d;
 }
 
 /**
@@ -918,6 +918,8 @@
     widget->setLayout(m_layout);
     setCentralWidget(widget);
 
+    m_d->createStereotypesWindow();
+
     // create the tree viewer
     m_listDock = new QDockWidget(i18n("&Tree View"), this);
     m_listDock->setObjectName(QLatin1String("TreeViewDock"));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umlappprivate.h 
new/umbrello-15.08.2/umbrello/umlappprivate.h
--- old/umbrello-15.08.1/umbrello/umlappprivate.h       2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/umlappprivate.h       2015-10-09 
02:00:55.000000000 +0200
@@ -15,8 +15,11 @@
 #include "finddialog.h"
 #include "findresults.h"
 #include "uml.h"
+#include "stereotypeswindow.h"
 
 // kde includes
+#include <KActionCollection>
+#include <KToggleAction>
 #include <ktexteditor/configinterface.h>
 #include <ktexteditor/document.h>
 #include <ktexteditor/editor.h>
@@ -43,16 +46,18 @@
 {
     Q_OBJECT
 public:
-    QWidget *parent;
+    UMLApp *parent;
     FindDialog findDialog;
     FindResults findResults;
     QListWidget *logWindow;         ///< Logging window.
+    KToggleAction *viewStereotypesWindow;
+    StereotypesWindow *stereotypesWindow;
 
     KTextEditor::Editor *editor;
     KTextEditor::View *view;
     KTextEditor::Document *document;
 
-    explicit UMLAppPrivate(QWidget *_parent)
+    explicit UMLAppPrivate(UMLApp *_parent)
       : parent(_parent),
         findDialog(_parent),
         view(0),
@@ -101,6 +106,19 @@
         delete dialog;
         delete document;
     }
+
+    void createStereotypesWindow()
+    {
+        // create the tree viewer
+        stereotypesWindow = new StereotypesWindow(parent);
+        parent->addDockWidget(Qt::LeftDockWidgetArea, stereotypesWindow);
+
+        viewStereotypesWindow = 
parent->actionCollection()->add<KToggleAction>(QLatin1String("view_stereotypes_window"));
+        // TODO: wrap with i18n in 2.18
+        viewStereotypesWindow->setText(QLatin1String("Stereotypes"));
+        connect(viewStereotypesWindow, SIGNAL(triggered(bool)), 
stereotypesWindow, SLOT(setVisible(bool)));
+    }
+
 };
 
 #endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umldoc.cpp 
new/umbrello-15.08.2/umbrello/umldoc.cpp
--- old/umbrello-15.08.1/umbrello/umldoc.cpp    2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/umldoc.cpp    2015-10-09 02:00:55.000000000 
+0200
@@ -44,6 +44,7 @@
 #include "umlscene.h"
 #include "version.h"
 #include "worktoolbar.h"
+#include "stereotypesmodel.h"
 
 // kde includes
 #include <kio/job.h>
@@ -113,7 +114,8 @@
     m_nViewID(Uml::ID::None),
     m_bTypesAreResolved(true),
     m_pCurrentRoot(0),
-    m_bClosing(false)
+    m_bClosing(false),
+    m_stereotypesModel(new StereotypesModel(&m_stereoList))
 {
     for (int i = 0; i < Uml::ModelType::N_MODELTYPES; ++i)
         m_root[i] = 0;
@@ -190,6 +192,7 @@
     }
     delete m_pChangeLog;
     qDeleteAll(m_stereoList);
+    delete m_stereotypesModel;
 }
 
 /**
@@ -402,18 +405,19 @@
         // @fixme With advanced code generation enabled, this crashes.
         removeAllObjects();
 
+        // Remove any stereotypes.
+        if (stereotypes().count() > 0) {
+            foreach(UMLStereotype *s, stereotypes()) {
+                m_stereotypesModel->removeStereotype(s);
+                delete s;
+            }
+            m_stereoList.clear();
+        }
+
         // Restore the datatype folder, it has been deleted above.
         createDatatypeFolder();
         // this creates to much items only Logical View should be created
         listView->init();
-        /* Remove any stereotypes.
-        if (m_stereoList.count() > 0) {
-            UMLStereotype *s;
-            for (UMLStereotypeListIt sit(m_stereoList); (s = sit.current()) != 
0; ++sit)
-                delete s;
-            m_stereoList.clear();
-        }
-        */
     }
     m_bClosing = false;
 }
@@ -1268,9 +1272,8 @@
  */
 void UMLDoc::addStereotype(UMLStereotype *s)
 {
-    if (! m_stereoList.contains(s)) {
-        m_stereoList.append(s);
-    }
+    if (m_stereotypesModel->addStereotype(s))
+        emit sigObjectCreated(s);
 }
 
 /**
@@ -1279,9 +1282,8 @@
  */
 void UMLDoc::removeStereotype(UMLStereotype *s)
 {
-    if (m_stereoList.contains(s)) {
-        m_stereoList.removeAll(s);
-    }
+    if (m_stereotypesModel->removeStereotype(s))
+        emit sigObjectRemoved(s);
 }
 
 /**
@@ -2444,6 +2446,11 @@
     qApp->processEvents();  // give UI events a chance
 }
 
+StereotypesModel *UMLDoc::stereotypesModel()
+{
+    return m_stereotypesModel;
+}
+
 /**
  * Ensures the XMI file is a valid UML file.
  * Currently only checks for metamodel=UML.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umldoc.h 
new/umbrello-15.08.2/umbrello/umldoc.h
--- old/umbrello-15.08.1/umbrello/umldoc.h      2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/umldoc.h      2015-10-09 02:00:55.000000000 
+0200
@@ -48,6 +48,7 @@
 class QPrinter;
 
 class IDChangeLog;
+class StereotypesModel;
 class UMLPackage;
 class UMLFolder;
 class DiagramPrintPage;
@@ -233,6 +234,8 @@
 
     void resolveTypes();
 
+    StereotypesModel *stereotypesModel();
+
 private:
     void initSaveTimer();
     void createDatatypeFolder();
@@ -308,6 +311,8 @@
      */
     bool m_bClosing;
 
+    StereotypesModel *m_stereotypesModel;
+
 public slots:
     void slotRemoveUMLObject(UMLObject*o);
     void slotAutoSave();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umllistview.cpp 
new/umbrello-15.08.2/umbrello/umllistview.cpp
--- old/umbrello-15.08.1/umbrello/umllistview.cpp       2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/umllistview.cpp       2015-10-09 
02:00:55.000000000 +0200
@@ -2161,6 +2161,11 @@
         QString name = classifier->uniqChildName(objectType);
         UMLObject* object = Object_Factory::createChildObject(classifier, 
objectType, name);
 
+        if (object == 0) {
+            // creation was cancelled by the user
+            return;
+        }
+
         // Handle primary key constraints (mark the unique constraint as PK on
         // the parent entity)
         if (type == UMLListViewItem::lvt_PrimaryKeyConstraint) {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umlobject.cpp 
new/umbrello-15.08.2/umbrello/umlobject.cpp
--- old/umbrello-15.08.1/umbrello/umlobject.cpp 2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/umlobject.cpp 2015-10-09 02:00:55.000000000 
+0200
@@ -99,6 +99,13 @@
  */
 UMLObject::~UMLObject()
 {
+    // unref stereotype
+    setUMLStereotype(0);
+    if (m_pSecondary && m_pSecondary->baseType() == ot_Stereotype) {
+        UMLStereotype* stereotype = 
dynamic_cast<UMLStereotype*>(m_pSecondary.data());
+        if (stereotype)
+            stereotype->decrRefCount();
+    }
 }
 
 /**
@@ -297,6 +304,8 @@
     // Data members with copy constructor
     lhs->m_Doc = m_Doc;
     lhs->m_pStereotype = m_pStereotype;
+    if (lhs->m_pStereotype)
+        lhs->m_pStereotype->incrRefCount();
     lhs->m_bAbstract = m_bAbstract;
     lhs->m_bStatic = m_bStatic;
     lhs->m_BaseType = m_BaseType;
@@ -703,6 +712,8 @@
         m_pSecondary = 
pDoc->findObjectById(Uml::ID::fromString(m_SecondaryId));
         if (m_pSecondary != NULL) {
             if (m_pSecondary->baseType() == ot_Stereotype) {
+                if (m_pStereotype)
+                    m_pStereotype->decrRefCount();
                 m_pStereotype = 
dynamic_cast<UMLStereotype*>(m_pSecondary.data());
                 m_pStereotype->incrRefCount();
                 m_pSecondary = NULL;
@@ -881,6 +892,8 @@
         return false;
     Uml::ID::Type stereoID = Uml::ID::fromString(stereo);
     UMLDoc *pDoc = UMLApp::app()->document();
+    if (m_pStereotype)
+        m_pStereotype->decrRefCount();
     m_pStereotype = pDoc->findStereotypeById(stereoID);
     if (m_pStereotype)
         m_pStereotype->incrRefCount();
@@ -972,6 +985,8 @@
     QString stereo = element.attribute(QLatin1String("stereotype"));
     if (!stereo.isEmpty()) {
         Uml::ID::Type stereoID = Uml::ID::fromString(stereo);
+        if (m_pStereotype)
+            m_pStereotype->decrRefCount();
         m_pStereotype = umldoc->findStereotypeById(stereoID);
         if (m_pStereotype) {
             m_pStereotype->incrRefCount();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/umlobject.h 
new/umbrello-15.08.2/umbrello/umlobject.h
--- old/umbrello-15.08.1/umbrello/umlobject.h   2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/umbrello/umlobject.h   2015-10-09 02:00:55.000000000 
+0200
@@ -172,7 +172,7 @@
     Uml::ID::Type          m_nId;          ///< object's id
     QString                m_Doc;          ///< object's documentation
     UMLPackage*            m_pUMLPackage;  ///< package the object belongs to 
if applicable
-    UMLStereotype*         m_pStereotype;  ///< stereotype of the object if 
applicable
+    QPointer<UMLStereotype> m_pStereotype;  ///< stereotype of the object if 
applicable
     QString                m_name;         ///< objects name
     ObjectType             m_BaseType;     ///< objects type
     Uml::Visibility::Enum  m_visibility;   ///< objects visibility
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/umbrello-15.08.1/umbrello/widgets/associationwidget.cpp 
new/umbrello-15.08.2/umbrello/widgets/associationwidget.cpp
--- old/umbrello-15.08.1/umbrello/widgets/associationwidget.cpp 2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/widgets/associationwidget.cpp 2015-10-09 
02:00:55.000000000 +0200
@@ -3082,7 +3082,7 @@
         if (newText != oldText) {
             if (FloatingTextWidget::isTextValid(newText)) {
                 setName(newText);
-            } else {
+            } else if (m_nameWidget) {
                 m_scene->removeWidget(m_nameWidget);
                 m_nameWidget = NULL;
             }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/umbrello-15.08.1/umbrello/widgets/classifierwidget.cpp 
new/umbrello-15.08.2/umbrello/widgets/classifierwidget.cpp
--- old/umbrello-15.08.1/umbrello/widgets/classifierwidget.cpp  2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/widgets/classifierwidget.cpp  2015-10-09 
02:00:55.000000000 +0200
@@ -1293,7 +1293,13 @@
 {
     QDomElement conceptElement;
     UMLClassifier *umlc = classifier();
-    if (umlc && umlc->isInterface())
+    if (umlObject() && umlObject()->baseType() == UMLObject::ot_Package) {
+        conceptElement = qDoc.createElement(QLatin1String("packagewidget"));
+        UMLWidget::saveToXMI(qDoc, conceptElement);
+        qElement.appendChild(conceptElement);
+        return;
+    }
+    else if (umlc && umlc->isInterface())
         conceptElement = qDoc.createElement(QLatin1String("interfacewidget"));
     else
         conceptElement = qDoc.createElement(QLatin1String("classwidget"));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/umbrello/widgets/widget_factory.cpp 
new/umbrello-15.08.2/umbrello/widgets/widget_factory.cpp
--- old/umbrello-15.08.1/umbrello/widgets/widget_factory.cpp    2015-09-10 
00:54:59.000000000 +0200
+++ new/umbrello-15.08.2/umbrello/widgets/widget_factory.cpp    2015-10-09 
02:00:55.000000000 +0200
@@ -86,6 +86,8 @@
         newWidget = new UseCaseWidget(scene, static_cast<UMLUseCase*>(o));
         break;
     case UMLObject::ot_Folder:
+        newWidget = new PackageWidget(scene, static_cast<UMLPackage*>(o));
+        break;
     case UMLObject::ot_Package:
         newWidget = new ClassifierWidget(scene, static_cast<UMLPackage*>(o));
         break;
@@ -251,7 +253,7 @@
                 widget = new UseCaseWidget(scene, static_cast<UMLUseCase*>(o));
         } else if (tag == QLatin1String("classwidget") ||
                    tag == QLatin1String("UML:ClassWidget") || tag == 
QLatin1String("UML:ConceptWidget")) {
-            if (validateObjType(UMLObject::ot_Class, o, id))
+            if (validateObjType(UMLObject::ot_Class, o, id) || 
validateObjType(UMLObject::ot_Package, o, id))
                 widget = new ClassifierWidget(scene, 
static_cast<UMLClassifier*>(o));
         } else if (tag == QLatin1String("packagewidget")) {
             if (validateObjType(UMLObject::ot_Package, o, id))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/umbrello-15.08.1/unittests/testbase.cpp 
new/umbrello-15.08.2/unittests/testbase.cpp
--- old/umbrello-15.08.1/unittests/testbase.cpp 2015-09-10 00:54:59.000000000 
+0200
+++ new/umbrello-15.08.2/unittests/testbase.cpp 2015-10-09 02:00:55.000000000 
+0200
@@ -39,8 +39,6 @@
 #include <QTemporaryDir>
 #endif
 
-static UMLApp *umlApp = 0;
-
 TestBase::TestBase(QObject *parent)
   : QObject(parent)
 {
@@ -49,12 +47,12 @@
 void TestBase::initTestCase()
 {
     QWidget *w = new QWidget;
-    umlApp = new UMLApp(w);
+    new UMLApp(w);
 }
 
 void TestBase::cleanupTestCase()
 {
-    delete umlApp;
+    delete UMLApp::app();
 }
 
 void TestCodeGeneratorBase::initTestCase()


Reply via email to