本文整理汇总了Java中org.gwtbootstrap3.client.ui.constants.IconType.ANGLE_DOUBLE_LEFT属性的典型用法代码示例。如果您正苦于以下问题:Java IconType.ANGLE_DOUBLE_LEFT属性的具体用法?Java IconType.ANGLE_DOUBLE_LEFT怎么用?Java IconType.ANGLE_DOUBLE_LEFT使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.gwtbootstrap3.client.ui.constants.IconType
的用法示例。
在下文中一共展示了IconType.ANGLE_DOUBLE_LEFT属性的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createTablePager
protected HorizontalPanel createTablePager() {
HorizontalPanel pagerPanel = new HorizontalPanel();
pagerPanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_MIDDLE);
pagerPanel.getElement().setAttribute("cellpadding", "5");
Pagination pagination = new Pagination();
pagination.setPaginationSize(PaginationSize.NONE);
for (int i = leftMostPageNumber; i <= rightMostPageNumber; i++) {
AnchorListItem pageLink = new AnchorListItem(Integer.toString(i));
final Integer _currentPage = i;
if (currentPage != i) {
pageLink.setActive(false);
pageLink.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
getPresenter().gotoPage(_currentPage.intValue());
}
});
} else {
pageLink.setActive(true);
}
pagination.add(pageLink);
}
Icon leftPageIcon = new Icon(IconType.ANGLE_LEFT);
leftPageIcon.setSize(IconSize.LARGE );
leftPageIcon.getElement().getStyle().setCursor(Style.Cursor.POINTER);
leftPageIcon.sinkEvents(Event.ONCLICK);
leftPageIcon.addHandler(createGotoPageHandler(currentPage - 1), ClickEvent.getType());
Tooltip leftPageTooltip = new Tooltip(GoogleDisplayerConstants.INSTANCE.googleTableDisplayer_gotoPreviousPage());
leftPageTooltip.add(leftPageIcon);
Icon rightPageIcon = new Icon(IconType.ANGLE_RIGHT);
rightPageIcon.setSize(IconSize.LARGE);
rightPageIcon.getElement().getStyle().setCursor(Style.Cursor.POINTER);
rightPageIcon.sinkEvents(Event.ONCLICK);
rightPageIcon.addHandler(createGotoPageHandler(currentPage + 1), ClickEvent.getType());
Tooltip rightPageTooltip = new Tooltip( GoogleDisplayerConstants.INSTANCE.googleTableDisplayer_gotoNextPage() );
rightPageTooltip.add(rightPageIcon);
Icon firstPageIcon = new Icon(IconType.ANGLE_DOUBLE_LEFT);
firstPageIcon.setSize(IconSize.LARGE);
firstPageIcon.getElement().getStyle().setCursor(Style.Cursor.POINTER);
firstPageIcon.sinkEvents(Event.ONCLICK);
firstPageIcon.addHandler(createGotoPageHandler(1), ClickEvent.getType());
Tooltip firstPageTooltip = new Tooltip(GoogleDisplayerConstants.INSTANCE.googleTableDisplayer_gotoFirstPage());
firstPageTooltip.add(firstPageIcon);
Icon lastPageIcon = new Icon(IconType.ANGLE_DOUBLE_RIGHT);
lastPageIcon.setSize(IconSize.LARGE);
lastPageIcon.getElement().getStyle().setCursor(Style.Cursor.POINTER);
lastPageIcon.sinkEvents(Event.ONCLICK);
lastPageIcon.addHandler(createGotoPageHandler(totalPages), ClickEvent.getType());
Tooltip lastPageTooltip = new Tooltip(GoogleDisplayerConstants.INSTANCE.googleTableDisplayer_gotoLastPage());
lastPageTooltip.add(lastPageIcon);
pagerPanel.add(firstPageTooltip);
pagerPanel.add(leftPageTooltip);
pagerPanel.add(pagination);
pagerPanel.add(rightPageTooltip);
pagerPanel.add(lastPageTooltip);
if (totalPagesHintEnabled) {
pagerPanel.add(new Label(GoogleDisplayerConstants.INSTANCE.googleTableDisplayer_pages(
Integer.toString(leftMostPageNumber),
Integer.toString(rightMostPageNumber),
Integer.toString(totalPages))));
}
if (totalRowsHintEnabled) {
int currentRowsShown = currentPage * pageSize > totalRows ? totalRows : currentPage * pageSize;
pagerPanel.add(new Label(GoogleDisplayerConstants.INSTANCE.googleTableDisplayer_rows(
Integer.toString(((currentPage - 1) * pageSize) + 1),
Integer.toString(currentRowsShown),
Integer.toString(totalRows))));
}
return pagerPanel;
}