On 2/12/10 7:30 AM, Babele Dunnit wrote:
1) I parse the DOM and encounter a DIV (or HTML block-level element?
what you mean? which other elements should I check? please excuse my
HTML newbie question :))

This isn't an HTML issue. It's a CSS issue. Any non-replaced block in CSS can be scrollable, effectively. Note that this is independent of the HTML concept of block-level; if I stick "display: block" on an HTML <span>, it can be scrollable.

2) I get the DIV scroll extents (scrollH and scrollW) and I check them
against... what? Parent client extents? How do I understand that a DIV
will be able to scroll its "inside"?

You could compare its scrollHeight to its clientHeight, right?

With eyetracking we obviously do not use scrollbars; the idea is to
register the extents of these scrolling areas, and when one looks near
the borders, it starts scrolling. OK, not so easy, we must use timers
and a lot of tricks with multiple overlapping zones, but it worked
quite well up to now...

So yeah, you need to hit test and then walk up the frame tree from the hit (or maybe dom tree is enough? Not sure how much you care about XBL) looking for something scrollable.

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

Reply via email to