Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / MIT / System / Web / UI / MobileControls / MobileControlBuilder.cs / 1305376 / MobileControlBuilder.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Collections; using System.ComponentModel; using System.ComponentModel.Design; using System.Diagnostics; using System.Drawing; using System.Globalization; using System.Web; using System.Web.UI; using System.Web.UI.Design.WebControls; using System.Web.UI.WebControls; using System.Security.Permissions; namespace System.Web.UI.MobileControls { /* * Control builder for mobile controls. * * Copyright (c) 2000 Microsoft Corporation */ ///[AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] [Obsolete("The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.")] public class MobileControlBuilder : ControlBuilder { /// public override bool AllowWhitespaceLiterals() { return false; } /// public override Type GetChildControlType(String tagName, IDictionary attributes) { Type type; if (String.Compare(tagName, typeof(DeviceSpecific).Name, StringComparison.OrdinalIgnoreCase) == 0) { type = typeof(DeviceSpecific); } else { type = base.GetChildControlType(tagName, attributes); //if (type == null) //{ // type = Parser.RootBuilder.GetChildControlType(tagName, attributes); //} } // enforce valid control nesting behaviour if (typeof(Form).IsAssignableFrom(type)) { throw new Exception( SR.GetString(SR.MobileControlBuilder_ControlMustBeTopLevelOfPage, "Form")); } if (typeof(StyleSheet).IsAssignableFrom(type)) { throw new Exception( SR.GetString(SR.MobileControlBuilder_ControlMustBeTopLevelOfPage, "StyleSheet")); } if (typeof(Style).IsAssignableFrom(type) && !typeof(StyleSheet).IsAssignableFrom(ControlType)) { throw new Exception( SR.GetString(SR.MobileControlBuilder_StyleMustBeInStyleSheet)); } return type; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ // // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Collections; using System.ComponentModel; using System.ComponentModel.Design; using System.Diagnostics; using System.Drawing; using System.Globalization; using System.Web; using System.Web.UI; using System.Web.UI.Design.WebControls; using System.Web.UI.WebControls; using System.Security.Permissions; namespace System.Web.UI.MobileControls { /* * Control builder for mobile controls. * * Copyright (c) 2000 Microsoft Corporation */ ///[AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] [Obsolete("The System.Web.Mobile.dll assembly has been deprecated and should no longer be used. For information about how to develop ASP.NET mobile applications, see http://go.microsoft.com/fwlink/?LinkId=157231.")] public class MobileControlBuilder : ControlBuilder { /// public override bool AllowWhitespaceLiterals() { return false; } /// public override Type GetChildControlType(String tagName, IDictionary attributes) { Type type; if (String.Compare(tagName, typeof(DeviceSpecific).Name, StringComparison.OrdinalIgnoreCase) == 0) { type = typeof(DeviceSpecific); } else { type = base.GetChildControlType(tagName, attributes); //if (type == null) //{ // type = Parser.RootBuilder.GetChildControlType(tagName, attributes); //} } // enforce valid control nesting behaviour if (typeof(Form).IsAssignableFrom(type)) { throw new Exception( SR.GetString(SR.MobileControlBuilder_ControlMustBeTopLevelOfPage, "Form")); } if (typeof(StyleSheet).IsAssignableFrom(type)) { throw new Exception( SR.GetString(SR.MobileControlBuilder_ControlMustBeTopLevelOfPage, "StyleSheet")); } if (typeof(Style).IsAssignableFrom(type) && !typeof(StyleSheet).IsAssignableFrom(ControlType)) { throw new Exception( SR.GetString(SR.MobileControlBuilder_StyleMustBeInStyleSheet)); } return type; } } } // 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
- ErrorEventArgs.cs
- XmlSchemaException.cs
- Completion.cs
- LoginView.cs
- TreeIterators.cs
- MaskedTextProvider.cs
- UserControlCodeDomTreeGenerator.cs
- LogWriteRestartAreaState.cs
- SqlClientPermission.cs
- ProgressBarRenderer.cs
- BinHexEncoding.cs
- DataGridClipboardHelper.cs
- MultiAsyncResult.cs
- EmbeddedMailObjectCollectionEditor.cs
- Ticks.cs
- WorkflowInstanceExtensionManager.cs
- UdpTransportSettingsElement.cs
- IsolatedStorageException.cs
- VectorAnimationBase.cs
- Column.cs
- NavigationPropertyAccessor.cs
- ApplicationFileCodeDomTreeGenerator.cs
- DefaultBinder.cs
- Claim.cs
- Scheduler.cs
- ProfileModule.cs
- DynamicQueryableWrapper.cs
- StorageTypeMapping.cs
- Trigger.cs
- DataGridViewAutoSizeColumnModeEventArgs.cs
- UmAlQuraCalendar.cs
- ColorMatrix.cs
- EventEntry.cs
- Inflater.cs
- MouseOverProperty.cs
- SystemColorTracker.cs
- DynamicMetaObject.cs
- UInt16Storage.cs
- DataPagerFieldCommandEventArgs.cs
- SynchronizingStream.cs
- TemplatePropertyEntry.cs
- Matrix3DStack.cs
- ToolStripRenderEventArgs.cs
- WebPartDesigner.cs
- CodeDomLoader.cs
- EntityClassGenerator.cs
- EncryptedType.cs
- IODescriptionAttribute.cs
- StreamGeometry.cs
- HtmlGenericControl.cs
- RankException.cs
- COM2TypeInfoProcessor.cs
- XmlDataSourceView.cs
- unsafeIndexingFilterStream.cs
- EntityConnection.cs
- DataGridViewButtonColumn.cs
- LambdaExpression.cs
- DiagnosticTraceSource.cs
- BypassElementCollection.cs
- ProvidersHelper.cs
- ColumnHeaderConverter.cs
- ChtmlFormAdapter.cs
- DocumentViewer.cs
- ButtonFieldBase.cs
- CodeParameterDeclarationExpressionCollection.cs
- RegexMatch.cs
- MachineKeyConverter.cs
- XpsColorContext.cs
- SoapServerProtocol.cs
- DataGridViewRow.cs
- WinFormsSecurity.cs
- ErrorsHelper.cs
- RadioButtonList.cs
- HWStack.cs
- WindowsBrush.cs
- DataGridViewAdvancedBorderStyle.cs
- CustomValidator.cs
- ObjectStateFormatter.cs
- SectionInput.cs
- InputGestureCollection.cs
- DataGridState.cs
- SimpleTextLine.cs
- AsyncOperation.cs
- Helpers.cs
- GroupQuery.cs
- ServiceNameElement.cs
- SapiAttributeParser.cs
- RegexGroupCollection.cs
- AutomationPropertyInfo.cs
- Point4DConverter.cs
- ObjectAnimationUsingKeyFrames.cs
- InvokeBase.cs
- DataGridCellAutomationPeer.cs
- VectorKeyFrameCollection.cs
- SafeNativeMethodsCLR.cs
- __TransparentProxy.cs
- SoapExtensionStream.cs
- ResourceDescriptionAttribute.cs
- FontDriver.cs
- DefaultSerializationProviderAttribute.cs