diff --git a/src/main/java/org/gcube/portlets/widgets/imagepreviewerwidget/client/ui/Carousel.java b/src/main/java/org/gcube/portlets/widgets/imagepreviewerwidget/client/ui/Carousel.java index 2b6406a..037f363 100644 --- a/src/main/java/org/gcube/portlets/widgets/imagepreviewerwidget/client/ui/Carousel.java +++ b/src/main/java/org/gcube/portlets/widgets/imagepreviewerwidget/client/ui/Carousel.java @@ -112,14 +112,6 @@ public class Carousel extends Composite{ mainModalPanel.show(); } - - /** - * Used to show this carousel. - */ - public void show(){ - - mainModalPanel.show(); - } @UiHandler("closeButton") public void closeOnClick(ClickEvent e){ @@ -169,6 +161,14 @@ public class Carousel extends Composite{ mainModalPanel.setTitle(listOfAttachmentsToShow.get(currentPreviewPosition).getTitleToShow()); } + + /** + * Used to show this carousel. + */ + public void show(){ + + mainModalPanel.show(); + } /** * Change the current image. @@ -191,5 +191,15 @@ public class Carousel extends Composite{ mainModalPanel.setTitle(listOfAttachmentsToShow.get(currentPreviewPosition).getTitleToShow()); } + + /** + * Change the set of images to show + * @param imagesToShow + */ + public void updateImages(List imagesToShow){ + + listOfAttachmentsToShow = imagesToShow; + + } }