Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / Design / DesignerVerb.cs / 1 / DesignerVerb.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel.Design { using Microsoft.Win32; using System; using System.ComponentModel; using System.Diagnostics; using System.Security.Permissions; using System.Text.RegularExpressions; ////// [HostProtection(SharedState = true)] [System.Runtime.InteropServices.ComVisible(true)] [System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.InheritanceDemand, Name="FullTrust")] [System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.LinkDemand, Name="FullTrust")] public class DesignerVerb : MenuCommand { ///Represents a verb that can be executed by a component's designer. ////// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")] public DesignerVerb(string text, EventHandler handler) : base(handler, StandardCommands.VerbFirst) { Properties["Text"] = text == null ? null : Regex.Replace(text, @"\(\&.\)", ""); // VSWHIDBEY 485835 } ////// Initializes a new instance of the ///class. /// /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")] public DesignerVerb(string text, EventHandler handler, CommandID startCommandID) : base(handler, startCommandID) { Properties["Text"] = text == null ? null : Regex.Replace(text, @"\(\&.\)", "");// VSWHIDBEY 485835 } ////// Initializes a new instance of the ////// class. /// /// Gets or sets the description of the menu item for the verb. /// public string Description { get { object result = Properties["Description"]; if (result == null) { return String.Empty; } return (string)result; } set { Properties["Description"] = value; } } ////// public string Text { get { object result = Properties["Text"]; if (result == null) { return String.Empty; } return (string)result; } } ////// Gets or sets the text to show on the menu item for the verb. /// ////// public override string ToString() { return Text + " : " + base.ToString(); } } }/// Overrides object's ToString(). /// ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TabItemWrapperAutomationPeer.cs
- Binding.cs
- MarshalByRefObject.cs
- SynchronizedDisposablePool.cs
- SystemIPInterfaceProperties.cs
- TypeListConverter.cs
- ForeignKeyConstraint.cs
- Converter.cs
- SessionParameter.cs
- BezierSegment.cs
- DateTimeFormat.cs
- CodeGeneratorOptions.cs
- ProcessHostFactoryHelper.cs
- RepeaterCommandEventArgs.cs
- NullRuntimeConfig.cs
- DataDocumentXPathNavigator.cs
- WebSysDefaultValueAttribute.cs
- OrderedDictionaryStateHelper.cs
- KeyFrames.cs
- NamespaceQuery.cs
- ReadWriteSpinLock.cs
- DbConnectionInternal.cs
- DoubleLinkList.cs
- SystemTcpStatistics.cs
- RegistrationContext.cs
- FormView.cs
- ValueUnavailableException.cs
- formatter.cs
- ControlBuilderAttribute.cs
- PropertyMappingExceptionEventArgs.cs
- ResolvePPIDRequest.cs
- DrawingGroup.cs
- XmlAttributeAttribute.cs
- SqlStatistics.cs
- PtsContext.cs
- RunWorkerCompletedEventArgs.cs
- CharacterBufferReference.cs
- CollectionsUtil.cs
- SqlUserDefinedAggregateAttribute.cs
- EdmSchemaAttribute.cs
- AmbiguousMatchException.cs
- UnsafeNativeMethods.cs
- SqlBinder.cs
- FacetValueContainer.cs
- DetailsViewDesigner.cs
- DataControlImageButton.cs
- XmlSchemaImporter.cs
- TextOutput.cs
- HostProtectionPermission.cs
- brushes.cs
- UserInitiatedRoutedEventPermissionAttribute.cs
- CompositeFontInfo.cs
- FixedDocumentPaginator.cs
- CLRBindingWorker.cs
- CollectionViewSource.cs
- SqlDataSourceEnumerator.cs
- DataGridColumnHeaderAutomationPeer.cs
- OSFeature.cs
- PlaceHolder.cs
- ConvertTextFrag.cs
- RouteValueDictionary.cs
- QuaternionRotation3D.cs
- UrlAuthFailureHandler.cs
- WindowsAuthenticationEventArgs.cs
- StrokeSerializer.cs
- WindowsPrincipal.cs
- streamingZipPartStream.cs
- DeploymentSection.cs
- IDispatchConstantAttribute.cs
- WebPartHeaderCloseVerb.cs
- ToolStripItem.cs
- BasicViewGenerator.cs
- ReflectionUtil.cs
- NameNode.cs
- WpfSharedXamlSchemaContext.cs
- HashHelper.cs
- BufferedGraphicsManager.cs
- ColorConverter.cs
- UniformGrid.cs
- PersonalizationProviderCollection.cs
- WindowsTab.cs
- CharUnicodeInfo.cs
- WebPartManagerInternals.cs
- HiddenFieldPageStatePersister.cs
- DelegatedStream.cs
- WebBrowserNavigatingEventHandler.cs
- EmptyEnumerable.cs
- DataGridViewButtonCell.cs
- StickyNote.cs
- TagMapCollection.cs
- SQLInt16.cs
- GridViewUpdateEventArgs.cs
- MainMenu.cs
- GreenMethods.cs
- InlineCollection.cs
- EncoderNLS.cs
- SelectionPattern.cs
- SystemPens.cs
- EarlyBoundInfo.cs
- CompilerGeneratedAttribute.cs