Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / 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
- TraceContextEventArgs.cs
- AddInEnvironment.cs
- odbcmetadatafactory.cs
- ExpressionParser.cs
- DataControlFieldCollection.cs
- StaticContext.cs
- CertificateReferenceElement.cs
- PathData.cs
- SynchronizedMessageSource.cs
- LassoHelper.cs
- WebBrowserBase.cs
- WebConvert.cs
- ExplicitDiscriminatorMap.cs
- MTConfigUtil.cs
- XamlInt32CollectionSerializer.cs
- EpmContentDeSerializerBase.cs
- DnsEndPoint.cs
- HtmlHistory.cs
- StringValueConverter.cs
- FramingEncoders.cs
- BaseParser.cs
- AliasGenerator.cs
- AsyncCompletedEventArgs.cs
- PointCollection.cs
- unsafenativemethodstextservices.cs
- TabControlCancelEvent.cs
- SqlConnectionPoolGroupProviderInfo.cs
- ObjectViewEntityCollectionData.cs
- InertiaExpansionBehavior.cs
- PeerNameRegistration.cs
- BufferAllocator.cs
- CodeConstructor.cs
- TreeNode.cs
- X509ChainElement.cs
- WebPartTransformerCollection.cs
- UserPersonalizationStateInfo.cs
- CodeSubDirectory.cs
- UnaryNode.cs
- dbenumerator.cs
- CounterSampleCalculator.cs
- Brush.cs
- EmptyEnumerator.cs
- MenuItem.cs
- Misc.cs
- GlyphRun.cs
- LocatorGroup.cs
- FamilyMapCollection.cs
- WCFModelStrings.Designer.cs
- MemoryPressure.cs
- PackUriHelper.cs
- BindingCollection.cs
- FileSecurity.cs
- SecurityState.cs
- SQLDoubleStorage.cs
- DependencyPropertyChangedEventArgs.cs
- RegexCompiler.cs
- Label.cs
- BitmapFrameEncode.cs
- RoutedCommand.cs
- UTF8Encoding.cs
- FileNameEditor.cs
- UniformGrid.cs
- GlyphingCache.cs
- Vector.cs
- BinaryKeyIdentifierClause.cs
- ActivityDesignerAccessibleObject.cs
- WebBaseEventKeyComparer.cs
- ZipIOExtraFieldZip64Element.cs
- PermissionSet.cs
- PointCollection.cs
- MessageQueuePermission.cs
- FocusWithinProperty.cs
- DrawingBrush.cs
- InternalConfigRoot.cs
- TranslateTransform3D.cs
- MethodExpression.cs
- TransformationRules.cs
- MethodImplAttribute.cs
- MonthCalendar.cs
- XpsDigitalSignature.cs
- SQLMoney.cs
- SafeProcessHandle.cs
- TrustLevelCollection.cs
- SortableBindingList.cs
- MenuItem.cs
- LicenseException.cs
- AuditLog.cs
- GifBitmapDecoder.cs
- IndicCharClassifier.cs
- TopClause.cs
- BadImageFormatException.cs
- ContextQuery.cs
- ProgressBarHighlightConverter.cs
- IisTraceWebEventProvider.cs
- ProxyAssemblyNotLoadedException.cs
- ConfigsHelper.cs
- XPathPatternParser.cs
- StatusBarPanelClickEvent.cs
- VersionUtil.cs
- SecurityException.cs