File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
src/main/java/com/actelion/research/gui/table Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -277,9 +277,11 @@ public void mouseMoved(MouseEvent e) {
277277 mDragStartRowHeight = mTable .getRowHeight ();
278278 int tolerance = HiDPIHelper .scale (cResizeTolerance );
279279 int row = y / mDragStartRowHeight ;
280+ if (row >= mTable .getRowCount ())
281+ row = -1 ;
280282 int fracY = y % mDragStartRowHeight ;
281283
282- mResizingStartRow = (fracY <= tolerance && row > 0 ) ? row - 1 : (fracY >= mDragStartRowHeight - tolerance ) ? row : -1 ;
284+ mResizingStartRow = (row == - 1 ) ? - 1 : ( fracY <= tolerance && row > 0 ) ? row - 1 : (fracY >= mDragStartRowHeight - tolerance ) ? row : -1 ;
283285 setCursor (mResizingStartRow == -1 ? JTableWithRowNumbers .sDefaultCursor : JTableWithRowNumbers .sResizeCursor );
284286
285287 if (mHighlightedRow != row ) {
You can’t perform that action at this time.
0 commit comments