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
- DPTypeDescriptorContext.cs
- ComponentDispatcherThread.cs
- RightsManagementEncryptedStream.cs
- DiscoveryInnerClientAdhoc11.cs
- Sql8ExpressionRewriter.cs
- LeftCellWrapper.cs
- CommandValueSerializer.cs
- PassportAuthenticationEventArgs.cs
- AccessViolationException.cs
- Base64Decoder.cs
- IconConverter.cs
- LinqToSqlWrapper.cs
- ExceptionUtil.cs
- TableCell.cs
- wmiutil.cs
- MethodBody.cs
- MarshalDirectiveException.cs
- SoapCodeExporter.cs
- ServiceDescription.cs
- HtmlTernaryTree.cs
- SoapEnumAttribute.cs
- XhtmlBasicSelectionListAdapter.cs
- TextEditor.cs
- SuppressMessageAttribute.cs
- EntityConnectionStringBuilderItem.cs
- UnlockInstanceAsyncResult.cs
- ExpressionConverter.cs
- AttachedPropertyMethodSelector.cs
- Soap.cs
- RbTree.cs
- CryptoApi.cs
- SpeechEvent.cs
- SQLInt64Storage.cs
- Brushes.cs
- UidManager.cs
- HtmlInputText.cs
- WindowsSecurityToken.cs
- DataGridViewImageCell.cs
- Convert.cs
- AutomationInteropProvider.cs
- MulticastDelegate.cs
- ContainerParagraph.cs
- ExtendedPropertyDescriptor.cs
- FontStretches.cs
- SubstitutionResponseElement.cs
- ProjectionPath.cs
- TreeViewItem.cs
- PageCatalogPart.cs
- Misc.cs
- RectangleGeometry.cs
- XpsSerializerFactory.cs
- Vars.cs
- ObjectDataSourceMethodEventArgs.cs
- Popup.cs
- BaseInfoTable.cs
- DataViewSetting.cs
- ComponentCollection.cs
- TabControlEvent.cs
- SafeSystemMetrics.cs
- CompiledRegexRunnerFactory.cs
- InputLanguageEventArgs.cs
- InstallHelper.cs
- MdImport.cs
- Ipv6Element.cs
- SpotLight.cs
- Italic.cs
- TextBoxAutoCompleteSourceConverter.cs
- TypeDependencyAttribute.cs
- ModelPerspective.cs
- ValueOfAction.cs
- CfgParser.cs
- DocumentOrderQuery.cs
- KnownTypeHelper.cs
- ListBoxItemAutomationPeer.cs
- DockProviderWrapper.cs
- MarkupCompilePass2.cs
- HwndMouseInputProvider.cs
- NodeLabelEditEvent.cs
- SortedList.cs
- SecurityUniqueId.cs
- RequestCachePolicyConverter.cs
- UnsupportedPolicyOptionsException.cs
- IntSecurity.cs
- Soap.cs
- AsyncOperation.cs
- ProfileBuildProvider.cs
- SelectionEditingBehavior.cs
- StorageComplexTypeMapping.cs
- EpmContentSerializer.cs
- EventKeyword.cs
- TemporaryBitmapFile.cs
- ProgressChangedEventArgs.cs
- FrameworkPropertyMetadata.cs
- StorageSetMapping.cs
- SerTrace.cs
- ColorAnimationBase.cs
- RegexBoyerMoore.cs
- MappingSource.cs
- DataConnectionHelper.cs
- XmlSchemaAttributeGroup.cs