mirror of
https://github.com/google/blockly.git
synced 2026-01-07 17:10:11 +01:00
Update getScaledBBox_ to return new object to fix issue in IE.
This commit is contained in:
@@ -231,9 +231,9 @@ Blockly.Field.prototype.getSize = function() {
|
||||
*/
|
||||
Blockly.Field.prototype.getScaledBBox_ = function() {
|
||||
var bBox = this.borderRect_.getBBox();
|
||||
bBox.width *= this.sourceBlock_.workspace.scale;
|
||||
bBox.height *= this.sourceBlock_.workspace.scale;
|
||||
return bBox;
|
||||
// Create new object, as getBBox can return an uneditable SVGRect.
|
||||
return {width: bBox.width * this.sourceBlock_.workspace.scale,
|
||||
height: bBox.height * this.sourceBlock_.workspace.scale};
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user