Explorar el Código

Editor: Empty project title on clear.

Mr.doob hace 4 años
padre
commit
e07eca4c0b
Se han modificado 1 ficheros con 10 adiciones y 0 borrados
  1. 10 0
      editor/js/Sidebar.Project.js

+ 10 - 0
editor/js/Sidebar.Project.js

@@ -7,6 +7,7 @@ import { SidebarProjectVideo } from './Sidebar.Project.Video.js';
 function SidebarProject( editor ) {
 
 	var config = editor.config;
+	var signals = editor.signals;
 	var strings = editor.strings;
 
 	var container = new UISpan();
@@ -69,6 +70,15 @@ function SidebarProject( editor ) {
 
 	}
 
+	// Signals
+
+	signals.editorCleared.add( function () {
+
+		title.setValue( '' );
+		config.setKey( 'project/title', '' );
+
+	} );
+
 	return container;
 
 }