GWT - RichTextArea - ScrollTo

Posted by Yanick Rochon on Stack Overflow See other posts from Stack Overflow or by Yanick Rochon
Published on 2010-06-02T10:19:50Z Indexed on 2010/06/02 10:23 UTC
Read the original article Hit count: 229

Filed under:
|

If I have an RichTextArea like this :

RichTextArea rta = new RichTextArea();
rta.setHTML("<p id=\"foo\">Foo</p>....<p id=\"bar\">Bar</p>");

If I extend the RichTextArea class, how would be the proper way (cross-browser wise) to write a scrollTo() method?

Ex:

class RichTextAreaExt extends RichTextArea {
   ...
   public native void scrollTo(String element) /*-{
      // the underlaying DOMElement is an iframe, so....
   }-*/;
   ...
}

Thanks!

© Stack Overflow or respective owner

Related posts about gwt

Related posts about scrollto