Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / UI / WebParts / WebPartCloseVerb.cs / 1 / WebPartCloseVerb.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; internal sealed class WebPartCloseVerb : WebPartActionVerb { private string _defaultDescription; private string _defaultText; private string DefaultDescription { get { if (_defaultDescription == null) { _defaultDescription = SR.GetString(SR.WebPartCloseVerb_Description); } return _defaultDescription; } } private string DefaultText { get { if (_defaultText == null) { _defaultText = SR.GetString(SR.WebPartCloseVerb_Text); } return _defaultText; } } // Properties must look at viewstate directly instead of the property in the base class, // so we can distinguish between an unset property and a property set to String.Empty. [ WebSysDefaultValue(SR.WebPartCloseVerb_Description) ] public override string Description { get { object o = ViewState["Description"]; return (o == null) ? DefaultDescription : (string)o; } set { ViewState["Description"] = value; } } [ WebSysDefaultValue(SR.WebPartCloseVerb_Text) ] public override string Text { get { object o = ViewState["Text"]; return (o == null) ? DefaultText : (string)o; } set { ViewState["Text"] = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; internal sealed class WebPartCloseVerb : WebPartActionVerb { private string _defaultDescription; private string _defaultText; private string DefaultDescription { get { if (_defaultDescription == null) { _defaultDescription = SR.GetString(SR.WebPartCloseVerb_Description); } return _defaultDescription; } } private string DefaultText { get { if (_defaultText == null) { _defaultText = SR.GetString(SR.WebPartCloseVerb_Text); } return _defaultText; } } // Properties must look at viewstate directly instead of the property in the base class, // so we can distinguish between an unset property and a property set to String.Empty. [ WebSysDefaultValue(SR.WebPartCloseVerb_Description) ] public override string Description { get { object o = ViewState["Description"]; return (o == null) ? DefaultDescription : (string)o; } set { ViewState["Description"] = value; } } [ WebSysDefaultValue(SR.WebPartCloseVerb_Text) ] public override string Text { get { object o = ViewState["Text"]; return (o == null) ? DefaultText : (string)o; } set { ViewState["Text"] = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- FixedTextContainer.cs
- XPathDocumentIterator.cs
- AsyncOperation.cs
- HttpRuntime.cs
- ConfigUtil.cs
- StrokeCollection.cs
- XmlSchemaAnyAttribute.cs
- HttpCachePolicyElement.cs
- MessageContractMemberAttribute.cs
- HtmlUtf8RawTextWriter.cs
- FlowThrottle.cs
- MaskDescriptor.cs
- WebSysDisplayNameAttribute.cs
- ImageInfo.cs
- HyperLinkStyle.cs
- ListItemsCollectionEditor.cs
- DocumentXmlWriter.cs
- EventHandlerList.cs
- ToolBarPanel.cs
- COAUTHINFO.cs
- DispatcherHooks.cs
- CollectionChangedEventManager.cs
- PolicyStatement.cs
- OutputCacheSettings.cs
- Pool.cs
- ConfigurationPermission.cs
- TextBreakpoint.cs
- Pair.cs
- datacache.cs
- HttpDateParse.cs
- DispatcherHooks.cs
- BitmapCacheBrush.cs
- ConsumerConnectionPointCollection.cs
- DesignerLoader.cs
- securitycriticaldataformultiplegetandset.cs
- serverconfig.cs
- Drawing.cs
- ProxyElement.cs
- HandlerWithFactory.cs
- PieceDirectory.cs
- SessionPageStatePersister.cs
- ClientUtils.cs
- LinqDataSourceDisposeEventArgs.cs
- WebHttpSecurity.cs
- HtmlInputPassword.cs
- TopClause.cs
- XmlFormatExtensionAttribute.cs
- SymLanguageType.cs
- BatchWriter.cs
- RC2CryptoServiceProvider.cs
- XmlSchemaProviderAttribute.cs
- WindowsListView.cs
- KnownTypes.cs
- TextDecoration.cs
- ValueOfAction.cs
- EncodingNLS.cs
- WebPartEditorOkVerb.cs
- Attachment.cs
- NameObjectCollectionBase.cs
- MiniConstructorInfo.cs
- CollectionBuilder.cs
- Soap11ServerProtocol.cs
- EditorPart.cs
- MailDefinition.cs
- InkCanvasFeedbackAdorner.cs
- ICspAsymmetricAlgorithm.cs
- HtmlInputPassword.cs
- DLinqColumnProvider.cs
- Hashtable.cs
- EntitySetBase.cs
- ListViewGroupConverter.cs
- SessionConnectionReader.cs
- VersionedStream.cs
- ActivityBuilderXamlWriter.cs
- TemplateBuilder.cs
- PersistenceProviderBehavior.cs
- SizeChangedEventArgs.cs
- PackageRelationship.cs
- Int16Converter.cs
- MouseBinding.cs
- PriorityQueue.cs
- XmlSubtreeReader.cs
- FigureParaClient.cs
- MetadataLocation.cs
- ReservationNotFoundException.cs
- CodeGroup.cs
- PropertyPathConverter.cs
- HtmlControlAdapter.cs
- Propagator.ExtentPlaceholderCreator.cs
- TrustLevelCollection.cs
- DuplicateWaitObjectException.cs
- OrderablePartitioner.cs
- SpecialNameAttribute.cs
- ShellProvider.cs
- X509ChainElement.cs
- RemoteWebConfigurationHost.cs
- LoginView.cs
- FileChangeNotifier.cs
- RealizationContext.cs
- ScrollEvent.cs