W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2011

[Pointer Lock] Few comments

From: Olli Pettay <Olli.Pettay@helsinki.fi>
Date: Thu, 15 Dec 2011 16:16:15 +0200
Message-ID: <4EEA012F.2050909@helsinki.fi>
To: Webapps WG <public-webapps@w3.org>, scheib@google.com
Hi all,

few comments about the API

(1)
currently 
http://dvcs.w3.org/hg/webevents/raw-file/default/mouse-lock.html uses 
VoidCallback which isn't defined anywhere.

I guess there should be something like

void lock (in Element target,
            optional in LockSuccessCallback successCallback,
            optional in LockErrorCallback failureCallback);


[Callback,NoInterfaceObject]
interface LockSuccessCallback {
   void pointerLockSuccess();
};

[Callback,NoInterfaceObject]
interface LockErrorCallback {
   void pointerLockFailure();
};

Or if the new proposed callback syntax is used:
callback LockSuccessCallback = void pointerLockSuccess();
callback LockErrorCallback = void pointerLockFailure();


(2)
"If another element is locked a user agent must transfer the mouse lock 
to the new target and call the pointerlocklost callback for the previous 
target."
There is no such thing as 'pointerlocklost callback'

(3)
"Mouse lock must succeed only if the window is in focus and the 
user-agent is the active application of the operating system"
What window? window object as in web page? Or OS level window?
What if lock is called in some iframe?

(4)
"If the target is removed from the DOM tree after mouse lock is entered 
then mouse lock will be lost."
Should 'pointerlocklost' event be dispatched?




-Olli
Received on Thursday, 15 December 2011 14:20:00 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:49 GMT