Fix folder renaming. (fixes #196)

This commit is contained in:
Don McCurdy 2018-10-06 21:46:06 -07:00
parent 642af145fd
commit df80c663f8

View File

@ -177,6 +177,7 @@ const GUI = function(pars) {
localStorage.getItem(getLocalStorageHash(this, 'isLocal')) === 'true';
let saveToLocalStorage;
let titleRow;
Object.defineProperties(this,
/** @lends GUI.prototype */
@ -267,8 +268,8 @@ const GUI = function(pars) {
set: function(v) {
// TODO Check for collisions among sibling folders
params.name = v;
if (titleRowName) {
titleRowName.innerHTML = params.name;
if (titleRow) {
titleRow.innerHTML = params.name;
}
}
},
@ -376,7 +377,7 @@ const GUI = function(pars) {
const titleRowName = document.createTextNode(params.name);
dom.addClass(titleRowName, 'controller-name');
const titleRow = addRow(_this, titleRowName);
titleRow = addRow(_this, titleRowName);
const onClickTitle = function(e) {
e.preventDefault();