Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / 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
- DesignerUtils.cs
- ToolBar.cs
- LayoutSettings.cs
- Converter.cs
- Vector3DValueSerializer.cs
- ExtensionElementCollection.cs
- TreeViewEvent.cs
- Baml2006Reader.cs
- Variant.cs
- Utility.cs
- CreationContext.cs
- MessageQuerySet.cs
- PersonalizableTypeEntry.cs
- HtmlControlPersistable.cs
- GeneralTransformGroup.cs
- SoapSchemaMember.cs
- XmlElement.cs
- RefreshEventArgs.cs
- SmtpTransport.cs
- XmlQualifiedName.cs
- XmlBinaryWriter.cs
- TextProviderWrapper.cs
- While.cs
- ConstraintCollection.cs
- SecurityContext.cs
- unitconverter.cs
- GridViewRowPresenterBase.cs
- CodeObject.cs
- TextTreePropertyUndoUnit.cs
- JsonGlobals.cs
- Bitmap.cs
- ThemeDirectoryCompiler.cs
- NativeRecognizer.cs
- HttpListenerRequestUriBuilder.cs
- ListViewVirtualItemsSelectionRangeChangedEvent.cs
- ServiceBusyException.cs
- PersonalizationEntry.cs
- LineSegment.cs
- AmbientValueAttribute.cs
- TemplateControl.cs
- DataColumnMappingCollection.cs
- OleServicesContext.cs
- Object.cs
- ProtectedUri.cs
- SettingsBase.cs
- CuspData.cs
- XmlSchemas.cs
- XPathAncestorIterator.cs
- ProfileProvider.cs
- DBNull.cs
- XPathChildIterator.cs
- Effect.cs
- KeyValueSerializer.cs
- Stackframe.cs
- CmsInterop.cs
- XsltInput.cs
- XmlRawWriterWrapper.cs
- CommandBinding.cs
- base64Transforms.cs
- SingleResultAttribute.cs
- InternalTypeHelper.cs
- KeyGestureConverter.cs
- InputBinder.cs
- MarshalDirectiveException.cs
- CompoundFileStreamReference.cs
- TcpClientChannel.cs
- Exception.cs
- TextEncodedRawTextWriter.cs
- RegisteredExpandoAttribute.cs
- LineServicesCallbacks.cs
- WmlMobileTextWriter.cs
- SpellerHighlightLayer.cs
- Transform3DGroup.cs
- TdsParserSafeHandles.cs
- Camera.cs
- ArrayTypeMismatchException.cs
- RowsCopiedEventArgs.cs
- ObjectPersistData.cs
- ChtmlTextBoxAdapter.cs
- SingleTagSectionHandler.cs
- QilInvokeLateBound.cs
- ProcessProtocolHandler.cs
- ActivityDelegate.cs
- XmlUtf8RawTextWriter.cs
- OdbcConnectionStringbuilder.cs
- JsonByteArrayDataContract.cs
- shaper.cs
- DataGridViewCellEventArgs.cs
- ProgressChangedEventArgs.cs
- HttpApplication.cs
- AssemblyAttributes.cs
- MD5.cs
- ConditionalAttribute.cs
- ManagementOptions.cs
- regiisutil.cs
- UnsafeNativeMethods.cs
- MethodSignatureGenerator.cs
- JavaScriptSerializer.cs
- EditorPartCollection.cs
- AppearanceEditorPart.cs