mirror of
https://github.com/dyne/FreeJ.git
synced 2026-02-07 13:29:47 +01:00
14 lines
329 B
JavaScript
14 lines
329 B
JavaScript
m = new MouseController();
|
|
register_controller(m);
|
|
|
|
// MouseController.button(button, state, x, y)
|
|
m.button = function(b, s, x, y) {
|
|
echo("b"+b+" s"+s+" x"+x+" y"+y);
|
|
this.grab(s);
|
|
}
|
|
|
|
// MouseController.motion(buttonmask, x, y, xrel, yrel)
|
|
m.motion = function(b, x, y, dx, dy) {
|
|
echo("b"+b+" x"+x+" y"+y+" dx"+dx+" dy"+dy);
|
|
}
|