Re: [whatwg] MediaModeAbstractView and changing of media dynamically

2009-02-10 Thread Ian Hickson
On Wed, 20 Sep 2006, Anne van Kesteren wrote:
> On Tue, 19 Sep 2006 23:27:12 -, Joao Eiras  wrote:
> >
> > So, I suggest the creation of the 'media-change' event, which will 
> > fire when the UA changes media, having the document as target. The 
> > event object could be an instance of a UIEvent, and have 2 extra 
> > properties: newMediaMode, and oldMediaMode.
> 
> This has already been suggested multiple times on this list. Personally, 
> I think a better place is probably the new CSSOM (whenever I get around 
> to it...).

I agree that this would be better in CSSOM.

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


Re: [whatwg] MediaModeAbstractView and changing of media dynamically

2006-09-20 Thread Anne van Kesteren
On Tue, 19 Sep 2006 23:27:12 -, Joao Eiras <[EMAIL PROTECTED]>  
wrote:
So, I suggest the creation of the 'media-change' event, which will fire  
when the UA changes media, having the document as target.
The event object could be an instance of a UIEvent, and have 2 extra  
properties: newMediaMode, and oldMediaMode.


This has already been suggested multiple times on this list. Personally, I  
think a better place is probably the new CSSOM (whenever I get around to  
it...).



--
Anne van Kesteren





[whatwg] MediaModeAbstractView and changing of media dynamically

2006-09-19 Thread Joao Eiras
For me, the w3c DOM 2 stylesheets spec always had the gap, which  
MediaModeAbstractView fixes: a variable which holds the current media how  
the page is being rendered.
But there's another small gap. Some UAs (Opera for desktop only to my  
knowledge) can change the current media by displaying a webpage as  
fullscreen (projection) or enabling small screen rendering (handheld). I  
assume future versions will allow Opera to trigger tv mode, for  
development sake. Also any other browsers can change from normal rendering  
(screen) to print preview (print).


The only way for a script to keep track of this variable value, is to set  
an interval, polling the variable.

I don't consider refreshing the page as valid workaround.

So, I suggest the creation of the 'media-change' event, which will fire  
when the UA changes media, having the document as target.
The event object could be an instance of a UIEvent, and have 2 extra  
properties: newMediaMode, and oldMediaMode.