Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / xsp / System / Web / UI / WebControls / Adapters / HideDisabledControlAdapter.cs / 1 / HideDisabledControlAdapter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.Adapters { using System; using System.Security.Permissions; using System.Web; using System.Web.UI; using System.Web.UI.Adapters; // Used for controls which use their default rendering, but are hidden when disabled. [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] public class HideDisabledControlAdapter : WebControlAdapter { // Returns without doing anything if the control is disabled, otherwise, uses the default rendering. protected internal override void Render(HtmlTextWriter writer) { if (Control.Enabled == false) { return; } Control.Render(writer); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.Adapters { using System; using System.Security.Permissions; using System.Web; using System.Web.UI; using System.Web.UI.Adapters; // Used for controls which use their default rendering, but are hidden when disabled. [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] public class HideDisabledControlAdapter : WebControlAdapter { // Returns without doing anything if the control is disabled, otherwise, uses the default rendering. protected internal override void Render(HtmlTextWriter writer) { if (Control.Enabled == false) { return; } Control.Render(writer); } } } // 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
- DataPager.cs
- QilPatternVisitor.cs
- TemplateKeyConverter.cs
- Style.cs
- SqlUDTStorage.cs
- SqlStream.cs
- CodeAttributeArgument.cs
- SQLGuid.cs
- DefaultBindingPropertyAttribute.cs
- DataGridViewComboBoxColumn.cs
- ValidationPropertyAttribute.cs
- ListSortDescriptionCollection.cs
- CustomTypeDescriptor.cs
- Point4D.cs
- Resources.Designer.cs
- DataGridViewCellStyleChangedEventArgs.cs
- ObsoleteAttribute.cs
- TrustSection.cs
- Events.cs
- RC2CryptoServiceProvider.cs
- DesignColumnCollection.cs
- IsolatedStoragePermission.cs
- PartitionResolver.cs
- _LazyAsyncResult.cs
- Point.cs
- NativeMethods.cs
- EventNotify.cs
- __TransparentProxy.cs
- EntityWrapperFactory.cs
- MetadataCollection.cs
- ProcessHostMapPath.cs
- IntSecurity.cs
- SamlAudienceRestrictionCondition.cs
- FilterEventArgs.cs
- StateWorkerRequest.cs
- HttpModulesSection.cs
- WindowsComboBox.cs
- TextRange.cs
- BrowserDefinitionCollection.cs
- XmlAnyElementAttribute.cs
- Decoder.cs
- DataGridViewDataConnection.cs
- LinearQuaternionKeyFrame.cs
- ContainerUtilities.cs
- SplitterCancelEvent.cs
- ItemCollection.cs
- FilterException.cs
- SafeHandles.cs
- CollectionViewGroupRoot.cs
- COAUTHINFO.cs
- XmlConvert.cs
- ECDiffieHellmanCng.cs
- Html32TextWriter.cs
- DependencyProperty.cs
- SqlCharStream.cs
- PackagingUtilities.cs
- ErrorHandlerModule.cs
- ConfigurationPropertyCollection.cs
- MenuScrollingVisibilityConverter.cs
- Nodes.cs
- MsmqSecureHashAlgorithm.cs
- IRCollection.cs
- SchemaNamespaceManager.cs
- BulletedListEventArgs.cs
- DbParameterHelper.cs
- MouseWheelEventArgs.cs
- SupportingTokenListenerFactory.cs
- ResourceBinder.cs
- DataGridTextBoxColumn.cs
- ChannelManager.cs
- DesignerActionMethodItem.cs
- ResourceDictionaryCollection.cs
- AbstractDataSvcMapFileLoader.cs
- BindToObject.cs
- EditorPart.cs
- FieldCollectionEditor.cs
- FlowNode.cs
- ResourceReferenceExpressionConverter.cs
- counter.cs
- ellipse.cs
- State.cs
- TreeNodeBindingCollection.cs
- Pts.cs
- PersistenceTypeAttribute.cs
- OdbcError.cs
- EncoderNLS.cs
- CodeComment.cs
- AssemblyAttributes.cs
- SqlNotificationRequest.cs
- SqlRemoveConstantOrderBy.cs
- CodeEntryPointMethod.cs
- FunctionQuery.cs
- SeparatorAutomationPeer.cs
- BitmapEffectOutputConnector.cs
- PositiveTimeSpanValidator.cs
- PersianCalendar.cs
- HtmlImage.cs
- WebPartConnectionsConnectVerb.cs
- CodeNamespaceCollection.cs
- MgmtResManager.cs