void mouse_triple_click2(CGPoint point) { // some apps still expect to receive the single click event first // and then the double and triple click events mouse_double_click2(point); mouse_multi_click2(3, point); }
/* * Perform a double click at the given mouse position * * Implemented by first generating a single click, and then a double click., * Apps seem to respond more consistently to this behaviour since that is * how a human would have to generate a double click event. * * You can optionally specify a point to click; the mouse cursor will * instantly jump to the given point; otherwise the click event happens * at the current cursor position. * * @overload double_click() * @return [CGPoint] * @overload double_click(point) * @param point [CGPoint] * @return [CGPoint] */ static VALUE rb_mouse_double_click(const int argc, VALUE* const argv, UNUSED const VALUE self) { switch (argc) { case 0: mouse_double_click(); break; case 1: default: mouse_double_click2(rb_mouse_unwrap_point(argv[0])); } return CURRENT_POSITION; }
void mouse_double_click() { mouse_double_click2(mouse_current_position()); }