Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Core / CSharp / System / Windows / Input / InputLanguageEventArgs.cs / 1 / InputLanguageEventArgs.cs
using System; using System.Collections; using System.Windows.Threading; using System.Windows; using System.Globalization; namespace System.Windows.Input { ////// The InputLanguageEventArgs class represents a type of /// RoutedEventArgs that are relevant to events raised to indicate /// changes. /// public abstract class InputLanguageEventArgs : EventArgs { //------------------------------------------------------ // // Constructors // //----------------------------------------------------- ////// Constructs an instance of the InputLanguageEventArgs class. /// /// /// The new language id. /// /// /// The previous language id. /// protected InputLanguageEventArgs(CultureInfo newLanguageId, CultureInfo previousLanguageId) { _newLanguageId = newLanguageId; _previousLanguageId = previousLanguageId; } //----------------------------------------------------- // // Public Properties // //----------------------------------------------------- ////// New Language Id. /// public virtual CultureInfo NewLanguage { get { return _newLanguageId; } } ////// Previous Language Id. /// public virtual CultureInfo PreviousLanguage { get { return _previousLanguageId; } } //------------------------------------------------------ // // Private Fields // //----------------------------------------------------- #region Private Fields // the new input language. private CultureInfo _newLanguageId; // the previous input language. private CultureInfo _previousLanguageId; #endregion Private Fields } ////// The InputLanguageEventArgs class represents a type of /// RoutedEventArgs that are relevant to events raised to indicate /// changes. /// public class InputLanguageChangedEventArgs : InputLanguageEventArgs { //------------------------------------------------------ // // Constructors // //------------------------------------------------------ ////// Constructs an instance of the InputLanguageEventArgs class. /// /// /// The new language id. /// /// /// The new language id. /// public InputLanguageChangedEventArgs(CultureInfo newLanguageId, CultureInfo previousLanguageId) : base(newLanguageId, previousLanguageId) { } } ////// The InputLanguageEventArgs class represents a type of /// RoutedEventArgs that are relevant to events raised to indicate /// changes. /// ///public class InputLanguageChangingEventArgs : InputLanguageEventArgs { //----------------------------------------------------- // // Constructors // //------------------------------------------------------ /// /// Constructs an instance of the InputLanguageEventArgs class. /// /// /// The new language id. /// /// /// The previous language id. /// public InputLanguageChangingEventArgs(CultureInfo newLanguageId, CultureInfo previousLanguageId) : base(newLanguageId, previousLanguageId) { _rejected = false; } //----------------------------------------------------- // // Public Properties // //----------------------------------------------------- ////// This is a value to reject the input language change. /// public bool Rejected { get { return _rejected; } set { _rejected = value; } } //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields // bool to reject the input language change. private bool _rejected; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Collections; using System.Windows.Threading; using System.Windows; using System.Globalization; namespace System.Windows.Input { ////// The InputLanguageEventArgs class represents a type of /// RoutedEventArgs that are relevant to events raised to indicate /// changes. /// public abstract class InputLanguageEventArgs : EventArgs { //------------------------------------------------------ // // Constructors // //----------------------------------------------------- ////// Constructs an instance of the InputLanguageEventArgs class. /// /// /// The new language id. /// /// /// The previous language id. /// protected InputLanguageEventArgs(CultureInfo newLanguageId, CultureInfo previousLanguageId) { _newLanguageId = newLanguageId; _previousLanguageId = previousLanguageId; } //----------------------------------------------------- // // Public Properties // //----------------------------------------------------- ////// New Language Id. /// public virtual CultureInfo NewLanguage { get { return _newLanguageId; } } ////// Previous Language Id. /// public virtual CultureInfo PreviousLanguage { get { return _previousLanguageId; } } //------------------------------------------------------ // // Private Fields // //----------------------------------------------------- #region Private Fields // the new input language. private CultureInfo _newLanguageId; // the previous input language. private CultureInfo _previousLanguageId; #endregion Private Fields } ////// The InputLanguageEventArgs class represents a type of /// RoutedEventArgs that are relevant to events raised to indicate /// changes. /// public class InputLanguageChangedEventArgs : InputLanguageEventArgs { //------------------------------------------------------ // // Constructors // //------------------------------------------------------ ////// Constructs an instance of the InputLanguageEventArgs class. /// /// /// The new language id. /// /// /// The new language id. /// public InputLanguageChangedEventArgs(CultureInfo newLanguageId, CultureInfo previousLanguageId) : base(newLanguageId, previousLanguageId) { } } ////// The InputLanguageEventArgs class represents a type of /// RoutedEventArgs that are relevant to events raised to indicate /// changes. /// ///public class InputLanguageChangingEventArgs : InputLanguageEventArgs { //----------------------------------------------------- // // Constructors // //------------------------------------------------------ /// /// Constructs an instance of the InputLanguageEventArgs class. /// /// /// The new language id. /// /// /// The previous language id. /// public InputLanguageChangingEventArgs(CultureInfo newLanguageId, CultureInfo previousLanguageId) : base(newLanguageId, previousLanguageId) { _rejected = false; } //----------------------------------------------------- // // Public Properties // //----------------------------------------------------- ////// This is a value to reject the input language change. /// public bool Rejected { get { return _rejected; } set { _rejected = value; } } //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields // bool to reject the input language change. private bool _rejected; #endregion Private Fields } } // 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
- OrderPreservingSpoolingTask.cs
- RSAPKCS1KeyExchangeDeformatter.cs
- TemplateParser.cs
- SHA256CryptoServiceProvider.cs
- XmlWellformedWriter.cs
- ObjectItemCachedAssemblyLoader.cs
- LineServicesCallbacks.cs
- SamlConditions.cs
- DispatcherFrame.cs
- WebSysDisplayNameAttribute.cs
- WebPartAuthorizationEventArgs.cs
- Constraint.cs
- PreviewControlDesigner.cs
- FixedBufferAttribute.cs
- DataServiceContext.cs
- ToolZone.cs
- WebBrowser.cs
- QueryPrefixOp.cs
- BindingsCollection.cs
- XPathException.cs
- NativeObjectSecurity.cs
- COAUTHIDENTITY.cs
- ExcCanonicalXml.cs
- DocumentViewerBaseAutomationPeer.cs
- CodeTypeReferenceCollection.cs
- wgx_exports.cs
- WindowsTokenRoleProvider.cs
- DataSourceHelper.cs
- DeflateStreamAsyncResult.cs
- WebServiceData.cs
- DbConnectionOptions.cs
- TogglePattern.cs
- ResourceDescriptionAttribute.cs
- InputBinding.cs
- BamlTreeNode.cs
- xamlnodes.cs
- CompareValidator.cs
- BaseTemplateCodeDomTreeGenerator.cs
- PositiveTimeSpanValidator.cs
- CodeGen.cs
- ConnectivityStatus.cs
- DirectoryNotFoundException.cs
- GorillaCodec.cs
- EntityContainerAssociationSetEnd.cs
- SdlChannelSink.cs
- SqlXml.cs
- PointAnimationBase.cs
- MultitargetingHelpers.cs
- ScriptReferenceEventArgs.cs
- DataGridViewColumnConverter.cs
- DecimalConstantAttribute.cs
- SelectionList.cs
- NameService.cs
- WebHttpDispatchOperationSelectorData.cs
- WebSysDescriptionAttribute.cs
- ToolStripArrowRenderEventArgs.cs
- XmlHierarchicalEnumerable.cs
- SmiRequestExecutor.cs
- FileChangesMonitor.cs
- UpdateCompiler.cs
- CngKeyBlobFormat.cs
- TagMapCollection.cs
- EnumerableRowCollection.cs
- ResourceDefaultValueAttribute.cs
- DebugInfo.cs
- ListenerElementsCollection.cs
- METAHEADER.cs
- BindableTemplateBuilder.cs
- PeerEndPoint.cs
- SQLGuid.cs
- DataGridViewSelectedRowCollection.cs
- HttpResponse.cs
- CodeFieldReferenceExpression.cs
- SiteMapNodeItem.cs
- X509ChainPolicy.cs
- ValidationRuleCollection.cs
- RayHitTestParameters.cs
- SoapHttpTransportImporter.cs
- GZipStream.cs
- Journaling.cs
- invalidudtexception.cs
- IPGlobalProperties.cs
- XamlTemplateSerializer.cs
- HttpCacheVaryByContentEncodings.cs
- NCryptNative.cs
- TextWriter.cs
- StylusPointPropertyUnit.cs
- ScrollItemPatternIdentifiers.cs
- SocketInformation.cs
- CompileLiteralTextParser.cs
- BitSet.cs
- CodeMethodReturnStatement.cs
- UserNamePasswordServiceCredential.cs
- dataSvcMapFileLoader.cs
- Triplet.cs
- ResourcesBuildProvider.cs
- XmlDocumentSurrogate.cs
- ListViewInsertedEventArgs.cs
- CryptographicAttribute.cs
- PathGeometry.cs