private static void HandleStructureChangedEventClient(ProxySimple el, IntPtr hwnd, int eventId) { if (eventId == NativeMethods.EventObjectCreate) { AutomationInteropProvider.RaiseStructureChangedEvent (el, new StructureChangedEventArgs (StructureChangeType.ChildAdded, el.MakeRuntimeId())); } else if (eventId == NativeMethods.EventObjectDestroy) { AutomationInteropProvider.RaiseStructureChangedEvent( el, new StructureChangedEventArgs( StructureChangeType.ChildRemoved, el.MakeRuntimeId() ) ); } else if ( eventId == NativeMethods.EventObjectReorder ) { IGridProvider grid = el.GetPatternProvider(GridPattern.Pattern) as IGridProvider; if ( grid == null ) return; AutomationInteropProvider.RaiseStructureChangedEvent( el, new StructureChangedEventArgs( StructureChangeType.ChildrenInvalidated, el.MakeRuntimeId() ) ); } }
private static void HandleStructureChangedEventClient(ProxySimple el, IntPtr hwnd, int eventId) { if (eventId == NativeMethods.EventObjectCreate) { AutomationInteropProvider.RaiseStructureChangedEvent(el, new StructureChangedEventArgs(StructureChangeType.ChildAdded, el.MakeRuntimeId())); } else if (eventId == NativeMethods.EventObjectDestroy) { AutomationInteropProvider.RaiseStructureChangedEvent(el, new StructureChangedEventArgs(StructureChangeType.ChildRemoved, el.MakeRuntimeId())); } else if (eventId == NativeMethods.EventObjectReorder) { IGridProvider grid = el.GetPatternProvider(GridPattern.Pattern) as IGridProvider; if (grid == null) { return; } AutomationInteropProvider.RaiseStructureChangedEvent(el, new StructureChangedEventArgs(StructureChangeType.ChildrenInvalidated, el.MakeRuntimeId())); } }
private static void HandleStructureChangedEventWindow(ProxySimple el, IntPtr hwnd, int eventId) { if (eventId == NativeMethods.EventObjectReorder) { AutomationInteropProvider.RaiseStructureChangedEvent( el, new StructureChangedEventArgs( StructureChangeType.ChildrenReordered, el.MakeRuntimeId() ) ); } }
private static void HandleStructureChangedEventWindow(ProxySimple el, IntPtr hwnd, int eventId) { if (eventId == NativeMethods.EventObjectReorder) { AutomationInteropProvider.RaiseStructureChangedEvent(el, new StructureChangedEventArgs(StructureChangeType.ChildrenReordered, el.MakeRuntimeId())); } }