Remove extra hiddenText assignment in clipboards

dev
Michael Ball 2015-12-17 00:41:23 -08:00
rodzic abe5f3fe1d
commit 1f9e923d04
1 zmienionych plików z 5 dodań i 6 usunięć

Wyświetl plik

@ -4496,19 +4496,18 @@ CursorMorph.prototype.init = function (aStringOrTextMorph) {
this.target.setAlignmentToLeft();
}
this.gotoSlot(this.slot);
// Add hidden text box for copying and pasting
this.hiddenText = document.createElement('textarea');
this.target.hiddenText = this.hiddenText;
this.hiddenText.style.position = 'absolute';
this.hiddenText.style.right = '101%'; // placed just out of view
document.body.appendChild(this.hiddenText);
this.hiddenText.value = this.target.selection();
this.hiddenText.focus();
this.hiddenText.select();
this.hiddenText.addEventListener(
'keypress',
function (event) {
@ -4518,7 +4517,7 @@ CursorMorph.prototype.init = function (aStringOrTextMorph) {
},
false
);
this.hiddenText.addEventListener(
'keydown',
function (event) {