Fixing bugs related to property changes in history with enum, object & list properties
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
7a25ba2f7a
commit
0e2c1bdae4
9 changed files with 69 additions and 46 deletions
|
@ -569,27 +569,27 @@ Diese Einstellungen können jederzeit über das Menü "Einstellungen"
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation>Neu %1 %2 erstellt.</translation>
|
<translation>Neu %1 %2 erstellt.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation>%1 %2 gelöscht.</translation>
|
<translation>%1 %2 gelöscht.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation>%1 von %2 %3 wurde von "%4" auf "%5" geändert.</translation>
|
<translation>%1 von %2 %3 wurde von "%4" auf "%5" geändert.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation>%1 %2 angezeigt.</translation>
|
<translation>%1 %2 angezeigt.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation>%1 %2 ausgeblendet.</translation>
|
<translation>%1 %2 ausgeblendet.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -569,27 +569,27 @@ These settings can be changed at any time from the "Settings" menu.</t
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation>New %1 %2 created.</translation>
|
<translation>New %1 %2 created.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation>%1 %2 deleted.</translation>
|
<translation>%1 %2 deleted.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation>%1 of %2 %3 changed from "%4" to "%5".</translation>
|
<translation>%1 of %2 %3 changed from "%4" to "%5".</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation>%1 %2 shown.</translation>
|
<translation>%1 %2 shown.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation>%1 %2 hidden.</translation>
|
<translation>%1 %2 hidden.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -568,27 +568,27 @@ These settings can be changed at any time from the "Settings" menu.</s
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -578,27 +578,27 @@ These settings can always be changed at any time from the "Settings" m
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation>Nouveau %1 %2 créé(e).</translation>
|
<translation>Nouvel objet %1 %2 créé.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation>%1 %2 supprimé(e).</translation>
|
<translation>%1 %2 supprimé(e).</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation>%1 de %2 %3 modifiée de "%4" à "%5".</translation>
|
<translation>%1 de %2 %3 modifiée de "%4" à "%5".</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation>%1 %2 affiché(e).</translation>
|
<translation>%1 %2 affiché(e).</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation>%1 %2 cachée(e).</translation>
|
<translation>%1 %2 cachée(e).</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -569,27 +569,27 @@ Ezek a beállítások bármikor módosíthatók a „Beállítások” menüben.
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation>Új %1 %2 létrehozva.</translation>
|
<translation>Új %1 %2 létrehozva.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation>%1 %2 törölve.</translation>
|
<translation>%1 %2 törölve.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation>%1/%2 %3 megváltozott. Régi érték: %4, új érték: %5.</translation>
|
<translation>%1/%2 %3 megváltozott. Régi érték: %4, új érték: %5.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation>%1 %2 megjelenítve.</translation>
|
<translation>%1 %2 megjelenítve.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation>%1 %2 rejtve.</translation>
|
<translation>%1 %2 rejtve.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -569,27 +569,27 @@ Disse innstillingene kan endres når som helst fra «Innstillinger»-menyen.</tr
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation>Ny %1 %2 opprettet.</translation>
|
<translation>Ny %1 %2 opprettet.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation>%1 %2 slettet.</translation>
|
<translation>%1 %2 slettet.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation>%1 av %2 %3 endret fra «%4» til «%5».</translation>
|
<translation>%1 av %2 %3 endret fra «%4» til «%5».</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation>%1 %2 vist.</translation>
|
<translation>%1 %2 vist.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation>%1 %2 skjult.</translation>
|
<translation>%1 %2 skjult.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -568,27 +568,27 @@ These settings can be changed at any time from the "Settings" menu.</s
|
||||||
<context>
|
<context>
|
||||||
<name>historylib</name>
|
<name>historylib</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="78"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="79"/>
|
||||||
<source>New %1 %2 created.</source>
|
<source>New %1 %2 created.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="95"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="96"/>
|
||||||
<source>%1 %2 deleted.</source>
|
<source>%1 %2 deleted.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="149"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="172"/>
|
||||||
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
<source>%1 of %2 %3 changed from "%4" to "%5".</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="166"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="189"/>
|
||||||
<source>%1 %2 shown.</source>
|
<source>%1 %2 shown.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="168"/>
|
<location filename="../qml/eu/ad5001/LogarithmPlotter/js/historylib.js" line="191"/>
|
||||||
<source>%1 %2 hidden.</source>
|
<source>%1 %2 hidden.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -33,7 +33,7 @@ D.Dialog {
|
||||||
property var obj: Objects.currentObjects[objType][objIndex]
|
property var obj: Objects.currentObjects[objType][objIndex]
|
||||||
property QtObject editingRow: QtObject{}
|
property QtObject editingRow: QtObject{}
|
||||||
property var objectLists
|
property var objectLists
|
||||||
title: `LogarithmPlotter`
|
title: "LogarithmPlotter"
|
||||||
width: 350
|
width: 350
|
||||||
height: 400
|
height: 400
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,7 @@
|
||||||
.pragma library
|
.pragma library
|
||||||
|
|
||||||
.import "objects.js" as Objects
|
.import "objects.js" as Objects
|
||||||
|
.import "parameters.js" as P
|
||||||
.import "objs/common.js" as Common
|
.import "objs/common.js" as Common
|
||||||
.import "utils.js" as Utils
|
.import "utils.js" as Utils
|
||||||
.import "mathlib.js" as MathLib
|
.import "mathlib.js" as MathLib
|
||||||
|
@ -103,14 +104,15 @@ class EditedProperty extends Action {
|
||||||
constructor(targetName = "", targetType = "Point", targetProperty = "visible", previousValue = false, newValue = true, valueIsExpressionNeedingImport = false) {
|
constructor(targetName = "", targetType = "Point", targetProperty = "visible", previousValue = false, newValue = true, valueIsExpressionNeedingImport = false) {
|
||||||
super(targetName, targetType)
|
super(targetName, targetType)
|
||||||
this.targetProperty = targetProperty
|
this.targetProperty = targetProperty
|
||||||
this.targetPropertyReadable = Utils.camelCase2readable(this.targetProperty)
|
this.targetPropertyReadable = qsTranslate("prop", this.targetProperty)
|
||||||
this.previousValue = previousValue
|
this.previousValue = previousValue
|
||||||
this.newValue = newValue
|
this.newValue = newValue
|
||||||
|
this.propertyType = Objects.types[targetType].properties()[targetProperty]
|
||||||
if(valueIsExpressionNeedingImport) {
|
if(valueIsExpressionNeedingImport) {
|
||||||
if(targetType == "Expression") {
|
if(propertyType == "Expression") {
|
||||||
this.previousValue = new MathLib.Expression(this.previousValue);
|
this.previousValue = new MathLib.Expression(this.previousValue);
|
||||||
this.newValue = new MathLib.Expression(this.newValue);
|
this.newValue = new MathLib.Expression(this.newValue);
|
||||||
} else if(targetType == "Domain") {
|
} else if(propertyType == "Domain") {
|
||||||
this.previousValue = MathLib.parseDomain(this.previousValue);
|
this.previousValue = MathLib.parseDomain(this.previousValue);
|
||||||
this.newValue = MathLib.parseDomain(this.newValue);
|
this.newValue = MathLib.parseDomain(this.newValue);
|
||||||
} else {
|
} else {
|
||||||
|
@ -140,12 +142,33 @@ class EditedProperty extends Action {
|
||||||
}
|
}
|
||||||
|
|
||||||
getReadableString() {
|
getReadableString() {
|
||||||
var prev = this.previousValue == null ? "null" : this.previousValue.toString()
|
let prev = "";
|
||||||
var next = this.newValue == null ? "null" : this.newValue.toString()
|
let next = "";
|
||||||
if(prev == "[object Object]") // Oh no!
|
if(this.propertyType instanceof Object) {
|
||||||
|
console.log(this.propertyType.type)
|
||||||
|
switch(this.propertyType.type) {
|
||||||
|
case "Enum":
|
||||||
|
console.log(this.propertyType.translatedValues, this.previousValue, this.propertyType.values.indexOf(this.previousValue))
|
||||||
|
prev = this.propertyType.translatedValues[this.propertyType.values.indexOf(this.previousValue)]
|
||||||
|
next = this.propertyType.translatedValues[this.propertyType.values.indexOf(this.newValue)]
|
||||||
|
break;
|
||||||
|
case "ObjectType":
|
||||||
|
prev = this.previousValue.name
|
||||||
|
next = this.newValue.name
|
||||||
|
break;
|
||||||
|
case "List":
|
||||||
|
prev = this.previousValue.join(",")
|
||||||
|
next = this.newValue.name.join(",")
|
||||||
|
break;
|
||||||
|
case "Dict":
|
||||||
prev = JSON.stringify(this.previousValue).replace("'", "\\'").replace('"', "'")
|
prev = JSON.stringify(this.previousValue).replace("'", "\\'").replace('"', "'")
|
||||||
if(next == "[object Object]") // Oh no!
|
next = JSON.stringify(this.newValue).replace("'", "\\'").replace('"', "'")
|
||||||
next = JSON.stringify(this.previousValue).replace("'", "\\'").replace('"', "'")
|
break;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
prev = this.previousValue == null ? "null" : this.previousValue.toString()
|
||||||
|
next = this.newValue == null ? "null" : this.newValue.toString()
|
||||||
|
}
|
||||||
return qsTr('%1 of %2 %3 changed from "%4" to "%5".')
|
return qsTr('%1 of %2 %3 changed from "%4" to "%5".')
|
||||||
.arg(this.targetPropertyReadable)
|
.arg(this.targetPropertyReadable)
|
||||||
.arg(Objects.types[this.targetType].displayType())
|
.arg(Objects.types[this.targetType].displayType())
|
||||||
|
|
Loading…
Reference in a new issue