1.1.1 • Published 8 years ago
@digitalattitude/ui-automation v1.1.1
UI Automation Helper
===============
detect
Return promise with clicked element class name, hwnd and name.
focused
Return promise with currently focused element class name, hwnd and name.
Usage
$ npm install @digitalattitude/ui-automation
const AutomationHelper = require("@digitalattitude/ui-automation");
const helper = new AutomationHelper("ui-automation"); // spawns helper process
// Coordinates on the screen
const x = 100;
const y = 200;
helper.detect(x, y)
  .then(result => {
    const [className, hwnd, name] = result.split("; ");
    // do your work
  });
helper.focused()
  .then(result => {
    const [className, hwnd, name] = result.split("; ");
    // do your work
  });Action detection
const AutomationHelper = require("@digitalattitude/ui-automation");
const helper = new AutomationHelper("key-listener");
helper.events.on('action', data => { console.log('action', data) });Requirenemts
- node v6
 - .Net Framework 4.6.1