Open main menu

CDOT Wiki β

Changes

Implementing the Mouse Lock API in Firefox

278 bytes added, 16:22, 30 November 2011
Implementation
# <s>The browser must exit the mouse lock state if the user agent, window, or tab loses focus</s> - diogogmt
# <strike>Fixup NULLs being returned from lock() C++ implementation, should be NS*</strike> - Anachid
# The ESC key should exit mouse lock - diogogmt
# <strike>Mouse lock should only work when in Full Screen Mode</strike> - diogogmt, rhung
# <strike>[[Refactor nsIDOMNavigator changes for pointer attribute to be in separate interface]]</strike> humph
# <strike>When mouse lock is enabled clientX, clientY, screenX, and screenY must hold constant values as if the mouse did not move at all once mouse lock was entered.</strike> humph
# <s>Freeze mouse pointer in centre of window when mouse lock is enabled (e.g., moving the mouse causes an event, but forces the mouse to go back to the original position).</s> - JSilver999
# "Once mouse lock is acquired, stop mouse events from being fired to other elements that are not locked (e.g., only fire to locked element)."
# "The Mouse Lock API must exit the mouse lock state if the user agent, window, or tab loses focus"
# "Events that require the concept of a mouse cursor must not be dispatched (for example: mouseover, mouseout)" - rhung
# Reset the mouse position back to the original position when unlocking. - humph
# Restructure Lock method to do most of its operations in a separate thread. diogogmt
 
=====Out of Scope Implementation=====
 
Because we are only implementing Mouse Lock for Fullscreen elements, some aspects of the spec can/must be put off until later.
 
# The ESC key should exit mouse lock. This will currently exit fullscreen, and therefore mouse lock - diogogmt
# "Once mouse lock is acquired, stop mouse events from being fired to other elements that are not locked (e.g., only fire to locked element)." Only the fullscreen element will get events.
====Tests====