3

An observation regarding the official jScrollPane full page scroll demo...

Click and drag the large vertical scrollbar controlling the window. I've noticed the following behavior when you click+drag the scrollbar and the mouse accidentally leaves the browser window:

  • Safari(XP): The scrollbar responds even when dragging outside of the browser window. Can't seem to break it. Awesome.
  • FF4(XP): The scrollbar stops responding. It responds again successfully when the mouse re-enters (you don't have to click to start dragging again). Slightly annoying.
  • IE8(XP): The scrollbar stops responding. It doesn't respond when the mouse re-enters either (you have to click to drag again). This is the worst of the three.

So Safari (and Webkit, I presume) handles mouse movement outside the window perfectly. Is it even possible to get IE and FF to behave similarly, or are those limitations of the Trident and Gecko engines?

Michael
  • 2,424
  • 2
  • 14
  • 26

1 Answers1

1

[I originally answered a completely different question here by mistake so editing to answer the correct question]

There is very little jScrollPane can do about this. I did a little research but it seems that different browsers behave differently when it comes to triggering rollout/mouseout events when the mouse leaves the browser window. This makes it hard to implement a consistent behaviour within jScrollPane (the problem also occurs when the mouse leaves an iframe if you use full body scroll on an iframe).

I think there are probably security reasons for browsers not reporting mouse movement outside of the window so there is probably very little that can be done about this :(

Community
  • 1
  • 1
vitch
  • 3,175
  • 3
  • 23
  • 25
  • What? I'm not using any UL's or hidden elements. I linked to an official demo as the example. Did you mean to reply to a different thread? – Michael Jun 11 '11 at 23:46
  • Yes I did! Sorry about the confusion! I'll replace the answer above with something actually relevant to your question! – vitch Jun 13 '11 at 10:47
  • No worries, thanks for your reply! That's what I was worried about. Oh well. I can live with that. :) – Michael Jun 13 '11 at 14:54