third_party/js/mozmill/shared-modules/toolbars.js
function locationBar_focus(event) {
    switch (event.type) {
      case "click":
        this._controller.click(this.urlbar);
        break;
      case "shortcut":
        var cmdKey = utils.getEntity(this.getDtds(), "openCmd.commandkey");
        this._controller.keypress(null, cmdKey, {accelKey: true});
        break;
      default:
        throw new Error(arguments.callee.name + ": Unkown event type - " + event.type);
    }

    // Wait until the location bar has been focused
    this._controller.waitForEval("subject.getAttribute('focused') == 'true'",
                                 TIMEOUT, 100, this.urlbar.getNode());
  }
function locationBar_focus(event) {
    switch (event.type) {
      case "click":
        this._controller.click(this.urlbar);
        break;
      case "shortcut":
        var cmdKey = utils.getEntity(this.getDtds(), "openCmd.commandkey");
        this._controller.keypress(null, cmdKey, {accelKey: true});
        break;
      default:
        throw new Error(arguments.callee.name + ": Unkown event type - " + event.type);
    }

    // Wait until the location bar has been focused
    this._controller.waitForEval("subject.getAttribute('focused') == 'true'",
                                 TIMEOUT, 100, this.urlbar.getNode());
  }
function locationBar_focus ( event ) { switch ( event . type ) { case "click" : this . _controller . click ( this . urlbar ) ; break ; case "shortcut" : var cmdKey = utils . getEntity ( this . getDtds ( ) , "openCmd.commandkey" ) ; this . _controller . keypress ( null , cmdKey , { accelKey : true } ) ; break ; default : throw new Error ( arguments . callee . name + ": Unkown event type - " + event . type ) ; } // Wait until the location bar has been focused this . _controller . waitForEval ( "subject.getAttribute('focused') == 'true'" , TIMEOUT , 100 , this . urlbar . getNode ( ) ) ; }
Focus the location bar

@param {object} event
Focus the location bar with the given event (click or shortcut)
Focus the location bar