Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / ThemeInfoAttribute.cs / 1305600 / ThemeInfoAttribute.cs
//---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using System; using System.Windows; using System.Reflection; namespace System.Windows { ////// Specifies where theme dictionaries are stored for types in an assembly. /// [AttributeUsage(AttributeTargets.Assembly)] public sealed class ThemeInfoAttribute : Attribute { ////// Creates an attribute that defines theme dictionary locations for types in an assembly. /// /// The location of theme specific resources. /// The location of generic, not theme specific, resources. public ThemeInfoAttribute(ResourceDictionaryLocation themeDictionaryLocation, ResourceDictionaryLocation genericDictionaryLocation) { _themeDictionaryLocation = themeDictionaryLocation; _genericDictionaryLocation = genericDictionaryLocation; } ////// The location of theme specific resources. /// public ResourceDictionaryLocation ThemeDictionaryLocation { get { return _themeDictionaryLocation; } } ////// The location of generic, not theme specific, resources. /// public ResourceDictionaryLocation GenericDictionaryLocation { get { return _genericDictionaryLocation; } } internal static ThemeInfoAttribute FromAssembly(Assembly assembly) { return Attribute.GetCustomAttribute(assembly, typeof(ThemeInfoAttribute)) as ThemeInfoAttribute; } private ResourceDictionaryLocation _themeDictionaryLocation; private ResourceDictionaryLocation _genericDictionaryLocation; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using System; using System.Windows; using System.Reflection; namespace System.Windows { ////// Specifies where theme dictionaries are stored for types in an assembly. /// [AttributeUsage(AttributeTargets.Assembly)] public sealed class ThemeInfoAttribute : Attribute { ////// Creates an attribute that defines theme dictionary locations for types in an assembly. /// /// The location of theme specific resources. /// The location of generic, not theme specific, resources. public ThemeInfoAttribute(ResourceDictionaryLocation themeDictionaryLocation, ResourceDictionaryLocation genericDictionaryLocation) { _themeDictionaryLocation = themeDictionaryLocation; _genericDictionaryLocation = genericDictionaryLocation; } ////// The location of theme specific resources. /// public ResourceDictionaryLocation ThemeDictionaryLocation { get { return _themeDictionaryLocation; } } ////// The location of generic, not theme specific, resources. /// public ResourceDictionaryLocation GenericDictionaryLocation { get { return _genericDictionaryLocation; } } internal static ThemeInfoAttribute FromAssembly(Assembly assembly) { return Attribute.GetCustomAttribute(assembly, typeof(ThemeInfoAttribute)) as ThemeInfoAttribute; } private ResourceDictionaryLocation _themeDictionaryLocation; private ResourceDictionaryLocation _genericDictionaryLocation; } } // 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
- HeaderUtility.cs
- __TransparentProxy.cs
- TextElement.cs
- IndentTextWriter.cs
- ChannelServices.cs
- HitTestParameters3D.cs
- XmlSerializerSection.cs
- SqlTopReducer.cs
- ObsoleteAttribute.cs
- EncryptedReference.cs
- ShapeTypeface.cs
- Int64AnimationBase.cs
- SR.Designer.cs
- PrimitiveSchema.cs
- ErrorHandler.cs
- WizardDesigner.cs
- AttributeInfo.cs
- SystemResources.cs
- DocumentsTrace.cs
- WebPartTransformerCollection.cs
- TypedReference.cs
- Pen.cs
- CatalogPartCollection.cs
- Vector3DAnimation.cs
- DrawingContext.cs
- XmlUtil.cs
- BitVector32.cs
- ConfigurationValidatorAttribute.cs
- IndexingContentUnit.cs
- ReferenceConverter.cs
- ComboBoxRenderer.cs
- CompilerErrorCollection.cs
- DataFormats.cs
- WindowsAuthenticationEventArgs.cs
- KeyValueConfigurationCollection.cs
- OpCellTreeNode.cs
- BitStream.cs
- NativeMethods.cs
- SubclassTypeValidatorAttribute.cs
- TypeUsageBuilder.cs
- StylusPointCollection.cs
- Int64KeyFrameCollection.cs
- OperationContractAttribute.cs
- HttpHostedTransportConfiguration.cs
- DayRenderEvent.cs
- TextTreeUndoUnit.cs
- SoapConverter.cs
- JournalEntryListConverter.cs
- ConfigXmlText.cs
- SQLStringStorage.cs
- Visual.cs
- DbConnectionOptions.cs
- TreeIterator.cs
- ArithmeticException.cs
- SmtpDigestAuthenticationModule.cs
- DesignerLinkAdapter.cs
- FixedFlowMap.cs
- LinkDescriptor.cs
- GeneralTransformGroup.cs
- ResourceProviderFactory.cs
- XPathScanner.cs
- PenContext.cs
- Wow64ConfigurationLoader.cs
- DebuggerAttributes.cs
- TdsRecordBufferSetter.cs
- util.cs
- DynamicDocumentPaginator.cs
- EDesignUtil.cs
- HandledMouseEvent.cs
- EntityContainerAssociationSetEnd.cs
- CopyOfAction.cs
- versioninfo.cs
- IFlowDocumentViewer.cs
- XmlIncludeAttribute.cs
- StorageRoot.cs
- LocalIdKeyIdentifierClause.cs
- UrlRoutingHandler.cs
- LowerCaseStringConverter.cs
- IssuedTokenServiceElement.cs
- FixedDSBuilder.cs
- SafeCryptContextHandle.cs
- OperationSelectorBehavior.cs
- DataTableNewRowEvent.cs
- PrinterUnitConvert.cs
- RevocationPoint.cs
- CompiledQueryCacheKey.cs
- PolyLineSegment.cs
- PointConverter.cs
- CalendarKeyboardHelper.cs
- FileNameEditor.cs
- EasingFunctionBase.cs
- SqlDataRecord.cs
- ReadOnlyHierarchicalDataSource.cs
- CategoryList.cs
- StdValidatorsAndConverters.cs
- RangeValidator.cs
- TableCellCollection.cs
- DrawListViewItemEventArgs.cs
- HttpPostedFile.cs
- ExtensibleClassFactory.cs