diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2009-11-04 23:05:51 -0800 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2009-11-04 23:05:51 -0800 |
commit | acb450269cc2c8c52106335bc047dd389f5c6183 (patch) | |
tree | 28d054dc76f792b5c2073208c54f4a54655cd4dc | |
parent | a4c82ffe8a6d923b9b5218915db071be85acd1dd (diff) | |
download | DotNetOpenAuth-acb450269cc2c8c52106335bc047dd389f5c6183.zip DotNetOpenAuth-acb450269cc2c8c52106335bc047dd389f5c6183.tar.gz DotNetOpenAuth-acb450269cc2c8c52106335bc047dd389f5c6183.tar.bz2 |
Fixed bugs in advertised property defaults.
-rw-r--r-- | src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingPartyAjaxControlBase.cs | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingPartyAjaxControlBase.cs b/src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingPartyAjaxControlBase.cs index 0079054..65e032c 100644 --- a/src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingPartyAjaxControlBase.cs +++ b/src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingPartyAjaxControlBase.cs @@ -76,6 +76,16 @@ namespace DotNetOpenAuth.OpenId.RelyingParty { #endregion /// <summary> + /// Default value of the <see cref="Popup"/> property. + /// </summary> + private const PopupBehavior PopupDefault = PopupBehavior.Always; + + /// <summary> + /// Default value of <see cref="LogOnMode"/> property.. + /// </summary> + private const LogOnSiteNotification LogOnModeDefault = LogOnSiteNotification.None; + + /// <summary> /// Backing field for the <see cref="RelyingPartyNonVerifying"/> property. /// </summary> private static OpenIdRelyingParty relyingPartyNonVerifying; @@ -102,10 +112,10 @@ namespace DotNetOpenAuth.OpenId.RelyingParty { /// </summary> protected OpenIdRelyingPartyAjaxControlBase() { // The AJAX login style always uses popups (or invisible iframes). - base.Popup = PopupBehavior.Always; + base.Popup = PopupDefault; // The expected use case for the AJAX login box is for comments... not logging in. - this.LogOnMode = LogOnSiteNotification.None; + this.LogOnMode = LogOnModeDefault; } /// <summary> @@ -125,13 +135,23 @@ namespace DotNetOpenAuth.OpenId.RelyingParty { /// Gets or sets a value indicating when to use a popup window to complete the login experience. /// </summary> /// <value>The default value is <see cref="PopupBehavior.Never"/>.</value> - [Bindable(false), Browsable(false)] + [Bindable(false), Browsable(false), DefaultValue(PopupDefault)] public override PopupBehavior Popup { get { return base.Popup; } set { ErrorUtilities.VerifySupported(value == base.Popup, OpenIdStrings.PropertyValueNotSupported); } } /// <summary> + /// Gets or sets the way a completed login is communicated to the rest of the web site. + /// </summary> + [Bindable(true), DefaultValue(LogOnModeDefault), Category(BehaviorCategory)] + [Description("The way a completed login is communicated to the rest of the web site.")] + public override LogOnSiteNotification LogOnMode { // override to set new DefaultValue + get { return base.LogOnMode; } + set { base.LogOnMode = value; } + } + + /// <summary> /// Gets the completed authentication response. /// </summary> public IAuthenticationResponse AuthenticationResponse { |