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
- CssTextWriter.cs
- XmlSchemaResource.cs
- FacetDescription.cs
- Hex.cs
- DataGridViewCellParsingEventArgs.cs
- DelegateSerializationHolder.cs
- httpapplicationstate.cs
- WindowsListView.cs
- ObjectViewListener.cs
- EntityDataSourceValidationException.cs
- NextPreviousPagerField.cs
- SuspendDesigner.cs
- Button.cs
- __TransparentProxy.cs
- ObjectSet.cs
- NamedPipeHostedTransportConfiguration.cs
- ObjectDesignerDataSourceView.cs
- ContentElementAutomationPeer.cs
- NetNamedPipeSecurityElement.cs
- PropertyGeneratedEventArgs.cs
- NetworkInformationException.cs
- XMLSchema.cs
- State.cs
- WebControlsSection.cs
- EffectiveValueEntry.cs
- MimePart.cs
- ArgumentException.cs
- BufferedWebEventProvider.cs
- DataSourceHelper.cs
- ReadOnlyHierarchicalDataSourceView.cs
- ServiceObjectContainer.cs
- OdbcException.cs
- TableChangeProcessor.cs
- WindowsListViewSubItem.cs
- PenContexts.cs
- ObjectParameter.cs
- SecureStringHasher.cs
- DataPager.cs
- DataGridAutoFormat.cs
- HandlerMappingMemo.cs
- QueryOutputWriter.cs
- TextBoxAutoCompleteSourceConverter.cs
- TreeNode.cs
- CompilationUtil.cs
- WpfPayload.cs
- HashCodeCombiner.cs
- ListControlStringCollectionEditor.cs
- SimpleTextLine.cs
- ModifierKeysConverter.cs
- VersionValidator.cs
- KeyConstraint.cs
- TcpHostedTransportConfiguration.cs
- OpacityConverter.cs
- EncryptRequest.cs
- TableLayoutPanelCellPosition.cs
- GACIdentityPermission.cs
- RangeValueProviderWrapper.cs
- ComMethodElement.cs
- ImageField.cs
- DesignerTransactionCloseEvent.cs
- AspProxy.cs
- BridgeDataReader.cs
- QueryAccessibilityHelpEvent.cs
- SqlMultiplexer.cs
- IUnknownConstantAttribute.cs
- TextElementEditingBehaviorAttribute.cs
- PointCollectionValueSerializer.cs
- CursorConverter.cs
- Rotation3D.cs
- PenThread.cs
- ObjectRef.cs
- BoolLiteral.cs
- PackageFilter.cs
- CodeSnippetStatement.cs
- GeometryHitTestParameters.cs
- EntityTypeEmitter.cs
- PersonalizationEntry.cs
- XmlBindingWorker.cs
- Decorator.cs
- XsltFunctions.cs
- _SSPIWrapper.cs
- ConnectionStringSettings.cs
- CallTemplateAction.cs
- RepeaterItemEventArgs.cs
- X500Name.cs
- ObjRef.cs
- DataViewManager.cs
- ProviderConnectionPointCollection.cs
- UnsafeNativeMethods.cs
- SlipBehavior.cs
- DiscriminatorMap.cs
- _TransmitFileOverlappedAsyncResult.cs
- FilteredSchemaElementLookUpTable.cs
- WriteTimeStream.cs
- CompilationLock.cs
- TypeRestriction.cs
- WebScriptClientGenerator.cs
- SkinBuilder.cs
- RadioButton.cs
- ProfileEventArgs.cs