lib/gcli/languages/command.js
function() {
    this.lastText = this.assignment.arg.text;

    var field = this.terminal.field;
    if (field) {
      field.onFieldChange.remove(this.terminal.fieldChanged, this.terminal);
      field.destroy();
    }

    var fields = this.terminal.system.fields;
    field = this.terminal.field = fields.get(this.assignment.param.type, {
      document: this.terminal.document,
      requisition: this.requisition
    });

    this.focusManager.setImportantFieldFlag(field.isImportant);

    field.onFieldChange.add(this.terminal.fieldChanged, this.terminal);
    field.setConversion(this.assignment.conversion);

    // Filled in by the template process
    this.terminal.errorEle = undefined;
    this.terminal.descriptionEle = undefined;

    var contents = this.terminal.tooltipTemplate.cloneNode(true);
    domtemplate.template(contents, this.terminal, {
      blankNullUndefined: true,
      stack: 'terminal.html#tooltip'
    });

    util.clearElement(this.terminal.tooltipElement);
    this.terminal.tooltipElement.appendChild(contents);
    this.terminal.tooltipElement.style.display = 'block';

    field.setMessageElement(this.terminal.errorEle);
  }
function() {
    this.lastText = this.assignment.arg.text;

    var field = this.terminal.field;
    if (field) {
      field.onFieldChange.remove(this.terminal.fieldChanged, this.terminal);
      field.destroy();
    }

    var fields = this.terminal.system.fields;
    field = this.terminal.field = fields.get(this.assignment.param.type, {
      document: this.terminal.document,
      requisition: this.requisition
    });

    this.focusManager.setImportantFieldFlag(field.isImportant);

    field.onFieldChange.add(this.terminal.fieldChanged, this.terminal);
    field.setConversion(this.assignment.conversion);

    // Filled in by the template process
    this.terminal.errorEle = undefined;
    this.terminal.descriptionEle = undefined;

    var contents = this.terminal.tooltipTemplate.cloneNode(true);
    domtemplate.template(contents, this.terminal, {
      blankNullUndefined: true,
      stack: 'terminal.html#tooltip'
    });

    util.clearElement(this.terminal.tooltipElement);
    this.terminal.tooltipElement.appendChild(contents);
    this.terminal.tooltipElement.style.display = 'block';

    field.setMessageElement(this.terminal.errorEle);
  }
function ( ) { this . lastText = this . assignment . arg . text ; var field = this . terminal . field ; if ( field ) { field . onFieldChange . remove ( this . terminal . fieldChanged , this . terminal ) ; field . destroy ( ) ; } var fields = this . terminal . system . fields ; field = this . terminal . field = fields . get ( this . assignment . param . type , { document : this . terminal . document , requisition : this . requisition } ) ; this . focusManager . setImportantFieldFlag ( field . isImportant ) ; field . onFieldChange . add ( this . terminal . fieldChanged , this . terminal ) ; field . setConversion ( this . assignment . conversion ) ; // Filled in by the template process this . terminal . errorEle = undefined ; this . terminal . descriptionEle = undefined ; var contents = this . terminal . tooltipTemplate . cloneNode ( true ) ; domtemplate . template ( contents , this . terminal , { blankNullUndefined : true , stack : 'terminal.html#tooltip' } ) ; util . clearElement ( this . terminal . tooltipElement ) ; this . terminal . tooltipElement . appendChild ( contents ) ; this . terminal . tooltipElement . style . display = 'block' ; field . setMessageElement ( this . terminal . errorEle ) ; }
Called whenever the assignment that we're providing help with changes
Called whenever the assignment that we re providing help with changes