Please help me I am working on your code. I wanted to show images on my
main page but it is not working. I am totally new to GWT.
public void onModuleLoad() {
Image base = new Image("resources/images/1.png");
VerticalPanel img = new VerticalPanel();
img.add(base);
final List imageURLs = new ArrayList();
// Add image urls to the above list
imageURLs.add("resources/images/1.png");
imageURLs.add("resources/images/1.png");
imageURLs.add("resources/images/1.png");
Timer timer = new Timer() {
int index = 0;
@Override
public void run() {
/*Set image URL to the image object created else where in your code*/
//image.setUrl((String)imageURLs.get(index);
image.setUrl((String)imageURLs.get(index));
index++;
if( ( imageURLs .size() -1) == index){
index = 0;
}
}
};
//timer.scheduleRepeating(1000) ;
RootPanel.get().add(img);
timer.scheduleRepeating(5000) ;
}
}
On Wednesday, August 6, 2008 10:06:30 PM UTC+5, Gaunt Face wrote:
>
> Cheers Srini Ill have a play thank you for the example code as well.
>
> Thanks alot
> Gaunt
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/google-web-toolkit/-/mjJPZRxa8ZkJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-web-toolkit?hl=en.