code: function ContentDialog_setState(NewState, arg0) {
                      if (!this._disposed) {
                          this._state && this._state.exit();
                          this._state = new NewState();
                          this._state.dialog = this;
                          this._state.enter(arg0);
                      }
                  }
docs: Methods called by states