Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / 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
- Clause.cs
- XmlSchemaSimpleType.cs
- SspiSecurityToken.cs
- SystemColors.cs
- ObjectDataSourceStatusEventArgs.cs
- Size.cs
- TextSelectionHelper.cs
- DebugView.cs
- QilIterator.cs
- WindowClosedEventArgs.cs
- ActivityExecutorOperation.cs
- SplitterEvent.cs
- Soap.cs
- Geometry3D.cs
- DispatcherEventArgs.cs
- Collection.cs
- StorageMappingItemCollection.cs
- TreeIterators.cs
- GlyphingCache.cs
- ActivityExecutorOperation.cs
- DemultiplexingClientMessageFormatter.cs
- CapacityStreamGeometryContext.cs
- CodeParameterDeclarationExpression.cs
- StringCollection.cs
- NameValueSectionHandler.cs
- NamespaceCollection.cs
- basecomparevalidator.cs
- EncryptedData.cs
- XmlSerializerAssemblyAttribute.cs
- DataControlImageButton.cs
- OleCmdHelper.cs
- Token.cs
- MethodBuilderInstantiation.cs
- SemaphoreSecurity.cs
- XmlDownloadManager.cs
- Opcode.cs
- Activator.cs
- SqlCommand.cs
- ItemChangedEventArgs.cs
- FontSourceCollection.cs
- StorageSetMapping.cs
- HWStack.cs
- PriorityChain.cs
- DirectoryObjectSecurity.cs
- DependencySource.cs
- NameValuePermission.cs
- GroupBoxAutomationPeer.cs
- SplashScreenNativeMethods.cs
- TreeNodeStyle.cs
- StickyNoteContentControl.cs
- XmlMapping.cs
- SmtpDigestAuthenticationModule.cs
- TimeSpanSecondsConverter.cs
- WindowsFormsLinkLabel.cs
- Hash.cs
- EditorResources.cs
- XappLauncher.cs
- OdbcStatementHandle.cs
- MobileDeviceCapabilitiesSectionHandler.cs
- ContractNamespaceAttribute.cs
- CapabilitiesUse.cs
- GlyphRunDrawing.cs
- FastEncoderWindow.cs
- HtmlImage.cs
- RelationshipNavigation.cs
- ContainerActivationHelper.cs
- LinkTarget.cs
- WindowsListViewGroup.cs
- localization.cs
- CorrelationValidator.cs
- ScrollBarAutomationPeer.cs
- DeclaredTypeValidator.cs
- FlowPosition.cs
- BindingCollection.cs
- ColumnTypeConverter.cs
- FullTextLine.cs
- StringExpressionSet.cs
- DynamicResourceExtensionConverter.cs
- FixedSOMFixedBlock.cs
- ExpressionConverter.cs
- TextServicesDisplayAttributePropertyRanges.cs
- OdbcConnectionOpen.cs
- EmptyElement.cs
- SqlInfoMessageEvent.cs
- SettingsBase.cs
- CodeDirectiveCollection.cs
- WmlSelectionListAdapter.cs
- ExpandCollapsePattern.cs
- MissingFieldException.cs
- _NativeSSPI.cs
- InstanceBehavior.cs
- CachedRequestParams.cs
- COM2PropertyBuilderUITypeEditor.cs
- Timer.cs
- RepeaterItemCollection.cs
- RangeBaseAutomationPeer.cs
- XmlSequenceWriter.cs
- SecurityProtocolCorrelationState.cs
- EventNotify.cs
- XmlSchemaImporter.cs