コード例 #1
0
ファイル: Widget.cs プロジェクト: swidge/iPhoneGUITAR
        public override WidgetPrx[] getChildren(Ice.Current context__)
        {
            AutomationElementCollection childrenList =
            element.FindAll(TreeScope.Children, Condition.TrueCondition);

            WidgetPrx[] components = new WidgetPrx[childrenList.Count];
            for (int i = 0; i < childrenList.Count; i++)
            {
            components[i] = new WidgetI(process,childrenList[i],this).Proxy;
            }
            return components;
        }
コード例 #2
0
ファイル: EventFactory.cs プロジェクト: swidge/iPhoneGUITAR
        public static ActionPrx[] getEventList(
            ProcessI process, WidgetI component)
        {
            loadAssembly();

            // Check which events support the component
            List<ActionPrx> proxies = new List<ActionPrx>();
            foreach (EventMaker maker in makerList)
            {
                if (maker.isSupportedBy(component))
                    proxies.Add(maker.newObject(process, component));
            }
            return proxies.ToArray();
        }
コード例 #3
0
ファイル: Process.cs プロジェクト: swidge/iPhoneGUITAR
        public override WidgetPrx[] getWindows(Ice.Current current__)
        {
            // Check based on pid and for ControlType.Window
            PropertyCondition pidCondition = new PropertyCondition(
                AutomationElement.ProcessIdProperty, process.Id);
            PropertyCondition windowCondition = new PropertyCondition(
                AutomationElement.ControlTypeProperty, ControlType.Window);
            Condition condition = new AndCondition(pidCondition,
                                                   windowCondition);

            // Check the children of the automation root for windows
            AutomationElement root = AutomationElement.RootElement;
            AutomationElementCollection rootWindows =
                root.FindAll(TreeScope.Children, condition);

            // Register the windows
            WidgetPrx[] windows = new WidgetPrx[rootWindows.Count];
            for (int i = 0; i < rootWindows.Count; i++)
            {
                windows[i] = new WidgetI(this, rootWindows[i]).Proxy;
            }

            return windows;
        }
コード例 #4
0
ファイル: EventFactory.cs プロジェクト: swidge/iPhoneGUITAR
 public ActionPrx newObject(ProcessI process, WidgetI component)
 {
     Ice.ObjectPrx obj = process.register(makeObject(component));
     return ActionPrxHelper.uncheckedCast(obj);
 }
コード例 #5
0
ファイル: EventFactory.cs プロジェクト: swidge/iPhoneGUITAR
 public abstract Ice.Object makeObject(WidgetI component);
コード例 #6
0
ファイル: EventFactory.cs プロジェクト: swidge/iPhoneGUITAR
 public abstract bool isSupportedBy(WidgetI component);
コード例 #7
0
ファイル: InvokeEvent.cs プロジェクト: swidge/iPhoneGUITAR
 public override Ice.Object makeObject(WidgetI component)
 {
     return new InvokeEvent(component);
 }
コード例 #8
0
ファイル: InvokeEvent.cs プロジェクト: swidge/iPhoneGUITAR
 public override bool isSupportedBy(WidgetI component)
 {
     AutomationElement element = component.Element;
     return (bool) element.GetCurrentPropertyValue(
         AutomationElement.IsInvokePatternAvailableProperty);
 }
コード例 #9
0
ファイル: InvokeEvent.cs プロジェクト: swidge/iPhoneGUITAR
 public InvokeEvent(WidgetI component)
 {
     this.component = component;
 }
コード例 #10
0
ファイル: Widget.cs プロジェクト: swidge/iPhoneGUITAR
 public WidgetI(ProcessI process, AutomationElement element,
               WidgetI parent)
     : this(process, element)
 {
     this.parent = parent;
 }
コード例 #11
0
 public override Ice.Object makeObject(WidgetI component)
 {
     return new ExpandCollapseEvent(component);
 }
コード例 #12
0
 public ExpandCollapseEvent(WidgetI component)
 {
     this.component = component;
 }