widgets have a method called setAutoHeight() which will do exactly
what you want.
However, I haven't tried this, but give it a shot. This might have to
go in an class that extends Frame.
link.addClickListener(new ClickListener() {
public void onClick(ClickEvent event) {
changeContentsOfFrame();
newPageInFrame(frame.getElement());
}
});
native void newPageInFrame(Element frame) /*-{
//Remember, JavascriptObject, Element, and the
//primitives are directly accessible in JSNI code.
//Thus frame here should be -the-frame.
var FramePageHeight = framePage.scrollHeight + 10;
/* framePage is the ID of the framed page's BODY
* tag. The added 10 pixels prevent an unnecessary
* scrollbar. */
frame.style.height=FramePageHeight;
}-*/;
Tom
On Jul 28, 10:28 pm, bcw <bcw1...@gmail.com> wrote:
> Hello,
>
> I've tried ideas in several posts, but none gets me what I need.
>
> If I assign a URL to a Frame, and also set a fixed size that is
> smaller than the resulting page, the Frame provides scroll bars.
>
> But my Frame is itself embedded in another page which provides the
> scroll bars. I want to set the Frame so it is large enough (and only
> large enough) to render the URL page without any scrollbars, and use
> the outer page's scroll bars to see it.
>
> I can't find any way to do this. I can't find anyway to get the size
> of the entire page contained within the Frame.
>
> Please let me know a way to do this. The Frame is positioned on an
> AbsolutePanel.
--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
No comments:
Post a Comment