Rename Blockly.eventHandling->Blockly.browserEvents and replace all Blockly.EventData annotations

This commit is contained in:
Rachel Fenichel
2021-02-22 13:23:19 -08:00
parent 2a3f5040e6
commit 54c4e8de39
17 changed files with 65 additions and 65 deletions

View File

@@ -17,7 +17,7 @@ goog.require('Blockly.blockRendering');
goog.require('Blockly.ConnectionDB');
goog.require('Blockly.constants');
goog.require('Blockly.ContextMenuRegistry');
goog.require('Blockly.eventHandling');
goog.require('Blockly.browserEvents');
goog.require('Blockly.Events');
goog.require('Blockly.Events.BlockCreate');
goog.require('Blockly.Events.ThemeChange');
@@ -223,7 +223,7 @@ Blockly.utils.object.inherits(Blockly.WorkspaceSvg, Blockly.Workspace);
/**
* A wrapper function called when a resize event occurs.
* You can pass the result to `eventHandling.unbind`.
* @type {?Blockly.eventHandling.Data}
* @type {?Blockly.browserEvents.Data}
* @private
*/
Blockly.WorkspaceSvg.prototype.resizeHandlerWrapper_ = null;
@@ -754,7 +754,7 @@ Blockly.WorkspaceSvg.prototype.getBlockCanvas = function() {
/**
* Save resize handler data so we can delete it later in dispose.
* @param {!Blockly.eventHandling.Data} handler Data that can be passed to
* @param {!Blockly.browserEvents.Data} handler Data that can be passed to
* eventHandling.unbind.
*/
Blockly.WorkspaceSvg.prototype.setResizeHandlerWrapper = function(handler) {
@@ -809,9 +809,9 @@ Blockly.WorkspaceSvg.prototype.createDom = function(opt_backgroundClass) {
{'class': 'blocklyBubbleCanvas'}, this.svgGroup_);
if (!this.isFlyout) {
Blockly.eventHandling.checkAndBind(
Blockly.browserEvents.checkAndBind(
this.svgGroup_, 'mousedown', this, this.onMouseDown_, false, true);
Blockly.eventHandling.checkAndBind(
Blockly.browserEvents.checkAndBind(
this.svgGroup_, 'wheel', this, this.onMouseWheel_);
}
@@ -919,7 +919,7 @@ Blockly.WorkspaceSvg.prototype.dispose = function() {
}
}
if (this.resizeHandlerWrapper_) {
Blockly.eventHandling.unbind(this.resizeHandlerWrapper_);
Blockly.browserEvents.unbind(this.resizeHandlerWrapper_);
this.resizeHandlerWrapper_ = null;
}
};