fix initial dimensions of read-only input slots

pull/95/head
jmoenig 2020-04-05 11:13:53 +02:00
rodzic 2729580a9f
commit 1a43d50ebf
1 zmienionych plików z 4 dodań i 1 usunięć

Wyświetl plik

@ -148,7 +148,7 @@ CustomCommandBlockMorph, SymbolMorph, ToggleButtonMorph, DialMorph*/
// Global stuff ////////////////////////////////////////////////////////
modules.blocks = '2020-April-04';
modules.blocks = '2020-April-05';
var SyntaxElementMorph;
var BlockMorph;
@ -8710,6 +8710,9 @@ InputSlotMorph.prototype.setContents = function (data) {
} else if (dta.toString) {
cnts.text = dta.toString();
}
if (this.isReadOnly) {
cnts.shadowOffset = new Point(1, 1); // correct initial dimensions
}
cnts.fixLayout();
// remember the constant, if any