Open LionKenedi95 opened 3 years ago
It does that to handle pressing inside the canvas, moving outside of it then releasing. SDL expects to still get the mouse up event in that case. (https://github.com/emscripten-ports/SDL2/commit/b1060d944f6fa379494f5f221cdbd370505fa687)
It should only prevent the default action if the mouse was inside though... (https://github.com/emscripten-ports/SDL2/commit/ed82ab12287937ac09eb41f1b979c068966fed2a)
Hello.
Can you tell me why emscripten_set_mouseup_callback uses
document
as target, when emscripten_set_mousedown_callback takes data-> canvas_id as target. This may be a mistake.In my case, this solution breaks the standard input behavior on the page, which is very strange.
Thanks in advance for your reply and sorry for my english :)