|
Project Information
Links
|
GWT CarouselThe only aim of this project is to provide a pure GWT implementation of carousel widget. GWT Carousel runs on variety of web browsers: Mozilla FireFox, Chrome, Safari, Opera. The widget fits well into new predictable layout introduced in GWT 2.0. I highly recommend reading relevant documentation. Image animation is based on animation of GWT 2.0. ExampleHave a look at the gallery example to see it in action. UsageInclude Carousel module in your project gwt.xml file: <inherits name='sk.gtug.carousel.Carousel' /> and then use it as any other Widget in your application: import sk.gtug.carousel.client.Carousel;
import sk.gtug.carousel.client.CarouselImageProvider;
import sk.gtug.carousel.client.ImageHandle;
import sk.gtug.carousel.client.ImageLoader;
import sk.gtug.carousel.client.ImageLoader.CallBack;
...
{
Carousel carousel = new Carousel();
carousel.setImageProvider(...);
RootLayoutPanel rootLayoutPanel = RootLayoutPanel.get();
rootLayoutPanel.add(carousel);
...
rootLayoutPanel.forceLayout();
}Don't forget to define DOCTYPE in html file to make new layouting work properly: <!doctype html> <html> ... </html> Image ProviderIn order to supply a collection of images CarouselImageProvider implementation has to be given to Carousel. It provides ImageHandle instances of images containing information regarding url, width and height of the image. ImageLoader is a convenient class to achive desired result. ImageHandler and ImageLoader are classes from SpeedTracer project. SpeedTracer (released together with GWT 2.0) also provides a great source of information and practices for developers using GWT. RoadmapCurrent project is in early stage and very basic functionality is provided. Following features are planned: TODOsversion 0.1
version 0.2
|