This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes GWT and the fly likes Pop up which will fix to window's left top coner without effected by scrolling Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » GWT
Bookmark "Pop up which will fix to window Watch "Pop up which will fix to window New topic
Author

Pop up which will fix to window's left top coner without effected by scrolling

au lai seong
Greenhorn

Joined: Mar 06, 2011
Posts: 14
How to do Pop up which will fix to window's left top coner without effected by scrolling? The pop up provided by gwt is effected by scrolling.
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10175
    
    8

Welcome to the Ranch.

1) Are you explicitly setting the popup position?
2) What panel do you have? DockLayoutPanel?


[How to ask questions] [Donate a pint, save a life!] [Onff-turn it on!]
au lai seong
Greenhorn

Joined: Mar 06, 2011
Posts: 14
Yes fixed position.
I am not using dock layout since my design is not application look&feel. The whole page is extending Composite with uibinder <g:HTMLPanel>
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10175
    
    8

In that case you can try using Window#getScrollLeft and Window#getScrollTop.
You might also need to attach a ScrollHandler to the Window.

Usually I use a DockLayoutPanel. With it, you can decide which part of the page will scroll and which will stay static.
So one would attach a static Widget to the DockLayoutPanel#North and then the popup location 0,0, would work.
au lai seong
Greenhorn

Joined: Mar 06, 2011
Posts: 14
I want website design which need scroll from browser. Dock layout is for application design. Will try on your suggestion.
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10175
    
    8

au lai seong wrote:I want website design which need scroll from browser. Dock layout is for application design.


As the name suggests, the DockLayoutPanel helps you lay out the child widget in the parent container. It has nothing to do with "application design" as you call it.
With the DockLayoutPanel, it is still possible to have the browser content scroll. All you need to do is wrap the scrollable widget inside a ScrollPanel and then add the ScrollPanel to the container
au lai seong
Greenhorn

Joined: Mar 06, 2011
Posts: 14
I think i understand what you meant. The website explain the dock layout panel
http://blog.discovr.net/post/516021390/layout-your-app-using-gwt-2-0-the-way-you-want-it

I will try it. Thanks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Pop up which will fix to window's left top coner without effected by scrolling
 
Similar Threads
can this button be align at the top left coner of a container
WA #1.....word association
Capturing the current window's cotents??
Capturing the current window's cotents?
Updating the value of Text box