PDA

View Full Version : TabItem Communication Issue



jeetmarwah
19 Jul 2010, 5:22 PM
Hi,

I am facing with this scenario where I have a TabPanel with 2 or more tabItems.

first TabItem 'WYSIWYG' is a URL
This is a JSP page with a textarea and TinyMCE. There is a javascript method 'getAllCOntent()' which returns the content of the text area.

the 2nd tabItem (Say 'Content')is a GXT component ContentPanel.
This is a GXT component and has a text area also.

Goal:
When the 'Content' tab is clicked or any other tab in that case, I want to invoke the method 'getAllContent()' that is defined in the first tab JSP. I know that this a iframe-to-iframe communication but I am not able to figure out how can I communicate from a GXT component to Javascript and vice versa.


Any help/example/direction is highly appreciated.

Thanks.

micgala
20 Jul 2010, 12:15 AM
Hi. This is done via JSNI.
Also, this is basic GWT, not GXT related.

Probably this can help you.
http://code.google.com/webtoolkit/doc/latest/DevGuideCodingBasicsJSNI.html

Regards,
Michel.