mirror of
https://github.com/google/blockly.git
synced 2026-01-07 09:00:11 +01:00
Reverse deprecated argument order to womtoblock in accessible.
This commit is contained in:
@@ -101,7 +101,7 @@ blocklyApp.BlockConnectionService = ng.core.Class({
|
|||||||
},
|
},
|
||||||
attachToMarkedConnection: function(block) {
|
attachToMarkedConnection: function(block) {
|
||||||
var xml = Blockly.Xml.blockToDom(block);
|
var xml = Blockly.Xml.blockToDom(block);
|
||||||
var reconstitutedBlock = Blockly.Xml.domToBlock(blocklyApp.workspace, xml);
|
var reconstitutedBlock = Blockly.Xml.domToBlock(xml, blocklyApp.workspace);
|
||||||
|
|
||||||
var targetConnection = null;
|
var targetConnection = null;
|
||||||
if (this.markedConnection_.targetBlock() &&
|
if (this.markedConnection_.targetBlock() &&
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ blocklyApp.FieldSegmentComponent = ng.core.Component({
|
|||||||
},
|
},
|
||||||
// Sets the value on a dropdown input.
|
// Sets the value on a dropdown input.
|
||||||
setDropdownValue: function(optionValue) {
|
setDropdownValue: function(optionValue) {
|
||||||
this.optionValue = optionValue
|
this.optionValue = optionValue;
|
||||||
if (this.optionValue == 'NO_ACTION') {
|
if (this.optionValue == 'NO_ACTION') {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,7 +26,7 @@
|
|||||||
}
|
}
|
||||||
.blocklySidebarButton[disabled] {
|
.blocklySidebarButton[disabled] {
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
opacity: 0.5;
|
opacity: .5;
|
||||||
}
|
}
|
||||||
|
|
||||||
.blocklyAriaLiveStatus {
|
.blocklyAriaLiveStatus {
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ blocklyApp.ToolboxModalService = ng.core.Class({
|
|||||||
this.allToolboxCategories = Array.from(toolboxCategoryElts).map(
|
this.allToolboxCategories = Array.from(toolboxCategoryElts).map(
|
||||||
function(categoryElt) {
|
function(categoryElt) {
|
||||||
var tmpWorkspace = new Blockly.Workspace();
|
var tmpWorkspace = new Blockly.Workspace();
|
||||||
var custom = categoryElt.attributes.custom
|
var custom = categoryElt.attributes.custom;
|
||||||
// TODO (corydiers): Implement custom flyouts once #1153 is solved.
|
// TODO (corydiers): Implement custom flyouts once #1153 is solved.
|
||||||
if (custom && custom.value == Blockly.VARIABLE_CATEGORY_NAME) {
|
if (custom && custom.value == Blockly.VARIABLE_CATEGORY_NAME) {
|
||||||
var varBlocks =
|
var varBlocks =
|
||||||
@@ -95,7 +95,7 @@ blocklyApp.ToolboxModalService = ng.core.Class({
|
|||||||
// containing all the top-level blocks.
|
// containing all the top-level blocks.
|
||||||
var tmpWorkspace = new Blockly.Workspace();
|
var tmpWorkspace = new Blockly.Workspace();
|
||||||
Array.from(toolboxXmlElt.children).forEach(function(topLevelNode) {
|
Array.from(toolboxXmlElt.children).forEach(function(topLevelNode) {
|
||||||
Blockly.Xml.domToBlock(tmpWorkspace, topLevelNode);
|
Blockly.Xml.domToBlock(topLevelNode, tmpWorkspace);
|
||||||
});
|
});
|
||||||
|
|
||||||
that.allToolboxCategories = [{
|
that.allToolboxCategories = [{
|
||||||
@@ -214,7 +214,7 @@ blocklyApp.ToolboxModalService = ng.core.Class({
|
|||||||
this.showModal_(this.toolboxCategoriesForNewGroup, function(block) {
|
this.showModal_(this.toolboxCategoriesForNewGroup, function(block) {
|
||||||
var blockDescription = that.utilsService.getBlockDescription(block);
|
var blockDescription = that.utilsService.getBlockDescription(block);
|
||||||
var xml = Blockly.Xml.blockToDom(block);
|
var xml = Blockly.Xml.blockToDom(block);
|
||||||
var newBlockId = Blockly.Xml.domToBlock(blocklyApp.workspace, xml).id;
|
var newBlockId = Blockly.Xml.domToBlock(xml, blocklyApp.workspace).id;
|
||||||
|
|
||||||
// Invoke a digest cycle, so that the DOM settles.
|
// Invoke a digest cycle, so that the DOM settles.
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ blocklyApp.VariableAddModalComponent = ng.core.Component({
|
|||||||
this.workspace = blocklyApp.workspace;
|
this.workspace = blocklyApp.workspace;
|
||||||
this.variableModalService = variableService;
|
this.variableModalService = variableService;
|
||||||
this.audioService = audioService;
|
this.audioService = audioService;
|
||||||
this.keyboardInputService = keyboardService
|
this.keyboardInputService = keyboardService;
|
||||||
this.modalIsVisible = false;
|
this.modalIsVisible = false;
|
||||||
this.activeButtonIndex = -1;
|
this.activeButtonIndex = -1;
|
||||||
|
|
||||||
@@ -103,7 +103,7 @@ blocklyApp.VariableAddModalComponent = ng.core.Component({
|
|||||||
getInteractiveElements: Blockly.CommonModal.getInteractiveElements,
|
getInteractiveElements: Blockly.CommonModal.getInteractiveElements,
|
||||||
// Gets the container with interactive elements.
|
// Gets the container with interactive elements.
|
||||||
getInteractiveContainer: function() {
|
getInteractiveContainer: function() {
|
||||||
return document.getElementById("varForm");
|
return document.getElementById('varForm');
|
||||||
},
|
},
|
||||||
// Submits the name change for the variable.
|
// Submits the name change for the variable.
|
||||||
submit: function() {
|
submit: function() {
|
||||||
|
|||||||
@@ -74,17 +74,17 @@ blocklyApp.VariableRemoveModalComponent = ng.core.Component({
|
|||||||
this.treeService = treeService;
|
this.treeService = treeService;
|
||||||
this.variableModalService = variableService;
|
this.variableModalService = variableService;
|
||||||
this.audioService = audioService;
|
this.audioService = audioService;
|
||||||
this.keyboardInputService = keyboardService
|
this.keyboardInputService = keyboardService;
|
||||||
this.modalIsVisible = false;
|
this.modalIsVisible = false;
|
||||||
this.activeButtonIndex = -1;
|
this.activeButtonIndex = -1;
|
||||||
this.currentVariableName = "";
|
this.currentVariableName = '';
|
||||||
this.count = 0;
|
this.count = 0;
|
||||||
|
|
||||||
var that = this;
|
var that = this;
|
||||||
this.variableModalService.registerPreRemoveShowHook(
|
this.variableModalService.registerPreRemoveShowHook(
|
||||||
function(name, count) {
|
function(name, count) {
|
||||||
that.currentVariableName = name;
|
that.currentVariableName = name;
|
||||||
that.count = count
|
that.count = count;
|
||||||
that.modalIsVisible = true;
|
that.modalIsVisible = true;
|
||||||
|
|
||||||
Blockly.CommonModal.setupKeyboardOverrides(that);
|
Blockly.CommonModal.setupKeyboardOverrides(that);
|
||||||
@@ -106,7 +106,7 @@ blocklyApp.VariableRemoveModalComponent = ng.core.Component({
|
|||||||
getInteractiveElements: Blockly.CommonModal.getInteractiveElements,
|
getInteractiveElements: Blockly.CommonModal.getInteractiveElements,
|
||||||
// Gets the container with interactive elements.
|
// Gets the container with interactive elements.
|
||||||
getInteractiveContainer: function() {
|
getInteractiveContainer: function() {
|
||||||
return document.getElementById("varForm");
|
return document.getElementById('varForm');
|
||||||
},
|
},
|
||||||
getNumVariables: function() {
|
getNumVariables: function() {
|
||||||
return this.variableModalService.getNumVariables(this.currentVariableName);
|
return this.variableModalService.getNumVariables(this.currentVariableName);
|
||||||
|
|||||||
@@ -72,10 +72,10 @@ blocklyApp.VariableRenameModalComponent = ng.core.Component({
|
|||||||
this.workspace = blocklyApp.workspace;
|
this.workspace = blocklyApp.workspace;
|
||||||
this.variableModalService = variableService;
|
this.variableModalService = variableService;
|
||||||
this.audioService = audioService;
|
this.audioService = audioService;
|
||||||
this.keyboardInputService = keyboardService
|
this.keyboardInputService = keyboardService;
|
||||||
this.modalIsVisible = false;
|
this.modalIsVisible = false;
|
||||||
this.activeButtonIndex = -1;
|
this.activeButtonIndex = -1;
|
||||||
this.currentVariableName = "";
|
this.currentVariableName = '';
|
||||||
|
|
||||||
var that = this;
|
var that = this;
|
||||||
this.variableModalService.registerPreRenameShowHook(
|
this.variableModalService.registerPreRenameShowHook(
|
||||||
@@ -106,7 +106,7 @@ blocklyApp.VariableRenameModalComponent = ng.core.Component({
|
|||||||
getInteractiveElements: Blockly.CommonModal.getInteractiveElements,
|
getInteractiveElements: Blockly.CommonModal.getInteractiveElements,
|
||||||
// Gets the container with interactive elements.
|
// Gets the container with interactive elements.
|
||||||
getInteractiveContainer: function() {
|
getInteractiveContainer: function() {
|
||||||
return document.getElementById("varForm");
|
return document.getElementById('varForm');
|
||||||
},
|
},
|
||||||
// Submits the name change for the variable.
|
// Submits the name change for the variable.
|
||||||
submit: function() {
|
submit: function() {
|
||||||
|
|||||||
Reference in New Issue
Block a user