Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / WinForms / Managed / System / WinForms / PropertyGridInternal / PropertiesTab.cs / 1 / PropertiesTab.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms.PropertyGridInternal { using System.Runtime.InteropServices; using System.Diagnostics; using System; using System.ComponentModel.Design; using System.ComponentModel; using System.Windows.Forms.ComponentModel; using System.Windows.Forms.Design; using System.Collections; using Microsoft.Win32; ////// /// [System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.InheritanceDemand, Name="FullTrust")] [System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.LinkDemand, Name="FullTrust")] public class PropertiesTab : PropertyTab { ///[To be supplied.] ////// /// public override string TabName { get { return SR.GetString(SR.PBRSToolTipProperties); } } ///[To be supplied.] ////// /// public override string HelpKeyword { get { return "vs.properties"; // do not localize. } } ///[To be supplied.] ////// /// public override PropertyDescriptor GetDefaultProperty(object obj) { PropertyDescriptor def = base.GetDefaultProperty(obj); if (def == null) { PropertyDescriptorCollection props = GetProperties(obj); if (props != null) { for (int i = 0; i < props.Count; i++) { if ("Name".Equals(props[i].Name)) { def = props[i]; break; } } } } return def; } ///[To be supplied.] ////// /// public override PropertyDescriptorCollection GetProperties(object component, Attribute[] attributes) { return GetProperties(null, component, attributes); } ///[To be supplied.] ////// /// public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext context, object component, Attribute[] attributes) { if (attributes == null) { attributes = new Attribute[]{BrowsableAttribute.Yes}; } if (context == null) { return TypeDescriptor.GetProperties(component, attributes); } else { TypeConverter tc = (context.PropertyDescriptor == null ? TypeDescriptor.GetConverter(component) : context.PropertyDescriptor.Converter); if (tc == null || !tc.GetPropertiesSupported(context)) { return TypeDescriptor.GetProperties(component, attributes); } else { return tc.GetProperties(context, component, attributes); } } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.[To be supplied.] ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- BevelBitmapEffect.cs
- Thumb.cs
- FontWeightConverter.cs
- TabControlDesigner.cs
- XmlElementAttributes.cs
- DecimalStorage.cs
- TreeNodeStyleCollection.cs
- ToolboxItemAttribute.cs
- DbConnectionStringBuilder.cs
- LayoutEvent.cs
- RectAnimationUsingKeyFrames.cs
- XmlBinaryReader.cs
- HttpModuleCollection.cs
- DescendentsWalkerBase.cs
- AutoResizedEvent.cs
- EnumDataContract.cs
- SqlDataSourceSelectingEventArgs.cs
- SplitterPanel.cs
- SByteConverter.cs
- Visual3D.cs
- IntegerFacetDescriptionElement.cs
- BuildDependencySet.cs
- QilBinary.cs
- base64Transforms.cs
- OpCopier.cs
- TrustLevelCollection.cs
- WebPartConnectionsConnectVerb.cs
- EmptyStringExpandableObjectConverter.cs
- IOException.cs
- RecipientInfo.cs
- BindingElement.cs
- HandlerWithFactory.cs
- XmlAnyAttributeAttribute.cs
- XPathNavigatorReader.cs
- Single.cs
- WindowsStartMenu.cs
- LinqMaximalSubtreeNominator.cs
- IndexedString.cs
- Parsers.cs
- SwitchElementsCollection.cs
- FileController.cs
- Typography.cs
- SignedXml.cs
- MarkupExtensionParser.cs
- WebPartEditorApplyVerb.cs
- SmtpSection.cs
- SHA384Managed.cs
- SqlConnectionPoolProviderInfo.cs
- _FtpControlStream.cs
- TextCharacters.cs
- SqlMethods.cs
- TraceContext.cs
- ConfigXmlCDataSection.cs
- CustomErrorCollection.cs
- CategoryState.cs
- tooltip.cs
- UnmanagedMemoryStreamWrapper.cs
- WmlSelectionListAdapter.cs
- ColumnMapCopier.cs
- DbConnectionClosed.cs
- MouseDevice.cs
- ActivityCollectionMarkupSerializer.cs
- ADRoleFactoryConfiguration.cs
- TraceContext.cs
- OracleCommandSet.cs
- DrawingBrush.cs
- CompilerGeneratedAttribute.cs
- AssociationType.cs
- EvidenceBase.cs
- PartialTrustVisibleAssembly.cs
- ScrollEvent.cs
- BindingOperations.cs
- SimpleBitVector32.cs
- ZoneLinkButton.cs
- SQLInt64.cs
- TypeUtils.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- ItemsChangedEventArgs.cs
- Imaging.cs
- CompilerGeneratedAttribute.cs
- LocationSectionRecord.cs
- RefType.cs
- VisualTreeUtils.cs
- TextSpanModifier.cs
- ExtendedPropertyCollection.cs
- ExpressionNode.cs
- ApplicationFileCodeDomTreeGenerator.cs
- InternalConfigHost.cs
- CodeCastExpression.cs
- BitmapData.cs
- CustomWebEventKey.cs
- SettingsProviderCollection.cs
- VerticalAlignConverter.cs
- ElapsedEventArgs.cs
- SaveFileDialog.cs
- Calendar.cs
- CounterSample.cs
- TraceHandlerErrorFormatter.cs
- WorkingDirectoryEditor.cs
- unsafenativemethodstextservices.cs