Skip to content

Simulates key press/release, mouse move and mouse click events for OS-X.

Notifications You must be signed in to change notification settings

polym0rph/libmkms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Overview

The MacKeyboardMouseSimulator simulates key press/release, mouse move and mouse click events with the help of mac OS-X Quartz Event Service.

The simulator uses the C API for event taps to alter the stream of low-level user input events.

Some parts are taken from libsikuli (robot.cpp).

Example

mkms::MacKeyboardMouseSimulator simulator;

std::cout << "Simulating mouse move" << std::endl;
simulator.mouseMove(100, 100);

std::cout << "Simulating single mouse click" << std::endl;
simulator.mouseSingleClick(1);

std::cout << "Simulating key press 'a' " << std::endl;
simulator.pressOnce(VK_A);

Build process

How to build libmkms

  1. mkdir lib/build
  2. cd lib/build
  3. cmake ..
  4. make

How to build the sample app

  1. mkdir sample-app/build
  2. cd sample-app/build
  3. cmake ..
  4. make

Documentation

  1. cd lib/build
  2. make mkms-docs
  3. open ../docs/doxygen/html/index.html

About

Simulates key press/release, mouse move and mouse click events for OS-X.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published