components/blockly-src/blocks/procedures.js
function(xmlElement) {
    this.arguments_ = [];
    for (var i = 0, childNode; childNode = xmlElement.childNodes[i]; i++) {
      if (childNode.nodeName.toLowerCase() == 'arg') {
        this.arguments_.push(childNode.getAttribute('name'));
      }
    }
    this.updateParams_();
    Blockly.Procedures.mutateCallers(this);

    // Show or hide the statement input.
    this.setStatements_(xmlElement.getAttribute('statements') !== 'false');
  }
function(xmlElement) {
    this.arguments_ = [];
    for (var i = 0, childNode; childNode = xmlElement.childNodes[i]; i++) {
      if (childNode.nodeName.toLowerCase() == 'arg') {
        this.arguments_.push(childNode.getAttribute('name'));
      }
    }
    this.updateParams_();
    Blockly.Procedures.mutateCallers(this);

    // Show or hide the statement input.
    this.setStatements_(xmlElement.getAttribute('statements') !== 'false');
  }
function ( xmlElement ) { this . arguments_ = [ ] ; for ( var i = 0 , childNode ; childNode = xmlElement . childNodes [ i ] ; i ++ ) { if ( childNode . nodeName . toLowerCase ( ) == 'arg' ) { this . arguments_ . push ( childNode . getAttribute ( 'name' ) ) ; } } this . updateParams_ ( ) ; Blockly . Procedures . mutateCallers ( this ) ; // Show or hide the statement input. this . setStatements_ ( xmlElement . getAttribute ( 'statements' ) !== 'false' ) ; }
Parse XML to restore the argument inputs.
@param {!Element} xmlElement XML storage element.
@this Blockly.Block
Parse XML to restore the argument inputs .