/**
* Update the vertical scrollbar if present.
*/
public void updateYScrollBar() {
if (Display.getCurrent() != null) {
Display.getCurrent().syncExec(new Runnable() {
public void run() {
ScrollBar scroll = getVerticalBar();
// scroll may be null
if (scroll != null) {
_oldVerticalScroll = -1; // guarantee a clean repaint
scroll.setMinimum(0);
scroll.setMaximum(getTotalHeight() - getFixedRowsHeight());
int height = getHeight();
if (_tableRect != null) {
height = _tableRect.height;
}
scroll.setThumb(height); // - getFixedRowsHeight() - getHeaderHeight());
scroll.setIncrement(50); // increment for arrows
scroll.setPageIncrement(getHeight()); // page increment areas
scroll.setSelection(getAbsBeginYForRowIdx(_firstRowIdx) + _firstRowPixelOffset
+ getFixedRowsHeight());
}
}
});
}
}
JaretTable.java 文件源码
java
阅读 36
收藏 0
点赞 0
评论 0
项目:translationstudio8
作者:
评论列表
文章目录