Re: HTML 5 window.showModalDialog parameters

On Thu, 9 Apr 2009, Smith, Jeremy wrote:
>
> The 
> sFeatures<http://msdn.microsoft.com/en-us/library/ms536759(VS.85).aspx> 
> (IE) or 
> options<https://developer.mozilla.org/en/DOM/window.showModalDialog> 
> (FF) parameter to window.showModalDialog appears to be missing in the 
> HTML 5 spec for this API.  I'm wondering how the user of the API will 
> then be able to control the size and placement of the dialog, for 
> example?

The user agent is able to control the placement and size of the dialog for 
the optimal user experience; the author doesn't have to give a position at 
all. (Indeed, the author is in no position to know what the best size 
should be, since it could vary based on the user's preferences, font 
settings, etc.)


> I'm also curious as to why the signature does not match the currently 
> implemented version of the API in most major browsers (Chrome, Safari, 
> IE, FF)?

Since the features argument is the last argument, and it does nothing in 
HTML5, I figured it was simpler to just omit it (extra arguments are 
ignored).

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Wednesday, 3 June 2009 20:13:13 UTC