Header's tooltip now is shown correctly
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/widgets/image-previewer-widget@122643 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
72a78d1e16
commit
9fd8747bb6
|
@ -11,6 +11,8 @@ import com.github.gwtbootstrap.client.ui.Modal;
|
|||
import com.github.gwtbootstrap.client.ui.constants.IconSize;
|
||||
import com.github.gwtbootstrap.client.ui.constants.IconType;
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.dom.client.Element;
|
||||
import com.google.gwt.dom.client.NodeList;
|
||||
import com.google.gwt.dom.client.Style.Cursor;
|
||||
import com.google.gwt.event.dom.client.ClickEvent;
|
||||
import com.google.gwt.event.dom.client.ClickHandler;
|
||||
|
@ -288,6 +290,10 @@ public class Carousel extends Composite{
|
|||
listOfAttachmentsToShow.get(currentPreviewPosition).getTitleToShow();
|
||||
mainModalPanel.setTitle(shownTitle);
|
||||
|
||||
// to set the tooltip we have to lookup the title in the header (it's a <h3> element)
|
||||
NodeList<Element> list = mainModalPanel.getElement().getElementsByTagName("h3");
|
||||
list.getItem(0).setTitle(listOfAttachmentsToShow.get(currentPreviewPosition).getTitleToShow());
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue