Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / UIAutomation / UIAutomationClient / System / Windows / Automation / InvokePattern.cs / 1305600 / InvokePattern.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: Client-side wrapper for Invoke Pattern // // History: // 06/23/2003 : BrendanM Ported to WCP // //--------------------------------------------------------------------------- using System; using System.Windows.Automation.Provider; using MS.Internal.Automation; namespace System.Windows.Automation { ////// Represents objects that have a single, unambiguous, action associated with them. /// /// Examples of UI that implments this includes: /// Push buttons /// Hyperlinks /// Menu items /// Radio buttons /// Check boxes /// #if (INTERNAL_COMPILE) internal class InvokePattern: BasePattern #else public class InvokePattern: BasePattern #endif { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors private InvokePattern(AutomationElement el, SafePatternHandle hPattern) : base(el, hPattern) { _hPattern = hPattern; } #endregion Constructors //------------------------------------------------------ // // Public Constants / Readonly Fields // //----------------------------------------------------- #region Public Constants and Readonly Fields ///Invokable pattern public static readonly AutomationPattern Pattern = InvokePatternIdentifiers.Pattern; ///Event ID: Invoked - event used to watch for Invokable pattern Invoked events public static readonly AutomationEvent InvokedEvent = InvokePatternIdentifiers.InvokedEvent; #endregion Public Constants and Readonly Fields //------------------------------------------------------ // // Public Methods // //------------------------------------------------------ #region Public Methods ////// Request that the control initiate its action. /// Should return immediately without blocking. /// There is no way to determine what happened, when it happend, or whether /// anything happened at all. /// /// ////// This API does not work inside the secure execution environment. /// public void Invoke() { UiaCoreApi.InvokePattern_Invoke(_hPattern); } #endregion Public Methods //----------------------------------------------------- // // Public Properties // //------------------------------------------------------ #region Public Properties // No properties #endregion Public Properties //----------------------------------------------------- // // Internal Methods // //----------------------------------------------------- #region Internal Methods internal static object Wrap(AutomationElement el, SafePatternHandle hPattern, bool cached) { return new InvokePattern(el, hPattern); } #endregion Internal Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private SafePatternHandle _hPattern; #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: Client-side wrapper for Invoke Pattern // // History: // 06/23/2003 : BrendanM Ported to WCP // //--------------------------------------------------------------------------- using System; using System.Windows.Automation.Provider; using MS.Internal.Automation; namespace System.Windows.Automation { ////// Represents objects that have a single, unambiguous, action associated with them. /// /// Examples of UI that implments this includes: /// Push buttons /// Hyperlinks /// Menu items /// Radio buttons /// Check boxes /// #if (INTERNAL_COMPILE) internal class InvokePattern: BasePattern #else public class InvokePattern: BasePattern #endif { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors private InvokePattern(AutomationElement el, SafePatternHandle hPattern) : base(el, hPattern) { _hPattern = hPattern; } #endregion Constructors //------------------------------------------------------ // // Public Constants / Readonly Fields // //----------------------------------------------------- #region Public Constants and Readonly Fields ///Invokable pattern public static readonly AutomationPattern Pattern = InvokePatternIdentifiers.Pattern; ///Event ID: Invoked - event used to watch for Invokable pattern Invoked events public static readonly AutomationEvent InvokedEvent = InvokePatternIdentifiers.InvokedEvent; #endregion Public Constants and Readonly Fields //------------------------------------------------------ // // Public Methods // //------------------------------------------------------ #region Public Methods ////// Request that the control initiate its action. /// Should return immediately without blocking. /// There is no way to determine what happened, when it happend, or whether /// anything happened at all. /// /// ////// This API does not work inside the secure execution environment. /// public void Invoke() { UiaCoreApi.InvokePattern_Invoke(_hPattern); } #endregion Public Methods //----------------------------------------------------- // // Public Properties // //------------------------------------------------------ #region Public Properties // No properties #endregion Public Properties //----------------------------------------------------- // // Internal Methods // //----------------------------------------------------- #region Internal Methods internal static object Wrap(AutomationElement el, SafePatternHandle hPattern, bool cached) { return new InvokePattern(el, hPattern); } #endregion Internal Methods //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private SafePatternHandle _hPattern; #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
- DataTableTypeConverter.cs
- ProviderSettingsCollection.cs
- BoundPropertyEntry.cs
- DatagridviewDisplayedBandsData.cs
- XmlElement.cs
- SqlBooleanizer.cs
- CommandHelper.cs
- ProviderConnectionPointCollection.cs
- TextParaClient.cs
- MobileCategoryAttribute.cs
- ComplexTypeEmitter.cs
- Graph.cs
- ObjectDataSourceView.cs
- ImageListUtils.cs
- FixedSOMPage.cs
- Error.cs
- CacheChildrenQuery.cs
- SiteMapNodeItem.cs
- SamlSubjectStatement.cs
- StorageAssociationSetMapping.cs
- IntegerCollectionEditor.cs
- ITreeGenerator.cs
- DynamicDiscoveryDocument.cs
- XPathConvert.cs
- ApplicationCommands.cs
- Vector3DCollection.cs
- ModifiableIteratorCollection.cs
- _LocalDataStoreMgr.cs
- TemplateBindingExpressionConverter.cs
- Floater.cs
- ScriptRegistrationManager.cs
- IImplicitResourceProvider.cs
- String.cs
- SignedXml.cs
- MsmqIntegrationBindingElement.cs
- BooleanKeyFrameCollection.cs
- HashMembershipCondition.cs
- WizardStepBase.cs
- BamlMapTable.cs
- DBSqlParser.cs
- ModelPerspective.cs
- DesignObjectWrapper.cs
- PatternMatcher.cs
- HttpMethodAttribute.cs
- AutoGeneratedFieldProperties.cs
- SchemaManager.cs
- CodeTypeOfExpression.cs
- SplitContainer.cs
- ReadOnlyObservableCollection.cs
- Scene3D.cs
- ThreadInterruptedException.cs
- RangeBaseAutomationPeer.cs
- DeclarationUpdate.cs
- EntityClientCacheKey.cs
- AutomationEvent.cs
- ExecutedRoutedEventArgs.cs
- TdsParserStaticMethods.cs
- SystemDiagnosticsSection.cs
- GlobalProxySelection.cs
- HttpListenerResponse.cs
- SelectionWordBreaker.cs
- CellPartitioner.cs
- DesignSurfaceServiceContainer.cs
- PathStreamGeometryContext.cs
- CharacterMetrics.cs
- XslCompiledTransform.cs
- Int16.cs
- GridViewUpdateEventArgs.cs
- Encoder.cs
- PolicyImporterElement.cs
- ImageCollectionEditor.cs
- ASCIIEncoding.cs
- CreateUserErrorEventArgs.cs
- InlinedAggregationOperatorEnumerator.cs
- GenericIdentity.cs
- CfgRule.cs
- XmlElementAttribute.cs
- SingleObjectCollection.cs
- EditorPart.cs
- RangeValidator.cs
- Point3DConverter.cs
- BooleanAnimationBase.cs
- EDesignUtil.cs
- OutputCacheModule.cs
- PropertyDescriptorGridEntry.cs
- FillRuleValidation.cs
- TemplateControlCodeDomTreeGenerator.cs
- XmlNamedNodeMap.cs
- ToolStripItemGlyph.cs
- XmlArrayAttribute.cs
- SoapFormatter.cs
- CheckBoxRenderer.cs
- SafeReversePInvokeHandle.cs
- SmiConnection.cs
- SqlClientFactory.cs
- ToolStripHighContrastRenderer.cs
- XmlHierarchicalEnumerable.cs
- TypeSystemProvider.cs
- DiscoveryViaBehavior.cs
- SqlDataReader.cs