EBEAST: utilities.js: add {un}request_pointer_lock(), has_pointer_lock()
EBEAST: utilities.js: add {un}request_pointer_lock(), has_pointer_lock()

Maintaining requestPointerLock() and exitPointerLock() state across
async 'pointerlockchange' and 'pointerlockerror' notifications can become
tricky for multiple elements. The new API maintains the desired pointer
lock state in a central place and ensures locks are only held between
corresponding request_pointer_lock() and unrequest_pointer_lock() calls,
never *after* an unrequest_pointer_lock().

Signed-off-by: Tim Janik <6ec6ff229c4e1c5bbd5933ee92e6c5832ff023bb@gnu.org>

swesterfeld/beast,tim-janik/beast,tim-janik/beast,swesterfeld/beast,tim-janik/beast,swesterfeld/beast,tim-janik/beast,tim-janik/beast,swesterfeld/beast,swesterfeld/beast,swesterfeld/beast,tim-janik/beast,swesterfeld/beast,tim-janik/beast