Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / UIAutomation / UIAutomationClient / MS / Internal / Automation / WinEventQueueItem.cs / 1 / WinEventQueueItem.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: Class to create a queue on its own thread. // // History: // 06/17/2003 : BrendanM Ported to WCP // //--------------------------------------------------------------------------- using System.Windows.Automation; using System.Windows.Automation.Provider; using System; using System.Threading; using System.Collections; using MS.Internal.Automation; using MS.Win32; namespace MS.Internal.Automation { // Worker class used to handle WinEvents internal class WinEventQueueItem : QueueItem { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal WinEventQueueItem(WinEventWrap winEventWrap, int state) { _winEventWrap = winEventWrap; _state = state; } #endregion Constructors //------------------------------------------------------ // // Public Constants / Readonly Fields // //----------------------------------------------------- #region Public Constants and Readonly Fields internal const int StartListening = 1; internal const int StopListening = 2; #endregion Public Constants and Readonly Fields //------------------------------------------------------ // // Internal Methods // //------------------------------------------------------ #region Internal Methods internal override void Process() { if (_state == StartListening) { _winEventWrap.StartListening(); } else { _winEventWrap.StopListening(); } } #endregion Internal Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private WinEventWrap _winEventWrap; private int _state; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: Class to create a queue on its own thread. // // History: // 06/17/2003 : BrendanM Ported to WCP // //--------------------------------------------------------------------------- using System.Windows.Automation; using System.Windows.Automation.Provider; using System; using System.Threading; using System.Collections; using MS.Internal.Automation; using MS.Win32; namespace MS.Internal.Automation { // Worker class used to handle WinEvents internal class WinEventQueueItem : QueueItem { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal WinEventQueueItem(WinEventWrap winEventWrap, int state) { _winEventWrap = winEventWrap; _state = state; } #endregion Constructors //------------------------------------------------------ // // Public Constants / Readonly Fields // //----------------------------------------------------- #region Public Constants and Readonly Fields internal const int StartListening = 1; internal const int StopListening = 2; #endregion Public Constants and Readonly Fields //------------------------------------------------------ // // Internal Methods // //------------------------------------------------------ #region Internal Methods internal override void Process() { if (_state == StartListening) { _winEventWrap.StartListening(); } else { _winEventWrap.StopListening(); } } #endregion Internal Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private WinEventWrap _winEventWrap; private int _state; #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
- VirtualizedContainerService.cs
- TextTreeText.cs
- FaultPropagationQuery.cs
- DriveInfo.cs
- WebRequest.cs
- EntityDataSourceSelectingEventArgs.cs
- MailWriter.cs
- SmiTypedGetterSetter.cs
- TextOutput.cs
- TextEditorSpelling.cs
- ReturnValue.cs
- UnionExpr.cs
- IItemContainerGenerator.cs
- DataComponentMethodGenerator.cs
- RemoteArgument.cs
- ExtenderProviderService.cs
- KnownTypeHelper.cs
- Queue.cs
- WebDisplayNameAttribute.cs
- GeometryDrawing.cs
- IODescriptionAttribute.cs
- ConnectionsZone.cs
- BinaryMessageEncoder.cs
- ConfigurationManagerInternal.cs
- AsyncStreamReader.cs
- TextEndOfLine.cs
- DefaultEventAttribute.cs
- CellLabel.cs
- DataGridViewColumnCollection.cs
- LogEntryUtils.cs
- TCPClient.cs
- IgnoreSectionHandler.cs
- CreateParams.cs
- FixedSOMTable.cs
- SecurityTokenResolver.cs
- PhoneCallDesigner.cs
- Activator.cs
- RegexStringValidator.cs
- AppearanceEditorPart.cs
- ClientConfigurationHost.cs
- ServiceEndpointElementCollection.cs
- HttpClientCertificate.cs
- HttpHeaderCollection.cs
- Semaphore.cs
- XmlSchemaException.cs
- FixedSOMTableRow.cs
- TypedElement.cs
- MarginsConverter.cs
- TextFormatterHost.cs
- LicenseContext.cs
- TypeGeneratedEventArgs.cs
- ClassHandlersStore.cs
- SQLMoneyStorage.cs
- HwndKeyboardInputProvider.cs
- CopyNamespacesAction.cs
- TableProviderWrapper.cs
- ParameterCollection.cs
- XmlSchemaSet.cs
- DbProviderFactories.cs
- Qualifier.cs
- DataRelationCollection.cs
- OleDbParameter.cs
- DataServiceClientException.cs
- InvalidEnumArgumentException.cs
- OracleDataAdapter.cs
- WebColorConverter.cs
- XmlSchemaProviderAttribute.cs
- EditorPart.cs
- HttpCacheVaryByContentEncodings.cs
- ClientProxyGenerator.cs
- VariantWrapper.cs
- TemplateComponentConnector.cs
- NavigationPropertySingletonExpression.cs
- SynchronousChannel.cs
- loginstatus.cs
- dtdvalidator.cs
- _CookieModule.cs
- AuthenticationModuleElementCollection.cs
- EntityTypeEmitter.cs
- TextContainerChangedEventArgs.cs
- RequestCacheValidator.cs
- SspiWrapper.cs
- IntSecurity.cs
- DataListCommandEventArgs.cs
- PrincipalPermission.cs
- SimpleMailWebEventProvider.cs
- ReadOnlyDataSourceView.cs
- GatewayDefinition.cs
- BindValidationContext.cs
- ExpressionDumper.cs
- InternalControlCollection.cs
- Operators.cs
- CacheAxisQuery.cs
- ImpersonationContext.cs
- ReadOnlyDataSourceView.cs
- SHA384.cs
- Misc.cs
- XpsInterleavingPolicy.cs
- SelfIssuedSamlTokenFactory.cs
- DataServiceQueryException.cs