mirror of
https://github.com/google/blockly.git
synced 2026-01-10 18:37:09 +01:00
Fix speling.
This commit is contained in:
@@ -341,7 +341,7 @@ Blockly.Block.prototype.bumpNeighbours_ = function() {
|
||||
if (rootBlock.isInFlyout) {
|
||||
return; // Don't move blocks around in a flyout.
|
||||
}
|
||||
// Loop though every connection on this block.
|
||||
// Loop through every connection on this block.
|
||||
var myConnections = this.getConnections_(false);
|
||||
for (var i = 0, connection; connection = myConnections[i]; i++) {
|
||||
// Spider down from this block bumping all sub-blocks.
|
||||
|
||||
@@ -554,7 +554,7 @@ Blockly.BlockSvg.prototype.renderDraw_ = function(iconWidth, inputRows) {
|
||||
*/
|
||||
Blockly.BlockSvg.prototype.renderMoveConnections_ = function() {
|
||||
var blockTL = this.getRelativeToSurfaceXY();
|
||||
// Don't tighten previous or output connecitons because they are inferior
|
||||
// Don't tighten previous or output connections because they are inferior
|
||||
// connections.
|
||||
if (this.previousConnection) {
|
||||
this.previousConnection.moveToOffset(blockTL);
|
||||
|
||||
@@ -1413,7 +1413,7 @@ Blockly.BlockSvg.prototype.setWarningText = function(text, opt_id) {
|
||||
}
|
||||
var id = opt_id || '';
|
||||
if (!id) {
|
||||
// Kill all previous pending processes, this edit supercedes them all.
|
||||
// Kill all previous pending processes, this edit supersedes them all.
|
||||
for (var n in this.setWarningText.pid_) {
|
||||
clearTimeout(this.setWarningText.pid_[n]);
|
||||
delete this.setWarningText.pid_[n];
|
||||
|
||||
@@ -78,7 +78,7 @@ Blockly.Comment.prototype.drawIcon_ = function(group) {
|
||||
{'class': 'blocklyIconSymbol',
|
||||
'd': 'm6.8,10h2c0.003,-0.617 0.271,-0.962 0.633,-1.266 2.875,-2.405 0.607,-5.534 -3.765,-3.874v1.7c3.12,-1.657 3.698,0.118 2.336,1.25 -1.201,0.998 -1.201,1.528 -1.204,2.19z'},
|
||||
group);
|
||||
// Dot of question point.
|
||||
// Dot of question mark.
|
||||
Blockly.utils.createSvgElement('rect',
|
||||
{'class': 'blocklyIconSymbol',
|
||||
'x': '6.8', 'y': '10.78', 'height': '2', 'width': '2'},
|
||||
|
||||
@@ -192,7 +192,7 @@ Blockly.FieldAngle.prototype.onMouseMove = function(e) {
|
||||
var dy = e.clientY - bBox.top - Blockly.FieldAngle.HALF;
|
||||
var angle = Math.atan(-dy / dx);
|
||||
if (isNaN(angle)) {
|
||||
// This shouldn't happen, but let's not let this error propogate further.
|
||||
// This shouldn't happen, but let's not let this error propagate further.
|
||||
return;
|
||||
}
|
||||
angle = goog.math.toDegrees(angle);
|
||||
|
||||
@@ -249,7 +249,7 @@ Blockly.Generator.prototype.valueToCode = function(block, name, outerOrder) {
|
||||
// In all known languages multiple such code blocks are not order
|
||||
// sensitive. In fact in Python ('a' 'b') 'c' would fail.
|
||||
} else {
|
||||
// The operators outside this code are stonger than the operators
|
||||
// The operators outside this code are stronger than the operators
|
||||
// inside this code. To prevent the code from being pulled apart,
|
||||
// wrap the code in parentheses.
|
||||
parensNeeded = true;
|
||||
|
||||
@@ -263,7 +263,7 @@ Blockly.init_ = function(mainWorkspace) {
|
||||
var options = mainWorkspace.options;
|
||||
var svg = mainWorkspace.getParentSvg();
|
||||
|
||||
// Supress the browser's context menu.
|
||||
// Suppress the browser's context menu.
|
||||
Blockly.bindEventWithChecks_(svg, 'contextmenu', null,
|
||||
function(e) {
|
||||
if (!Blockly.utils.isTargetInput(e)) {
|
||||
@@ -327,7 +327,7 @@ Blockly.inject.bindDocumentEvents_ = function() {
|
||||
Blockly.bindEventWithChecks_(document, 'touchcancel', null,
|
||||
Blockly.longStop_);
|
||||
// Don't use bindEvent_ for document's mouseup since that would create a
|
||||
// corresponding touch handler that would squeltch the ability to interact
|
||||
// corresponding touch handler that would squelch the ability to interact
|
||||
// with non-Blockly elements.
|
||||
document.addEventListener('mouseup', Blockly.onMouseUp_, false);
|
||||
// Some iPad versions don't fire resize after portrait to landscape change.
|
||||
|
||||
@@ -303,7 +303,7 @@ Blockly.Mutator.prototype.workspaceChanged_ = function() {
|
||||
block.compose(this.rootBlock_);
|
||||
// Restore rendering and show the changes.
|
||||
block.rendered = savedRendered;
|
||||
// Mutation may have added some elements that need initalizing.
|
||||
// Mutation may have added some elements that need initializing.
|
||||
block.initSvg();
|
||||
var newMutationDom = block.mutationToDom();
|
||||
var newMutation = newMutationDom && Blockly.Xml.domToText(newMutationDom);
|
||||
|
||||
@@ -330,7 +330,7 @@ Blockly.Toolbox.prototype.syncTrees_ = function(treeIn, treeOut, pathToMedia) {
|
||||
}
|
||||
if (childIn.getAttribute('expanded') == 'true') {
|
||||
if (childOut.blocks.length) {
|
||||
// This is a category that directly contians blocks.
|
||||
// This is a category that directly contains blocks.
|
||||
// After the tree is rendered, open this category and show flyout.
|
||||
openNode = childOut;
|
||||
}
|
||||
@@ -585,7 +585,7 @@ Blockly.Toolbox.TreeNode = function(toolbox, html, opt_config, opt_domHelper) {
|
||||
goog.inherits(Blockly.Toolbox.TreeNode, goog.ui.tree.TreeNode);
|
||||
|
||||
/**
|
||||
* Supress population of the +/- icon.
|
||||
* Suppress population of the +/- icon.
|
||||
* @return {!goog.html.SafeHtml} The source for the icon.
|
||||
* @override
|
||||
*/
|
||||
@@ -612,7 +612,7 @@ Blockly.Toolbox.TreeNode.prototype.onMouseDown = function(e) {
|
||||
};
|
||||
|
||||
/**
|
||||
* Supress the inherited double-click behaviour.
|
||||
* Suppress the inherited double-click behaviour.
|
||||
* @param {!goog.events.BrowserEvent} e The browser event.
|
||||
* @override
|
||||
* @private
|
||||
|
||||
@@ -160,7 +160,7 @@ Blockly.Tooltip.onMouseOver_ = function(e) {
|
||||
Blockly.Tooltip.poisonedElement_ = null;
|
||||
Blockly.Tooltip.element_ = element;
|
||||
}
|
||||
// Forget about any immediately preceeding mouseOut event.
|
||||
// Forget about any immediately preceding mouseOut event.
|
||||
clearTimeout(Blockly.Tooltip.mouseOutPid_);
|
||||
};
|
||||
|
||||
|
||||
@@ -1270,7 +1270,7 @@ Blockly.WorkspaceSvg.prototype.zoomToFit = function() {
|
||||
workspaceWidth -= this.flyout_.width_;
|
||||
}
|
||||
if (!this.scrollbar) {
|
||||
// Orgin point of 0,0 is fixed, blocks will not scroll to center.
|
||||
// Origin point of 0,0 is fixed, blocks will not scroll to center.
|
||||
blocksWidth += metrics.contentLeft;
|
||||
blocksHeight += metrics.contentTop;
|
||||
}
|
||||
|
||||
@@ -362,7 +362,7 @@ Blockly.Xml.domToBlock = function(xmlBlock, workspace) {
|
||||
for (var i = blocks.length - 1; i >= 0; i--) {
|
||||
blocks[i].render(false);
|
||||
}
|
||||
// Populating the connection database may be defered until after the
|
||||
// Populating the connection database may be deferred until after the
|
||||
// blocks have rendered.
|
||||
setTimeout(function() {
|
||||
if (topBlock.workspace) { // Check that the block hasn't been deleted.
|
||||
@@ -432,7 +432,7 @@ Blockly.Xml.domToBlockHeadless_ = function(xmlBlock, workspace) {
|
||||
if (block.domToMutation) {
|
||||
block.domToMutation(xmlChild);
|
||||
if (block.initSvg) {
|
||||
// Mutation may have added some elements that need initalizing.
|
||||
// Mutation may have added some elements that need initializing.
|
||||
block.initSvg();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user