Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Framework / System / Windows / ThemeInfoAttribute.cs / 1 / 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
- IList.cs
- SqlRecordBuffer.cs
- FlowSwitch.cs
- _WebProxyDataBuilder.cs
- xamlnodes.cs
- ResolvePPIDRequest.cs
- SingleStorage.cs
- ToolStripKeyboardHandlingService.cs
- Parsers.cs
- ComAdminInterfaces.cs
- InstanceLockQueryResult.cs
- NetNamedPipeSecurityElement.cs
- DispatcherHookEventArgs.cs
- DetailsViewPagerRow.cs
- InplaceBitmapMetadataWriter.cs
- FixedSOMContainer.cs
- FileDataSourceCache.cs
- ByteAnimationUsingKeyFrames.cs
- ResourceReferenceKeyNotFoundException.cs
- NamespaceCollection.cs
- HttpsHostedTransportConfiguration.cs
- AutomationElement.cs
- AutomationFocusChangedEventArgs.cs
- AutoSizeComboBox.cs
- MouseBinding.cs
- HttpCapabilitiesBase.cs
- WebBrowserNavigatedEventHandler.cs
- ScalarOps.cs
- SubpageParagraph.cs
- PersonalizationState.cs
- xdrvalidator.cs
- StringAnimationUsingKeyFrames.cs
- TextParagraphProperties.cs
- ServiceModelConfigurationSection.cs
- HttpException.cs
- MembershipValidatePasswordEventArgs.cs
- WaitHandleCannotBeOpenedException.cs
- ColumnBinding.cs
- SwitchCase.cs
- IntPtr.cs
- FlowLayoutSettings.cs
- SessionEndingEventArgs.cs
- OleDbCommandBuilder.cs
- COM2ExtendedBrowsingHandler.cs
- TextChangedEventArgs.cs
- EntityDataSourceEntitySetNameItem.cs
- HitTestResult.cs
- GCHandleCookieTable.cs
- ResourceManager.cs
- SystemIPv4InterfaceProperties.cs
- Logging.cs
- GPPOINT.cs
- DocumentGridPage.cs
- ConfigXmlAttribute.cs
- Glyph.cs
- GridViewColumn.cs
- DrawingAttributeSerializer.cs
- _OSSOCK.cs
- NTAccount.cs
- ArgumentNullException.cs
- ValueUtilsSmi.cs
- WindowsProgressbar.cs
- InputBuffer.cs
- _LocalDataStore.cs
- SoapAttributes.cs
- ExternalDataExchangeService.cs
- JournalNavigationScope.cs
- HwndHost.cs
- UpdateExpressionVisitor.cs
- StrokeNodeEnumerator.cs
- _StreamFramer.cs
- PolyLineSegment.cs
- RemotingServices.cs
- EditingCoordinator.cs
- AstNode.cs
- ByteAnimationBase.cs
- RegexReplacement.cs
- EngineSite.cs
- StateManagedCollection.cs
- VectorValueSerializer.cs
- COM2ExtendedBrowsingHandler.cs
- RecognizedWordUnit.cs
- PersonalizationProvider.cs
- Utils.cs
- DictionarySectionHandler.cs
- ServiceManagerHandle.cs
- ItemType.cs
- UserNameSecurityTokenAuthenticator.cs
- GatewayDefinition.cs
- OperandQuery.cs
- FunctionImportElement.cs
- XmlLanguageConverter.cs
- Inline.cs
- Environment.cs
- StringArrayConverter.cs
- DataSpaceManager.cs
- PolygonHotSpot.cs
- DirectoryNotFoundException.cs
- RegexGroupCollection.cs
- EmulateRecognizeCompletedEventArgs.cs