code: function (type, args, obj) {
  
              var el = this.firstFormElement;
  
              if (args && args[1]) {
                  Event.stopEvent(args[1]);
              }
  
              if (el) {
                  try {
                      el.focus();
                  } catch(oException) {
                      // Ignore
                  }
              } else {
                  if (this.defaultHtmlButton) {
                      this.focusDefaultButton();
                  } else {
                      this.focusFirstButton();
                  }
              }
          }
docs: <p>
  Sets focus to the first focusable element in the Dialog's form if found,
  else, the default button if found, else the first button defined via the
  "buttons" configuration property.
  </p>
  <p>
  This method is invoked when the Dialog is made visible.
  </p>
  @method focusFirst