Example #1
0
 internal OpenSpan.Adapters.Controls.Control Create_Control1(out System.Collections.Generic.ICollection<System.ComponentModel.IComponent> components)
 {
     components = new System.Collections.Generic.List<System.ComponentModel.IComponent>();
     OpenSpan.Adapters.Controls.Control Control1 = new OpenSpan.Adapters.Controls.Control();
     this.SetId(Control1, new OpenSpan.Design.ComponentIdentity("Control-8D162430A983A75"));
     OpenSpan.Adapters.Controls.Control Control;
     Control = new OpenSpan.Adapters.Controls.Control();
     //
     // Control
     //
     OpenSpan.Adapters.Controls.Button btnSeven;
     btnSeven = new OpenSpan.Adapters.Controls.Button();
     //
     // btnSeven
     //
     btnSeven.Extender = null;
     btnSeven.ForwardObjectExplorerEvent = true;
     btnSeven.MatchingIndex = 2;
     OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule classNameMatchRule4;
     classNameMatchRule4 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     //
     // classNameMatchRule4
     //
     classNameMatchRule4.ClassName = "Button";
     OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule controlIdMatchRule1;
     controlIdMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule();
     //
     // controlIdMatchRule1
     //
     controlIdMatchRule1.ControlId = 137;
     btnSeven.MatchRules.Add(classNameMatchRule4);
     btnSeven.MatchRules.Add(controlIdMatchRule1);
     btnSeven.Name = "btnSeven";
     btnSeven.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Button, OpenSpan.Adapters.Windows";
     OpenSpan.Adapters.Controls.Button btnC;
     btnC = new OpenSpan.Adapters.Controls.Button();
     //
     // btnC
     //
     btnC.Extender = null;
     btnC.ForwardObjectExplorerEvent = true;
     btnC.MatchingIndex = 12;
     OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule classNameMatchRule5;
     classNameMatchRule5 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     //
     // classNameMatchRule5
     //
     classNameMatchRule5.ClassName = "Button";
     OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule controlIdMatchRule2;
     controlIdMatchRule2 = new OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule();
     //
     // controlIdMatchRule2
     //
     controlIdMatchRule2.ControlId = 81;
     btnC.MatchRules.Add(classNameMatchRule5);
     btnC.MatchRules.Add(controlIdMatchRule2);
     btnC.Name = "btnC";
     btnC.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Button, OpenSpan.Adapters.Windows";
     Control.Controls.Add(btnSeven);
     Control.Controls.Add(btnC);
     Control.Extender = null;
     Control.ForwardObjectExplorerEvent = true;
     Control.MatchingIndex = 3;
     OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule classNameMatchRule3;
     classNameMatchRule3 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     //
     // classNameMatchRule3
     //
     classNameMatchRule3.ClassName = "#32770";
     OpenSpan.Adapters.Windows.MatchRules.WindowTypeMatchRule windowTypeMatchRule2;
     windowTypeMatchRule2 = new OpenSpan.Adapters.Windows.MatchRules.WindowTypeMatchRule();
     //
     // windowTypeMatchRule2
     //
     windowTypeMatchRule2.Type = OpenSpan.Adapters.Windows.WindowType.Child;
     OpenSpan.Adapters.MatchRules.ControlChildrenMatchRule controlChildrenMatchRule1;
     controlChildrenMatchRule1 = new OpenSpan.Adapters.MatchRules.ControlChildrenMatchRule();
     //
     // controlChildrenMatchRule1
     //
     controlChildrenMatchRule1.Children.Add(btnSeven);
     Control.MatchRules.Add(classNameMatchRule3);
     Control.MatchRules.Add(windowTypeMatchRule2);
     Control.MatchRules.Add(controlChildrenMatchRule1);
     Control.Name = "Control";
     Control.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Control, OpenSpan.Adapters.Windows";
     Control1.Controls.Add(Control);
     Control1.Extender = null;
     Control1.ForwardObjectExplorerEvent = true;
     Control1.MatchingIndex = 0;
     OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule classNameMatchRule2;
     classNameMatchRule2 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     //
     // classNameMatchRule2
     //
     classNameMatchRule2.ClassName = "CalcFrame";
     OpenSpan.Adapters.Windows.MatchRules.WindowTypeMatchRule windowTypeMatchRule1;
     windowTypeMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.WindowTypeMatchRule();
     //
     // windowTypeMatchRule1
     //
     windowTypeMatchRule1.Type = OpenSpan.Adapters.Windows.WindowType.Child;
     Control1.MatchRules.Add(classNameMatchRule2);
     Control1.MatchRules.Add(windowTypeMatchRule1);
     Control1.Name = "Control1";
     Control1.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Control, OpenSpan.Adapters.Windows";
     //
     // Set component Ids
     //
     this.SetId(Control, new OpenSpan.Design.ComponentIdentity("Control-8D162430A972905"));
     this.SetId(btnSeven, new OpenSpan.Design.ComponentIdentity("Button-8D162430A933165"));
     this.SetId(classNameMatchRule4, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430AA50BB5"));
     this.SetId(controlIdMatchRule1, new OpenSpan.Design.ComponentIdentity("ControlIdMatchRule-8D162430AA5F615"));
     this.SetId(btnC, new OpenSpan.Design.ComponentIdentity("Button-8D1624365A8E217"));
     this.SetId(classNameMatchRule5, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D1624365AB2C16"));
     this.SetId(controlIdMatchRule2, new OpenSpan.Design.ComponentIdentity("ControlIdMatchRule-8D1624365ACD9D1"));
     this.SetId(classNameMatchRule3, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430AA16235"));
     this.SetId(windowTypeMatchRule2, new OpenSpan.Design.ComponentIdentity("WindowTypeMatchRule-8D162430AA273A5"));
     this.SetId(controlChildrenMatchRule1, new OpenSpan.Design.ComponentIdentity("ControlChildrenMatchRule-8D162434F95AEEF"));
     this.SetId(classNameMatchRule2, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430A9EF135"));
     this.SetId(windowTypeMatchRule1, new OpenSpan.Design.ComponentIdentity("WindowTypeMatchRule-8D162430AA002A5"));
     //
     // Add components
     //
     components.Add(Control);
     components.Add(btnSeven);
     components.Add(classNameMatchRule4);
     components.Add(controlIdMatchRule1);
     components.Add(btnC);
     components.Add(classNameMatchRule5);
     components.Add(controlIdMatchRule2);
     components.Add(classNameMatchRule3);
     components.Add(windowTypeMatchRule2);
     components.Add(controlChildrenMatchRule1);
     components.Add(classNameMatchRule2);
     components.Add(windowTypeMatchRule1);
     //
     // Result
     //
     return Control1;
 }
Example #2
0
 internal OpenSpan.Adapters.MatchRules.ControlChildrenMatchRule Create_controlChildrenMatchRule1(out System.Collections.Generic.ICollection<System.ComponentModel.IComponent> components)
 {
     components = new System.Collections.Generic.List<System.ComponentModel.IComponent>();
     OpenSpan.Adapters.MatchRules.ControlChildrenMatchRule controlChildrenMatchRule1 = new OpenSpan.Adapters.MatchRules.ControlChildrenMatchRule();
     this.SetId(controlChildrenMatchRule1, new OpenSpan.Design.ComponentIdentity("ControlChildrenMatchRule-8D162434F95AEEF"));
     OpenSpan.Adapters.Controls.Button btnSeven;
     btnSeven = new OpenSpan.Adapters.Controls.Button();
     //
     // btnSeven
     //
     btnSeven.Extender = null;
     btnSeven.ForwardObjectExplorerEvent = true;
     btnSeven.MatchingIndex = 2;
     OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule classNameMatchRule4;
     classNameMatchRule4 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     //
     // classNameMatchRule4
     //
     classNameMatchRule4.ClassName = "Button";
     OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule controlIdMatchRule1;
     controlIdMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule();
     //
     // controlIdMatchRule1
     //
     controlIdMatchRule1.ControlId = 137;
     btnSeven.MatchRules.Add(classNameMatchRule4);
     btnSeven.MatchRules.Add(controlIdMatchRule1);
     btnSeven.Name = "btnSeven";
     btnSeven.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Button, OpenSpan.Adapters.Windows";
     controlChildrenMatchRule1.Children.Add(btnSeven);
     //
     // Set component Ids
     //
     this.SetId(btnSeven, new OpenSpan.Design.ComponentIdentity("Button-8D162430A933165"));
     this.SetId(classNameMatchRule4, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430AA50BB5"));
     this.SetId(controlIdMatchRule1, new OpenSpan.Design.ComponentIdentity("ControlIdMatchRule-8D162430AA5F615"));
     //
     // Add components
     //
     components.Add(btnSeven);
     components.Add(classNameMatchRule4);
     components.Add(controlIdMatchRule1);
     //
     // Result
     //
     return controlChildrenMatchRule1;
 }
Example #3
0
 public Calc()
 {
     System.ComponentModel.ComponentResourceManager _resources_ = new System.ComponentModel.ComponentResourceManager(typeof(Calc));
     OpenSpan.Adapters.TextMatchData textmatchdata1 = new OpenSpan.Adapters.TextMatchData();
     OpenSpan.Adapters.TextMatchData textmatchdata2 = new OpenSpan.Adapters.TextMatchData();
     this.ActiveXFactory = new OpenSpan.Adapters.ActiveX.ActiveXFactory();
     this.moduleNameMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.ModuleNameMatchRule();
     this.Calculator = new OpenSpan.Adapters.Controls.Form();
     this.Control1 = new OpenSpan.Adapters.Controls.Control();
     this.Control = new OpenSpan.Adapters.Controls.Control();
     this.btnSeven = new OpenSpan.Adapters.Controls.Button();
     this.classNameMatchRule4 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     this.controlIdMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule();
     this.btnC = new OpenSpan.Adapters.Controls.Button();
     this.classNameMatchRule5 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     this.controlIdMatchRule2 = new OpenSpan.Adapters.Windows.MatchRules.ControlIdMatchRule();
     this.classNameMatchRule3 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     this.windowTypeMatchRule2 = new OpenSpan.Adapters.Windows.MatchRules.WindowTypeMatchRule();
     this.controlChildrenMatchRule1 = new OpenSpan.Adapters.MatchRules.ControlChildrenMatchRule();
     this.classNameMatchRule2 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     this.windowTypeMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.WindowTypeMatchRule();
     this.windowTextMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.WindowTextMatchRule();
     this.classNameMatchRule1 = new OpenSpan.Adapters.Windows.MatchRules.ClassNameMatchRule();
     //
     // Initialize design component
     //
     this.Initialize();
     //
     // Set design component Id
     //
     this.Id = new OpenSpan.Design.ComponentIdentity("WindowsAdapter-8D16242F4F549B5");
     //
     // Set component Ids
     //
     this.SetId(this.ActiveXFactory, new OpenSpan.Design.ComponentIdentity("ActiveXFactory-8D1624307A427C5"));
     this.SetId(this.moduleNameMatchRule1, new OpenSpan.Design.ComponentIdentity("ModuleNameMatchRule-8D1624307AC6525"));
     this.SetId(this.Calculator, new OpenSpan.Design.ComponentIdentity("Form-8D162430A994BE5"));
     this.SetId(this.Control1, new OpenSpan.Design.ComponentIdentity("Control-8D162430A983A75"));
     this.SetId(this.Control, new OpenSpan.Design.ComponentIdentity("Control-8D162430A972905"));
     this.SetId(this.btnSeven, new OpenSpan.Design.ComponentIdentity("Button-8D162430A933165"));
     this.SetId(this.classNameMatchRule4, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430AA50BB5"));
     this.SetId(this.controlIdMatchRule1, new OpenSpan.Design.ComponentIdentity("ControlIdMatchRule-8D162430AA5F615"));
     this.SetId(this.btnC, new OpenSpan.Design.ComponentIdentity("Button-8D1624365A8E217"));
     this.SetId(this.classNameMatchRule5, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D1624365AB2C16"));
     this.SetId(this.controlIdMatchRule2, new OpenSpan.Design.ComponentIdentity("ControlIdMatchRule-8D1624365ACD9D1"));
     this.SetId(this.classNameMatchRule3, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430AA16235"));
     this.SetId(this.windowTypeMatchRule2, new OpenSpan.Design.ComponentIdentity("WindowTypeMatchRule-8D162430AA273A5"));
     this.SetId(this.controlChildrenMatchRule1, new OpenSpan.Design.ComponentIdentity("ControlChildrenMatchRule-8D162434F95AEEF"));
     this.SetId(this.classNameMatchRule2, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430A9EF135"));
     this.SetId(this.windowTypeMatchRule1, new OpenSpan.Design.ComponentIdentity("WindowTypeMatchRule-8D162430AA002A5"));
     this.SetId(this.windowTextMatchRule1, new OpenSpan.Design.ComponentIdentity("WindowTextMatchRule-8D162430A9BE3F5"));
     this.SetId(this.classNameMatchRule1, new OpenSpan.Design.ComponentIdentity("ClassNameMatchRule-8D162430A9D4385"));
     //
     // Calc
     //
     ComponentInfo.CodeDomData = _resources_.GetString("_Calc_1_");
     //
     // ActiveXFactory
     //
     this.ActiveXFactory.Extender = null;
     this.ActiveXFactory.FactoryName = null;
     this.ActiveXFactory.ForwardObjectExplorerEvent = true;
     this.ActiveXFactory.MatchingIndex = 0;
     //
     // moduleNameMatchRule1
     //
     textmatchdata1.Text = "ole32.dll";
     this.moduleNameMatchRule1.Text = textmatchdata1;
     this.ActiveXFactory.MatchRules.Add(this.moduleNameMatchRule1);
     this.ActiveXFactory.Name = "ActiveXFactory";
     this.ActiveXFactory.TargetTypeString = "OpenSpan.Adapters.Windows.WindowsModule, OpenSpan.Adapters.Windows";
     this.ActiveXFactory.UseKeys = true;
     //
     // Calculator
     //
     //
     // Control1
     //
     //
     // Control
     //
     //
     // btnSeven
     //
     this.btnSeven.Extender = null;
     this.btnSeven.ForwardObjectExplorerEvent = true;
     this.btnSeven.MatchingIndex = 2;
     //
     // classNameMatchRule4
     //
     this.classNameMatchRule4.ClassName = "Button";
     //
     // controlIdMatchRule1
     //
     this.controlIdMatchRule1.ControlId = 137;
     this.btnSeven.MatchRules.Add(this.classNameMatchRule4);
     this.btnSeven.MatchRules.Add(this.controlIdMatchRule1);
     this.btnSeven.Name = "btnSeven";
     this.btnSeven.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Button, OpenSpan.Adapters.Windows";
     //
     // btnC
     //
     this.btnC.Extender = null;
     this.btnC.ForwardObjectExplorerEvent = true;
     this.btnC.MatchingIndex = 12;
     //
     // classNameMatchRule5
     //
     this.classNameMatchRule5.ClassName = "Button";
     //
     // controlIdMatchRule2
     //
     this.controlIdMatchRule2.ControlId = 81;
     this.btnC.MatchRules.Add(this.classNameMatchRule5);
     this.btnC.MatchRules.Add(this.controlIdMatchRule2);
     this.btnC.Name = "btnC";
     this.btnC.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Button, OpenSpan.Adapters.Windows";
     this.Control.Controls.Add(this.btnSeven);
     this.Control.Controls.Add(this.btnC);
     this.Control.Extender = null;
     this.Control.ForwardObjectExplorerEvent = true;
     this.Control.MatchingIndex = 3;
     //
     // classNameMatchRule3
     //
     this.classNameMatchRule3.ClassName = "#32770";
     //
     // windowTypeMatchRule2
     //
     this.windowTypeMatchRule2.Type = OpenSpan.Adapters.Windows.WindowType.Child;
     //
     // controlChildrenMatchRule1
     //
     this.controlChildrenMatchRule1.Children.Add(this.btnSeven);
     this.Control.MatchRules.Add(this.classNameMatchRule3);
     this.Control.MatchRules.Add(this.windowTypeMatchRule2);
     this.Control.MatchRules.Add(this.controlChildrenMatchRule1);
     this.Control.Name = "Control";
     this.Control.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Control, OpenSpan.Adapters.Windows";
     this.Control1.Controls.Add(this.Control);
     this.Control1.Extender = null;
     this.Control1.ForwardObjectExplorerEvent = true;
     this.Control1.MatchingIndex = 0;
     //
     // classNameMatchRule2
     //
     this.classNameMatchRule2.ClassName = "CalcFrame";
     //
     // windowTypeMatchRule1
     //
     this.windowTypeMatchRule1.Type = OpenSpan.Adapters.Windows.WindowType.Child;
     this.Control1.MatchRules.Add(this.classNameMatchRule2);
     this.Control1.MatchRules.Add(this.windowTypeMatchRule1);
     this.Control1.Name = "Control1";
     this.Control1.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Control, OpenSpan.Adapters.Windows";
     this.Calculator.Controls.Add(this.Control1);
     this.Calculator.Extender = null;
     this.Calculator.ForwardObjectExplorerEvent = true;
     this.Calculator.MatchingIndex = 0;
     //
     // windowTextMatchRule1
     //
     textmatchdata2.Text = "Calculator";
     this.windowTextMatchRule1.Text = textmatchdata2;
     //
     // classNameMatchRule1
     //
     this.classNameMatchRule1.ClassName = "CalcFrame";
     this.Calculator.MatchRules.Add(this.windowTextMatchRule1);
     this.Calculator.MatchRules.Add(this.classNameMatchRule1);
     this.Calculator.Name = "Calculator";
     this.Calculator.TargetTypeString = "OpenSpan.Adapters.Windows.Targets.Form, OpenSpan.Adapters.Windows";
     this.Controls.Add(this.ActiveXFactory);
     this.Controls.Add(this.Calculator);
     this.Extender = null;
     this.Name = "Calc";
     this.Path = "C:\\Windows\\system32\\calc.exe | System";
     this.StartMethod = OpenSpan.Adapters.Windows.WindowsProcessStartMethod.MonitorAll;
     this.WorkingDirectory = "C:\\Windows\\system32";
     //
     // Add components
     //
     this.mComponents = new System.Collections.Generic.List<System.ComponentModel.IComponent>(20);
     this.Components.Add(this.ActiveXFactory);
     this.Components.Add(this.moduleNameMatchRule1);
     this.Components.Add(this.Calculator);
     this.Components.Add(this.Control1);
     this.Components.Add(this.Control);
     this.Components.Add(this.btnSeven);
     this.Components.Add(this.classNameMatchRule4);
     this.Components.Add(this.controlIdMatchRule1);
     this.Components.Add(this.btnC);
     this.Components.Add(this.classNameMatchRule5);
     this.Components.Add(this.controlIdMatchRule2);
     this.Components.Add(this.classNameMatchRule3);
     this.Components.Add(this.windowTypeMatchRule2);
     this.Components.Add(this.controlChildrenMatchRule1);
     this.Components.Add(this.classNameMatchRule2);
     this.Components.Add(this.windowTypeMatchRule1);
     this.Components.Add(this.windowTextMatchRule1);
     this.Components.Add(this.classNameMatchRule1);
 }