Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / 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
- WindowsToolbarAsMenu.cs
- WebBrowserHelper.cs
- DbFunctionCommandTree.cs
- NetworkInformationException.cs
- MediaElement.cs
- Buffer.cs
- DelayDesigner.cs
- ReadOnlyPropertyMetadata.cs
- InvalidEnumArgumentException.cs
- RegexReplacement.cs
- DataGridViewSelectedCellCollection.cs
- SevenBitStream.cs
- MemoryRecordBuffer.cs
- ResourceReader.cs
- PartialToken.cs
- BCryptSafeHandles.cs
- CalendarDay.cs
- CounterSampleCalculator.cs
- SqlCrossApplyToCrossJoin.cs
- Paragraph.cs
- MenuItem.cs
- OrderedDictionaryStateHelper.cs
- CatalogPartCollection.cs
- GenericsNotImplementedException.cs
- ConsumerConnectionPoint.cs
- MailWriter.cs
- RepeaterItemCollection.cs
- HelpEvent.cs
- MaterialGroup.cs
- XamlTemplateSerializer.cs
- SamlAttribute.cs
- ErrorWrapper.cs
- Visitor.cs
- DataGridViewCell.cs
- PartialCachingAttribute.cs
- UIAgentMonitorHandle.cs
- TypeValidationEventArgs.cs
- ActivationProxy.cs
- ValidatingReaderNodeData.cs
- ProxyGenerator.cs
- TypeConverterValueSerializer.cs
- DataShape.cs
- DesignerActionHeaderItem.cs
- LogRecordSequence.cs
- EntityDataSourceStatementEditor.cs
- ZipIOExtraField.cs
- MaterialCollection.cs
- FixedTextBuilder.cs
- DependencyPropertyKind.cs
- DataGridViewRowPostPaintEventArgs.cs
- Matrix.cs
- Debug.cs
- EventQueueState.cs
- DataServiceRequestOfT.cs
- PostBackOptions.cs
- WorkflowInvoker.cs
- SchemaEntity.cs
- DecimalConverter.cs
- DiscoveryServiceExtension.cs
- CodeConstructor.cs
- AttributeUsageAttribute.cs
- TraceListeners.cs
- GeneratedCodeAttribute.cs
- ProfileInfo.cs
- PaperSource.cs
- ElementHostAutomationPeer.cs
- SqlDataSourceParameterParser.cs
- DataServiceRequestException.cs
- DrawingImage.cs
- ActivationServices.cs
- XmlValidatingReaderImpl.cs
- ProgressBar.cs
- ControlCodeDomSerializer.cs
- DataGridViewCellStyleChangedEventArgs.cs
- DataErrorValidationRule.cs
- MergeFailedEvent.cs
- DynamicEndpointElement.cs
- dbenumerator.cs
- QueryContinueDragEventArgs.cs
- DataTable.cs
- SiteIdentityPermission.cs
- EntityKeyElement.cs
- CommandEventArgs.cs
- ActivityCodeGenerator.cs
- OleTxTransactionInfo.cs
- Validator.cs
- SiteMapNode.cs
- HtmlInputControl.cs
- XmlDeclaration.cs
- DataGridViewImageCell.cs
- coordinator.cs
- FieldMetadata.cs
- CreateUserWizardStep.cs
- XPathChildIterator.cs
- sqlnorm.cs
- GPPOINT.cs
- DataGridRowHeaderAutomationPeer.cs
- ConversionContext.cs
- FontCacheLogic.cs
- HttpHandlerAction.cs