/* * Generate a click event for the middle mouse button (down and up events) * * It doesn't matter if you don't have a middle mouse button. * * 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 middle_click() * @return [CGPoint] * @overload middle_click(point) * @param point [CGPoint] * @return [CGPoint] */ static VALUE rb_mouse_middle_click(const int argc, VALUE* const argv, UNUSED const VALUE self) { switch (argc) { case 0: mouse_middle_click(); break; case 1: default: mouse_middle_click2(rb_mouse_unwrap_point(argv[0])); } return CURRENT_POSITION; }
void mouse_middle_click() { mouse_middle_click2(mouse_current_position()); }