Re: If not Multiple-Contents, how do we have Widgets with multiple modes?

Hi Ivan,

2009/2/9 ivan.demarino <>:
> Hello.
> I'm following the specs evolving for Window Modes (
> Given the fact that the "content tag" has an occurrence of "0 or 1", and the fact that the "mode" is one, my question is:
> - Would it be possible to have widgets that have "multiple views"?
> I dug into the "widgets-api", and what it looks like is the fact that the only place where the widget should handle "mode change" is the call-back named "onmodechange()".
> That's fine.
> But we are assuming that there is an "initial mode" chosen by the Developer and that the widget "change it's shape" based on the event "onmodechange".
> - What if the Developer can't know in which mode the Widget will start?

We could make it explicit that the widget user agent should attempt to
start the widget in the mode the author declared (or in floating, as
is the default).

> - What if the "User-Agent" running the Widget does not pass a "onmodechange", because NO MODE WAS CHANGED: it was simply initialized with a mode different from the one chosen in the "config.xml"?

We could specify that a user agent must fire a mode change event if it
initializes the widget in a mode other than the default or the mode
that the author specified.

> It's a bit "tricky" to explain, but I can give more details if needed.

If the above would not help, then more details would be helpful to
build a use case.

> One of the great thing of having "widgets with multiple modes", is the fact that the same widget can run in different scenarios, based on the hosting platform screen resolution AND other requirements. The widget has to adapt itself at "load time".


> A widget that, for example, run in "window mode" and just after load has to change to "docked", because that's the mode supported by the current User-Agent, will look "clunky" and "not seamlessly integrated".
> What do you think?

This may be true. Can you go into more details about how we might
overcome this? is this an author's problem or a user agent problem?
what more can we do on the user agent side to overcome this issue?

Kind regards,
Marcos Caceres

Received on Friday, 13 February 2009 13:27:23 UTC