How to fix a div (or a panel...) after some scroll ?

119 views
Skip to first unread message

regnoult axel

unread,
Jul 21, 2012, 10:31:42 AM7/21/12
to google-we...@googlegroups.com
Hello,

I am trying to achieve this effect : http://massless.org/pegs/
You can see that after scrolling, the left navigation bar stay fixed on the top of the page.

How could I achieve a such effect with GWT ? 

Regards,

Joseph Lust

unread,
Jul 27, 2012, 1:50:43 PM7/27/12
to google-we...@googlegroups.com

They are using a listener to detect scrolling and then winching the header div up as you scroll down. This makes it appear to scroll off the screen as part of the page, but really it is absolutely positioned.

See the code they use here:

You just need to replicate this structure, logic, and listeners in GWT.

Sincerely,
Joseph
Reply all
Reply to author
Forward
0 new messages