Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Themes / Shared / Microsoft / Windows / Themes / PlatformCulture.cs / 1305600 / PlatformCulture.cs
//----------------------------------------------------------------------------
// File: CurrentWPFCulture.cs
//
// Description:
// Helper class that allows access to localized values based on the current WPF culture.
//
// Copyright (C) 2006 by Microsoft Corporation. All rights reserved.
//
//---------------------------------------------------------------------------
using System.Diagnostics;
using System.Globalization;
using System.Windows;
using System;
namespace Microsoft.Windows.Themes
{
///
/// Public class used to expose some properties of the culture
/// the platform is localized to.
///
public static class PlatformCulture
{
///
/// FlowDirection of the culture the platform is localized to.
///
public static FlowDirection FlowDirection
{
get
{
if (_platformCulture == null)
{
_platformCulture = MS.Internal.PlatformCulture.Value;
}
Debug.Assert(_platformCulture != null);
return _platformCulture.TextInfo.IsRightToLeft ? FlowDirection.RightToLeft : FlowDirection.LeftToRight;
}
}
private static CultureInfo _platformCulture;
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
//----------------------------------------------------------------------------
// File: CurrentWPFCulture.cs
//
// Description:
// Helper class that allows access to localized values based on the current WPF culture.
//
// Copyright (C) 2006 by Microsoft Corporation. All rights reserved.
//
//---------------------------------------------------------------------------
using System.Diagnostics;
using System.Globalization;
using System.Windows;
using System;
namespace Microsoft.Windows.Themes
{
///
/// Public class used to expose some properties of the culture
/// the platform is localized to.
///
public static class PlatformCulture
{
///
/// FlowDirection of the culture the platform is localized to.
///
public static FlowDirection FlowDirection
{
get
{
if (_platformCulture == null)
{
_platformCulture = MS.Internal.PlatformCulture.Value;
}
Debug.Assert(_platformCulture != null);
return _platformCulture.TextInfo.IsRightToLeft ? FlowDirection.RightToLeft : FlowDirection.LeftToRight;
}
}
private static CultureInfo _platformCulture;
}
}
// 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
- _ShellExpression.cs
- Quaternion.cs
- BasicExpressionVisitor.cs
- EastAsianLunisolarCalendar.cs
- ViewManager.cs
- LocalClientSecuritySettingsElement.cs
- BitmapImage.cs
- PeerConnector.cs
- CompositionAdorner.cs
- InheritablePropertyChangeInfo.cs
- ManagementObject.cs
- Attributes.cs
- StatusBarAutomationPeer.cs
- ResXResourceSet.cs
- NativeMethods.cs
- Label.cs
- M3DUtil.cs
- PerfCounterSection.cs
- LazyInitializer.cs
- LocatorPartList.cs
- EncryptedPackageFilter.cs
- SyndicationDeserializer.cs
- GenericEnumerator.cs
- SimpleWebHandlerParser.cs
- ISCIIEncoding.cs
- CustomValidator.cs
- ColumnMapTranslator.cs
- HttpException.cs
- CollaborationHelperFunctions.cs
- DataGridRelationshipRow.cs
- SizeAnimation.cs
- GridViewItemAutomationPeer.cs
- WebPartMinimizeVerb.cs
- PenLineCapValidation.cs
- ColumnHeaderConverter.cs
- UmAlQuraCalendar.cs
- UIElementHelper.cs
- HtmlToClrEventProxy.cs
- printdlgexmarshaler.cs
- GroupQuery.cs
- SchemaTableColumn.cs
- RequestCacheEntry.cs
- LZCodec.cs
- BitHelper.cs
- HtmlEncodedRawTextWriter.cs
- hresults.cs
- TraceContextEventArgs.cs
- FixedSOMTable.cs
- ListViewDataItem.cs
- UIElementParaClient.cs
- Html32TextWriter.cs
- RelationshipDetailsCollection.cs
- DataPointer.cs
- AppAction.cs
- Fx.cs
- WebChannelFactory.cs
- RangeValidator.cs
- Random.cs
- NegotiateStream.cs
- ConfigurationSectionCollection.cs
- XsltException.cs
- ProfileSettingsCollection.cs
- CurrentChangingEventArgs.cs
- DataGridViewDataConnection.cs
- QuaternionKeyFrameCollection.cs
- SqlBulkCopy.cs
- DoubleAnimationBase.cs
- WindowPatternIdentifiers.cs
- VirtualPathUtility.cs
- XmlWrappingReader.cs
- WSFederationHttpSecurityElement.cs
- ResourceReferenceExpression.cs
- WebPartDisplayModeEventArgs.cs
- SQLDecimalStorage.cs
- Separator.cs
- glyphs.cs
- StateMachineSubscription.cs
- AccessibleObject.cs
- WebOperationContext.cs
- ToolboxItemCollection.cs
- CollectionTypeElement.cs
- ErrorWrapper.cs
- DataObject.cs
- CommandID.cs
- DeploymentSection.cs
- BitStack.cs
- Control.cs
- ThreadExceptionDialog.cs
- DataGridItemCollection.cs
- DecoderFallback.cs
- DoubleLinkListEnumerator.cs
- PingReply.cs
- ApplicationFileCodeDomTreeGenerator.cs
- DropShadowEffect.cs
- FileSystemInfo.cs
- ReflectEventDescriptor.cs
- ArgumentFixer.cs
- LoginView.cs
- DataSourceComponent.cs
- TableAutomationPeer.cs