Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / ndp / fx / src / DataWebControlsDesign / System / Data / WebControls / Design / Util / RTLAwareMessageBox.cs / 1 / RTLAwareMessageBox.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //----------------------------------------------------------------------------- using System; using System.Windows.Forms; using System.Design; namespace System.Web.UI.Design.WebControls { ////// internal static class RTLAwareMessageBox { ////// The Show method displays a message box that can contain text, buttons, and symbols that /// inform and instruct the user. This MessageBox will be RTL, if the resources /// for this dll have been localized to a RTL language. /// ////// public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options) { if (RTLAwareMessageBox.IsRTLResources) { options |= (MessageBoxOptions.RightAlign | MessageBoxOptions.RtlReading); } return MessageBox.Show(owner, text, caption, buttons, icon, defaultButton, options); } ////// Displays a message box with specified text, caption, and style. /// Makes the dialog RTL if the resources for this dll have been localized to a RTL language. /// ////// Tells whether the current resources for this dll have been /// localized for a RTL language. /// public static bool IsRTLResources { get { return Strings.RTL != "RTL_False"; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //----------------------------------------------------------------------------- using System; using System.Windows.Forms; using System.Design; namespace System.Web.UI.Design.WebControls { ////// internal static class RTLAwareMessageBox { ////// The Show method displays a message box that can contain text, buttons, and symbols that /// inform and instruct the user. This MessageBox will be RTL, if the resources /// for this dll have been localized to a RTL language. /// ////// public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options) { if (RTLAwareMessageBox.IsRTLResources) { options |= (MessageBoxOptions.RightAlign | MessageBoxOptions.RtlReading); } return MessageBox.Show(owner, text, caption, buttons, icon, defaultButton, options); } ////// Displays a message box with specified text, caption, and style. /// Makes the dialog RTL if the resources for this dll have been localized to a RTL language. /// ////// Tells whether the current resources for this dll have been /// localized for a RTL language. /// public static bool IsRTLResources { get { return Strings.RTL != "RTL_False"; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- CompositeCollectionView.cs
- ActivationArguments.cs
- JournalNavigationScope.cs
- EmptyStringExpandableObjectConverter.cs
- DetailsViewRow.cs
- BuilderPropertyEntry.cs
- CodeVariableReferenceExpression.cs
- ToolstripProfessionalRenderer.cs
- MinimizableAttributeTypeConverter.cs
- ScrollBarRenderer.cs
- CultureMapper.cs
- Parser.cs
- PasswordRecoveryDesigner.cs
- TableRowCollection.cs
- RegexCapture.cs
- EventListener.cs
- SelfIssuedAuthRSACryptoProvider.cs
- BamlResourceSerializer.cs
- PrtCap_Public.cs
- ErrorHandler.cs
- MouseActionConverter.cs
- WmlTextViewAdapter.cs
- UrlPath.cs
- VisualTreeHelper.cs
- SafeBuffer.cs
- MetadataStore.cs
- UriTemplate.cs
- WebPartRestoreVerb.cs
- HttpPostClientProtocol.cs
- SqlConnectionPoolGroupProviderInfo.cs
- TypeTypeConverter.cs
- DependencyObjectType.cs
- WeakReferenceList.cs
- DataObjectMethodAttribute.cs
- EventSourceCreationData.cs
- OdbcConnectionHandle.cs
- MergeLocalizationDirectives.cs
- RootCodeDomSerializer.cs
- UnmanagedMarshal.cs
- QilStrConcat.cs
- ISAPIWorkerRequest.cs
- ProviderCollection.cs
- DataSetSchema.cs
- NullableFloatSumAggregationOperator.cs
- Mutex.cs
- IsolatedStorageFile.cs
- IIS7UserPrincipal.cs
- DefaultObjectMappingItemCollection.cs
- SecurityException.cs
- DataFormats.cs
- StylusSystemGestureEventArgs.cs
- COM2ColorConverter.cs
- SecurityCookieModeValidator.cs
- AuthenticationService.cs
- WriteableBitmap.cs
- SortedList.cs
- ButtonFieldBase.cs
- Menu.cs
- Int16.cs
- TypeDescriptionProviderAttribute.cs
- HttpContext.cs
- DefaultValueAttribute.cs
- HostedElements.cs
- UIPropertyMetadata.cs
- TraceEventCache.cs
- BufferedStream.cs
- JournalEntryListConverter.cs
- InternalRelationshipCollection.cs
- PopOutPanel.cs
- InputScopeConverter.cs
- adornercollection.cs
- DataGridToolTip.cs
- InvalidateEvent.cs
- Accessors.cs
- OleDbConnectionFactory.cs
- SHA384Managed.cs
- ListViewTableCell.cs
- HelpKeywordAttribute.cs
- SafeNativeMethods.cs
- MailMessageEventArgs.cs
- FixedStringLookup.cs
- DataGridDefaultColumnWidthTypeConverter.cs
- SafePEFileHandle.cs
- IsolatedStorageException.cs
- DataSourceView.cs
- DropShadowEffect.cs
- CqlIdentifiers.cs
- input.cs
- ConfigXmlElement.cs
- ProtocolsInstallComponent.cs
- ReturnValue.cs
- AssertSection.cs
- IconBitmapDecoder.cs
- ExecutedRoutedEventArgs.cs
- UnsafeNativeMethods.cs
- WindowsSolidBrush.cs
- LogAppendAsyncResult.cs
- ImageCollectionEditor.cs
- BamlRecordReader.cs
- HttpHandlersSection.cs