Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / UIAutomation / UIAutomationClient / MS / Internal / Automation / ClientSideQueueItem.cs / 1 / ClientSideQueueItem.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.Collections; using System.ComponentModel; using MS.Internal.Automation; using MS.Win32; namespace MS.Internal.Automation { // Worker class used to queue events that originated on the client side (e.g. // used by focus and top-level window tracking to queue WinEvent information). internal class ClientSideQueueItem : QueueItem { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal ClientSideQueueItem(Delegate clientCallback, AutomationElement srcEl, UiaCoreApi.UiaCacheRequest request, AutomationEventArgs e) { _clientCallback = clientCallback; _srcEl = srcEl; _request = request; _e = e; } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods internal override void Process() { // Grab properties for cache request here... AutomationElement src; if (_srcEl == null) { src = null; } else { UiaCoreApi.UiaCacheResponse response = UiaCoreApi.UiaGetUpdatedCache(_srcEl.RawNode, _request, UiaCoreApi.NormalizeState.View, null); src = CacheHelper.BuildAutomationElementsFromResponse(_request, response); } // if (!(src == null && _e.EventId == AutomationElement.AutomationFocusChangedEvent)) InvokeHandlers.InvokeClientHandler(_clientCallback, src, _e); } #endregion Internal Methods //------------------------------------------------------ // // Private Fields // //------------------------------------------------------ #region Private Fields private Delegate _clientCallback; // a client callback delegate private AutomationElement _srcEl; // the source element private UiaCoreApi.UiaCacheRequest _request; // shopping list for prefetch private AutomationEventArgs _e; // the event args for the callback #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.Collections; using System.ComponentModel; using MS.Internal.Automation; using MS.Win32; namespace MS.Internal.Automation { // Worker class used to queue events that originated on the client side (e.g. // used by focus and top-level window tracking to queue WinEvent information). internal class ClientSideQueueItem : QueueItem { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal ClientSideQueueItem(Delegate clientCallback, AutomationElement srcEl, UiaCoreApi.UiaCacheRequest request, AutomationEventArgs e) { _clientCallback = clientCallback; _srcEl = srcEl; _request = request; _e = e; } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods internal override void Process() { // Grab properties for cache request here... AutomationElement src; if (_srcEl == null) { src = null; } else { UiaCoreApi.UiaCacheResponse response = UiaCoreApi.UiaGetUpdatedCache(_srcEl.RawNode, _request, UiaCoreApi.NormalizeState.View, null); src = CacheHelper.BuildAutomationElementsFromResponse(_request, response); } // if (!(src == null && _e.EventId == AutomationElement.AutomationFocusChangedEvent)) InvokeHandlers.InvokeClientHandler(_clientCallback, src, _e); } #endregion Internal Methods //------------------------------------------------------ // // Private Fields // //------------------------------------------------------ #region Private Fields private Delegate _clientCallback; // a client callback delegate private AutomationElement _srcEl; // the source element private UiaCoreApi.UiaCacheRequest _request; // shopping list for prefetch private AutomationEventArgs _e; // the event args for the callback #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
- ReferencedType.cs
- CriticalFinalizerObject.cs
- BitmapEffectDrawingContent.cs
- CqlWriter.cs
- MobileDeviceCapabilitiesSectionHandler.cs
- DataViewManager.cs
- StreamHelper.cs
- TargetParameterCountException.cs
- LogReservationCollection.cs
- CompilerInfo.cs
- DeferredReference.cs
- BrowserInteropHelper.cs
- Bidi.cs
- ACL.cs
- CollectionCodeDomSerializer.cs
- NumberSubstitution.cs
- FragmentNavigationEventArgs.cs
- LoginDesigner.cs
- ToolStripSystemRenderer.cs
- ListViewPagedDataSource.cs
- ResourceDescriptionAttribute.cs
- recordstatefactory.cs
- TypeAccessException.cs
- ISAPIWorkerRequest.cs
- BlobPersonalizationState.cs
- Label.cs
- DelimitedListTraceListener.cs
- PartialTrustVisibleAssembliesSection.cs
- MessageRpc.cs
- FactoryGenerator.cs
- FieldAccessException.cs
- IntranetCredentialPolicy.cs
- BitmapSource.cs
- ConstraintConverter.cs
- HtmlShimManager.cs
- ServiceElement.cs
- SerialStream.cs
- UInt64Storage.cs
- PlatformCulture.cs
- CodeSubDirectory.cs
- ConnectivityStatus.cs
- ParserHooks.cs
- Rules.cs
- COM2PictureConverter.cs
- LogicalCallContext.cs
- AlternationConverter.cs
- ProcessHostFactoryHelper.cs
- FixedSOMPage.cs
- StreamAsIStream.cs
- DateTime.cs
- SmiContext.cs
- ScriptRegistrationManager.cs
- RepeatBehaviorConverter.cs
- FileSecurity.cs
- CodeArrayCreateExpression.cs
- SqlSelectStatement.cs
- DataListCommandEventArgs.cs
- InkCanvasAutomationPeer.cs
- MailHeaderInfo.cs
- AnimatedTypeHelpers.cs
- ReaderContextStackData.cs
- DropShadowEffect.cs
- TemplatedAdorner.cs
- CompilerResults.cs
- AvTraceDetails.cs
- XmlObjectSerializerReadContext.cs
- MessageLoggingElement.cs
- RSAPKCS1SignatureDeformatter.cs
- DictionaryEntry.cs
- RegistrationServices.cs
- DeploymentExceptionMapper.cs
- SystemIPInterfaceProperties.cs
- StaticDataManager.cs
- RectAnimationClockResource.cs
- AuthorizationContext.cs
- MatcherBuilder.cs
- AccessDataSource.cs
- Overlapped.cs
- SignatureDescription.cs
- DataGridViewRowContextMenuStripNeededEventArgs.cs
- StreamingContext.cs
- X509Certificate.cs
- StringInfo.cs
- HyperLink.cs
- RuntimeEnvironment.cs
- PathStreamGeometryContext.cs
- ResourceCategoryAttribute.cs
- StateMachine.cs
- CustomErrorsSectionWrapper.cs
- DefaultDiscoveryService.cs
- MsmqIntegrationSecurity.cs
- Vars.cs
- MimeMultiPart.cs
- ProxyWebPartManagerDesigner.cs
- InvalidEnumArgumentException.cs
- XmlSignatureProperties.cs
- EffectiveValueEntry.cs
- DirectoryObjectSecurity.cs
- DataControlFieldTypeEditor.cs
- PasswordRecovery.cs