Explorar o código

command should be updatable (#28616)

ycw hai 1 ano
pai
achega
846825ad0a
Modificáronse 1 ficheiros con 7 adicións e 0 borrados
  1. 7 0
      editor/js/commands/SetShadowValueCommand.js

+ 7 - 0
editor/js/commands/SetShadowValueCommand.js

@@ -15,6 +15,7 @@ class SetShadowValueCommand extends Command {
 
 
 		this.type = 'SetShadowValueCommand';
 		this.type = 'SetShadowValueCommand';
 		this.name = editor.strings.getKey( 'command/SetShadowValue' ) + ': ' + attributeName;
 		this.name = editor.strings.getKey( 'command/SetShadowValue' ) + ': ' + attributeName;
+		this.updatable = true;
 
 
 		this.object = object;
 		this.object = object;
 		this.attributeName = attributeName;
 		this.attributeName = attributeName;
@@ -37,6 +38,12 @@ class SetShadowValueCommand extends Command {
 
 
 	}
 	}
 
 
+	update( cmd ) {
+
+		this.newValue = cmd.newValue;
+
+	}
+
 	toJSON() {
 	toJSON() {
 
 
 		const output = super.toJSON( this );
 		const output = super.toJSON( this );