mirror of
https://github.com/google/blockly.git
synced 2026-01-04 15:40:08 +01:00
Improve rendering of flyouts with many blocks
This commit is contained in:
@@ -758,6 +758,7 @@ Blockly.Flyout.prototype.show = function(xmlList) {
|
||||
}
|
||||
|
||||
this.setVisible(true);
|
||||
this.workspace_.rendered = false;
|
||||
// Create the blocks to be shown in this flyout.
|
||||
var contents = [];
|
||||
var gaps = [];
|
||||
@@ -800,6 +801,12 @@ Blockly.Flyout.prototype.show = function(xmlList) {
|
||||
}
|
||||
}
|
||||
}
|
||||
this.workspace_.rendered = true;
|
||||
var blocks = goog.object.getValues(this.workspace_.blockDB_);
|
||||
for (var i = 0; i < blocks.length; i++) {
|
||||
blocks[i].initSvg();
|
||||
}
|
||||
this.workspace_.render();
|
||||
|
||||
this.layout_(contents, gaps);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user