public UiaDbusSelectionItemPattern (DCI.ISelectionItemPattern pattern, string busName,
		                                    UiaDbusAutomationSource source)
		{
			this.pattern = pattern;
			this.busName = busName;
			this.source = source;
		}
Example #2
0
		public UiaDbusGridPattern (DCI.IGridPattern pattern, string busName,
		                           UiaDbusAutomationSource source)
		{
			this.pattern = pattern;
			this.busName = busName;
			this.source = source;
		}
Example #3
0
		public UiaDbusElement (DCI.IAutomationElement dbusElement, string busName,
		                        string dbusPath, UiaDbusAutomationSource source)
		{
			this.source = source;
			this.busName = busName;
			this.dbusPath = dbusPath;
			this.dbusElement = dbusElement;
		}
Example #4
0
		public UiaDbusTextPatternRange (DCI.ITextPatternRange range,
		                                UiaDbusTextPattern parent,
		                                string path)
		{
			this.range = range;
			this.parent = parent;
			this.path = path;
		}
Example #5
0
		public UiaDbusTablePattern (DCI.ITablePattern pattern, string busName,
		                           UiaDbusAutomationSource source)
			: base (DCI.InterfaceConverter.Table2Grid (pattern),
			        busName, source)
		{
			this.pattern = pattern;
			this.busName = busName;
			this.source = source;
		}
		public UiaDbusMultipleViewPattern (DCI.IMultipleViewPattern pattern)
		{
			this.pattern = pattern;
		}
		public UiaDbusExpandCollapsePattern (DCI.IExpandCollapsePattern pattern)
		{
			this.pattern = pattern;
		}
Example #8
0
		public UiaDbusTransformPattern (DCI.ITransformPattern pattern)
		{
			this.pattern = pattern;
		}
Example #9
0
		public UiaDbusWindowPattern (DCI.IWindowPattern pattern)
		{
			this.pattern = pattern;
		}
Example #10
0
		private UiaDbusElement CreateElement (DCI.IAutomationElement dbusElement, string busName, string elementPath)
		{
			if (dbusElement == null)
				return null;
			UiaDbusElement element = new UiaDbusElement (dbusElement, busName, elementPath, this);
			lock (elementMapping)
				elementMapping.Add (new DbusElementTuple (busName, elementPath), element);
			return element;
		}
Example #11
0
		private void EnsureStructureEventsSetUp (DCI.IApplication app, string busName)
		{
			if (!structureEventBusNames.Contains (busName)) {
				structureEventBusNames.Add (busName);
				app.StructureChanged += delegate (int hId, int evtId, string providerPath,
				                                  StructureChangeType changeType) {
					var handler = eventHandlerManager.GetStructureEventHandlerById (hId);
					if (handler != null) {
						UiaDbusElement elem = GetOrCreateElement (busName, providerPath);
						AutomationElement ae = SourceManager.GetOrCreateAutomationElement (elem);
						var args = new StructureChangedEventArgs (changeType, elem.RuntimeId);
						handler (ae, args);
					}
				};
			}
		}
Example #12
0
		private void EnsurePropertyEventsSetUp (DCI.IApplication app, string busName)
		{
			if (!propertyEventBusNames.Contains (busName)) {
				propertyEventBusNames.Add (busName);
				app.AutomationPropertyChanged += delegate (
					int hId, int evtId, string providerPath,
					int propertyId, object oldValue, object newValue) {
					var handler = eventHandlerManager.GetPropertyEventHandlerById (hId);
					if (handler != null) {
						UiaDbusElement elem = GetOrCreateElement (busName, providerPath);
						AutomationElement ae = SourceManager.GetOrCreateAutomationElement (elem);
						oldValue = DeserializeAutomationPropertyValue (busName, propertyId, oldValue);
						newValue = DeserializeAutomationPropertyValue (busName, propertyId, newValue);
						var args = new AutomationPropertyChangedEventArgs (
							AutomationProperty.LookupById (propertyId),
							oldValue, newValue);
						handler (ae, args);
					}
				};
			}
		}
Example #13
0
		private void EnsureAutomationEventsSetUp (DCI.IApplication app, string busName)
		{
			if (!automationEventBusNames.Contains (busName)) {
				automationEventBusNames.Add (busName);
				app.AutomationEvent += delegate (int hId, int evtId, string providerPath) {
					var handler = eventHandlerManager.GetAutomationEventHandlerById (hId);
					if (handler != null) {
						UiaDbusElement elem = GetOrCreateElement (busName, providerPath);
						AutomationElement ae = SourceManager.GetOrCreateAutomationElement (elem);
						var args = new AutomationEventArgs (AutomationEvent.LookupById (evtId));
						handler (ae, args);
					}
				};
			}
		}
Example #14
0
		public UiaDbusValuePattern (DCI.IValuePattern pattern)
		{
			this.pattern = pattern;
		}
Example #15
0
		public UiaDbusScrollItemPattern (DCI.IScrollItemPattern pattern)
		{
			this.pattern = pattern;
		}
Example #16
0
		public UiaDbusTogglePattern (DCI.ITogglePattern pattern)
		{
			this.pattern = pattern;
		}
Example #17
0
		public UiaDbusDockPattern (DCI.IDockPattern pattern)
		{
			this.pattern = pattern;
		}
Example #18
0
		public UiaDbusRangeValuePattern (DCI.IRangeValuePattern pattern)
		{
			this.pattern = pattern;
		}
Example #19
0
		public UiaDbusInvokePattern (DCI.IInvokePattern pattern)
		{
			this.pattern = pattern;
		}