Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / Designer / WebForms / System / Web / UI / Design / WebFormDesignerActionService.cs / 1 / WebFormDesignerActionService.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.UI.Design {
using System;
using System.Collections;
using System.Collections.Specialized;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Design;
using System.Diagnostics;
using System.Drawing;
using System.Drawing.Design;
using System.Globalization;
using System.Resources;
using System.Web.Compilation;
using System.Web.UI;
///
///
public class WebFormsDesignerActionService : DesignerActionService {
public WebFormsDesignerActionService(IServiceProvider serviceProvider)
: base(serviceProvider) {
}
protected override void GetComponentDesignerActions(IComponent component, DesignerActionListCollection actionLists) {
if (component == null) {
throw new ArgumentNullException("component");
}
if (actionLists == null) {
throw new ArgumentNullException("actionLists");
}
IServiceContainer sc = component.Site as IServiceContainer;
if (sc != null) {
DesignerCommandSet dcs = (DesignerCommandSet)sc.GetService(typeof(DesignerCommandSet));
if (dcs != null) {
DesignerActionListCollection pullCollection = dcs.ActionLists;
if (pullCollection != null) {
actionLists.AddRange(pullCollection);
}
}
// if we don't find any, add the verbs for this component there...
if ((actionLists.Count == 0) ||
((actionLists.Count == 1) && (actionLists[0] is ControlDesigner.ControlDesignerActionList))) {
DesignerVerbCollection verbs = dcs.Verbs;
if (verbs != null && verbs.Count != 0) {
DesignerVerb[] verbsArray = new DesignerVerb[verbs.Count];
verbs.CopyTo(verbsArray, 0);
actionLists.Add(new DesignerActionVerbList(verbsArray));
}
}
}
}
}
}
// 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
- InternalBase.cs
- CanonicalXml.cs
- SafePEFileHandle.cs
- SHA256Managed.cs
- RecommendedAsConfigurableAttribute.cs
- AsyncCodeActivity.cs
- FolderBrowserDialog.cs
- AdRotator.cs
- BaseTypeViewSchema.cs
- StringFreezingAttribute.cs
- SessionChannels.cs
- StrokeNodeOperations.cs
- XPathNavigator.cs
- SharingService.cs
- DateTimeOffset.cs
- ProviderCollection.cs
- InfoCardCryptoHelper.cs
- XamlFigureLengthSerializer.cs
- ViewBox.cs
- ScaleTransform3D.cs
- PersonalizationProviderHelper.cs
- SourceExpressionException.cs
- EntityDataReader.cs
- IndentedWriter.cs
- EmptyElement.cs
- VisualStyleTypesAndProperties.cs
- QueryHandler.cs
- ConfigXmlWhitespace.cs
- TreeViewAutomationPeer.cs
- datacache.cs
- ServiceTimeoutsBehavior.cs
- SecurityDescriptor.cs
- PackageStore.cs
- QueryGeneratorBase.cs
- ImageFormat.cs
- HtmlTitle.cs
- ListInitExpression.cs
- WSDualHttpBinding.cs
- Deserializer.cs
- SoapSchemaMember.cs
- TemplateColumn.cs
- AutomationElement.cs
- Unit.cs
- WindowsListBox.cs
- Crypto.cs
- DiscoveryInnerClientAdhocCD1.cs
- FilterableAttribute.cs
- XdrBuilder.cs
- MouseGesture.cs
- FormParameter.cs
- ProviderConnectionPoint.cs
- NativeMethods.cs
- EncoderReplacementFallback.cs
- XdrBuilder.cs
- CompilationUtil.cs
- XmlFormatExtensionAttribute.cs
- WinFormsUtils.cs
- UnsafeNativeMethods.cs
- COM2ExtendedTypeConverter.cs
- ListBindingHelper.cs
- SystemNetworkInterface.cs
- ThreadStaticAttribute.cs
- Attributes.cs
- EntityDataSourceValidationException.cs
- ApplicationManager.cs
- FormViewPageEventArgs.cs
- GenericPrincipal.cs
- TimeSpanMinutesConverter.cs
- StringUtil.cs
- OutputScope.cs
- ColumnProvider.cs
- AsyncResult.cs
- ActivityXamlServices.cs
- IWorkflowDebuggerService.cs
- XmlUtil.cs
- Error.cs
- DocumentPageViewAutomationPeer.cs
- GacUtil.cs
- DetailsViewInsertedEventArgs.cs
- XMLSyntaxException.cs
- LinqDataSourceStatusEventArgs.cs
- ToolStripComboBox.cs
- BamlLocalizableResourceKey.cs
- OdbcConnectionOpen.cs
- ModuleConfigurationInfo.cs
- HyperLinkField.cs
- XmlNodeComparer.cs
- CodeGeneratorAttribute.cs
- SerialStream.cs
- CallbackValidator.cs
- SqlTypeSystemProvider.cs
- EdmMember.cs
- ToolBarButton.cs
- Part.cs
- EntryIndex.cs
- MetadataElement.cs
- ParseElementCollection.cs
- ShaderRenderModeValidation.cs
- ConversionContext.cs
- ErrorWrapper.cs