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
- RegularExpressionValidator.cs
- NamedPermissionSet.cs
- WeakHashtable.cs
- Cursor.cs
- DetailsViewCommandEventArgs.cs
- DataGridViewDataConnection.cs
- ApplicationSettingsBase.cs
- SqlBuilder.cs
- Win32KeyboardDevice.cs
- Win32PrintDialog.cs
- HttpDictionary.cs
- ViewManager.cs
- EntityFunctions.cs
- ServiceDescriptions.cs
- TakeQueryOptionExpression.cs
- DesignerFrame.cs
- BindingExpressionUncommonField.cs
- XmlMembersMapping.cs
- CategoriesDocumentFormatter.cs
- Separator.cs
- BaseContextMenu.cs
- ErrorLog.cs
- EncryptedType.cs
- TransformerConfigurationWizardBase.cs
- MgmtConfigurationRecord.cs
- RealProxy.cs
- WebPartMovingEventArgs.cs
- WorkflowOperationBehavior.cs
- XPathNavigator.cs
- VisualStyleRenderer.cs
- BoolExpr.cs
- FixedSOMSemanticBox.cs
- StringUtil.cs
- basenumberconverter.cs
- BufferBuilder.cs
- ApplicationManager.cs
- BindingMAnagerBase.cs
- AnnotationResource.cs
- ASCIIEncoding.cs
- CollectionMarkupSerializer.cs
- DatePickerDateValidationErrorEventArgs.cs
- TemplateKeyConverter.cs
- CodeRegionDirective.cs
- Tile.cs
- TimeZone.cs
- BookmarkTable.cs
- XPathChildIterator.cs
- WindowsFormsDesignerOptionService.cs
- SessionStateUtil.cs
- Freezable.cs
- LOSFormatter.cs
- TemplateKey.cs
- DropTarget.cs
- XmlILCommand.cs
- WorkflowApplicationEventArgs.cs
- AttributeProviderAttribute.cs
- FormatConvertedBitmap.cs
- MailHeaderInfo.cs
- StateRuntime.cs
- SymLanguageVendor.cs
- AsymmetricKeyExchangeDeformatter.cs
- DeclaredTypeElement.cs
- DataGridViewButtonCell.cs
- QilName.cs
- SspiHelper.cs
- ForwardPositionQuery.cs
- SqlInternalConnection.cs
- PolicyLevel.cs
- FormViewInsertEventArgs.cs
- VisualTreeUtils.cs
- SoapExtensionTypeElementCollection.cs
- ObservableDictionary.cs
- TemplateBuilder.cs
- CodePropertyReferenceExpression.cs
- ValueCollectionParameterReader.cs
- TextTreeObjectNode.cs
- Renderer.cs
- _SslStream.cs
- XdrBuilder.cs
- ActivityBindForm.cs
- WindowsNonControl.cs
- DbConnectionOptions.cs
- CollectionBase.cs
- SafeHandle.cs
- HttpHandlersSection.cs
- sortedlist.cs
- ValueProviderWrapper.cs
- DataGridColumnHeaderAutomationPeer.cs
- FixedLineResult.cs
- AppDomainManager.cs
- XmlUtf8RawTextWriter.cs
- DeviceContexts.cs
- AttributeExtensions.cs
- BinaryConverter.cs
- WindowsListViewGroup.cs
- _SpnDictionary.cs
- OdbcConnectionPoolProviderInfo.cs
- ActiveXContainer.cs
- WorkflowQueuingService.cs
- WebPartChrome.cs