Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / xsp / System / Web / UI / WebParts / WebPartEditVerb.cs / 1 / WebPartEditVerb.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; internal sealed class WebPartEditVerb : WebPartActionVerb { private string _defaultDescription; private string _defaultText; private string DefaultDescription { get { if (_defaultDescription == null) { _defaultDescription = SR.GetString(SR.WebPartEditVerb_Description); } return _defaultDescription; } } private string DefaultText { get { if (_defaultText == null) { _defaultText = SR.GetString(SR.WebPartEditVerb_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.WebPartEditVerb_Description) ] public override string Description { get { object o = ViewState["Description"]; return (o == null) ? DefaultDescription : (string)o; } set { ViewState["Description"] = value; } } [ WebSysDefaultValue(SR.WebPartEditVerb_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. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; internal sealed class WebPartEditVerb : WebPartActionVerb { private string _defaultDescription; private string _defaultText; private string DefaultDescription { get { if (_defaultDescription == null) { _defaultDescription = SR.GetString(SR.WebPartEditVerb_Description); } return _defaultDescription; } } private string DefaultText { get { if (_defaultText == null) { _defaultText = SR.GetString(SR.WebPartEditVerb_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.WebPartEditVerb_Description) ] public override string Description { get { object o = ViewState["Description"]; return (o == null) ? DefaultDescription : (string)o; } set { ViewState["Description"] = value; } } [ WebSysDefaultValue(SR.WebPartEditVerb_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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- SystemUnicastIPAddressInformation.cs
- MessageDispatch.cs
- AuthenticationManager.cs
- DateTimeOffset.cs
- HtmlButton.cs
- EmptyEnumerator.cs
- RemotingConfigParser.cs
- MarshalDirectiveException.cs
- validationstate.cs
- ScriptingProfileServiceSection.cs
- ThreadExceptionDialog.cs
- WindowsEditBoxRange.cs
- MULTI_QI.cs
- WebPartConnectVerb.cs
- CommonProperties.cs
- XmlWriterSettings.cs
- TimeStampChecker.cs
- XmlSchemaImporter.cs
- WindowsGraphics2.cs
- EntityDataSourceChangingEventArgs.cs
- TextViewDesigner.cs
- updateconfighost.cs
- StringValidatorAttribute.cs
- HasCopySemanticsAttribute.cs
- ChannelSinkStacks.cs
- ProtocolsConfiguration.cs
- ToolStripGrip.cs
- CodeStatement.cs
- WebPartCatalogCloseVerb.cs
- XmlUnspecifiedAttribute.cs
- HorizontalAlignConverter.cs
- BrowserDefinition.cs
- Path.cs
- NotifyCollectionChangedEventArgs.cs
- QueryComponents.cs
- PasswordRecovery.cs
- CompoundFileStreamReference.cs
- QuerySettings.cs
- StreamReader.cs
- XmlUtil.cs
- ComPlusDiagnosticTraceSchemas.cs
- StaticFileHandler.cs
- Subset.cs
- DomainUpDown.cs
- ArgumentNullException.cs
- EntityTypeEmitter.cs
- LocalizationComments.cs
- PrimaryKeyTypeConverter.cs
- TraceUtils.cs
- ObjectToIdCache.cs
- HMACMD5.cs
- CultureInfoConverter.cs
- CqlErrorHelper.cs
- HttpRequest.cs
- ClientType.cs
- VBIdentifierTrimConverter.cs
- PerfProviderCollection.cs
- ToolStripContentPanel.cs
- OleDbConnection.cs
- ParameterBuilder.cs
- RIPEMD160.cs
- DocumentApplicationJournalEntry.cs
- DesignerActionPanel.cs
- LookupNode.cs
- CodeRemoveEventStatement.cs
- XNodeNavigator.cs
- ExtendedPropertyDescriptor.cs
- ExceptionValidationRule.cs
- MDIWindowDialog.cs
- DataGridViewCellLinkedList.cs
- OdbcReferenceCollection.cs
- ReadOnlyPermissionSet.cs
- Baml2006KnownTypes.cs
- ToolboxItemCollection.cs
- DbConnectionInternal.cs
- MenuScrollingVisibilityConverter.cs
- SqlDataSourceCache.cs
- PackageProperties.cs
- InfoCardCryptoHelper.cs
- DetailsViewUpdateEventArgs.cs
- ApplyImportsAction.cs
- HtmlControl.cs
- XmlQueryRuntime.cs
- ModuleConfigurationInfo.cs
- DataGrid.cs
- SafeIUnknown.cs
- TemplateBaseAction.cs
- SafeEventLogWriteHandle.cs
- ClickablePoint.cs
- OneToOneMappingSerializer.cs
- InternalConfigRoot.cs
- ToolConsole.cs
- listitem.cs
- MeshGeometry3D.cs
- CryptographicAttribute.cs
- FullTextBreakpoint.cs
- UnicastIPAddressInformationCollection.cs
- ImageAutomationPeer.cs
- XmlSchemaExporter.cs
- InputMethod.cs