mirror of
https://github.com/google/blockly.git
synced 2026-01-10 18:37:09 +01:00
Make Blockly options an interface (#3312)
* Make workspace options an interface so it can be extended in the d.ts.
This commit is contained in:
@@ -178,7 +178,7 @@ Blockly.Toolbox.prototype.init = function() {
|
||||
}
|
||||
Blockly.Touch.clearTouchIdentifier(); // Don't block future drags.
|
||||
}, /* opt_noCaptureIdentifier */ false, /* opt_noPreventDefault */ true);
|
||||
var workspaceOptions = {
|
||||
var workspaceOptions = /** @type {!Blockly.Options} */ ({
|
||||
disabledPatternId: workspace.options.disabledPatternId,
|
||||
parentWorkspace: workspace,
|
||||
RTL: workspace.RTL,
|
||||
@@ -186,7 +186,7 @@ Blockly.Toolbox.prototype.init = function() {
|
||||
horizontalLayout: workspace.horizontalLayout,
|
||||
toolboxPosition: workspace.options.toolboxPosition,
|
||||
renderer: workspace.options.renderer
|
||||
};
|
||||
});
|
||||
if (workspace.horizontalLayout) {
|
||||
if (!Blockly.HorizontalFlyout) {
|
||||
throw Error('Missing require for Blockly.HorizontalFlyout');
|
||||
|
||||
Reference in New Issue
Block a user