Le 12/08/2013 11:44, Alive a écrit :
> Interesting, but only Keyboard app knows its actual height,
> and as far as we're introducing 3 party keyboard, there may be a
> 'fullscreen' keyboard implementation.
>
> I am not sure if media query could cover the use case without fail.
> You don't want to use media query to record each keyboard app height
> in your app, right?
>
> So far an app window height is affected by:
>
> 1. Keyboard height (?)
> 2. Statusbar height (2rem to 4rem now)
> 3. Wrapper footer(the navigation UI) height (1rem to 5 or 6rem now)
> 4. Fullscreen state
> 5. Orientation state
>
> I am uncertain if we could judge 'now keyboard is there' from some
> math statement in media query.

We actually do this in JavaScript in the Messages app (but it's quite
fragile and it broke once already when suggestions get added).

but what Schlomi said was:
"Viewport getting shrinked and I need to control the UI on this event."

Therefore, the real question is: "my viewport is shrinked, how can I
detect this ?". Which sounds a lot like media queries to me ;)

So my proposition was: let's not detect we have a keyboard, let's detect
screen size changes instead (that's what the resize event does too after
all).

-- 
Julien

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
dev-b2g mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-b2g

Reply via email to