[Swift-commit] r3197 - branches/1.0/src/org/griphyn/vdl/karajan/monitor/monitors/ansi/tui

noreply at svn.ci.uchicago.edu noreply at svn.ci.uchicago.edu
Wed Dec 16 19:38:42 CST 2009


Author: hategan
Date: 2009-12-16 19:38:41 -0600 (Wed, 16 Dec 2009)
New Revision: 3197

Modified:
   branches/1.0/src/org/griphyn/vdl/karajan/monitor/monitors/ansi/tui/Table.java
Log:
actually scroll tables

Modified: branches/1.0/src/org/griphyn/vdl/karajan/monitor/monitors/ansi/tui/Table.java
===================================================================
--- branches/1.0/src/org/griphyn/vdl/karajan/monitor/monitors/ansi/tui/Table.java	2009-12-03 20:19:20 UTC (rev 3196)
+++ branches/1.0/src/org/griphyn/vdl/karajan/monitor/monitors/ansi/tui/Table.java	2009-12-17 01:38:41 UTC (rev 3197)
@@ -159,6 +159,12 @@
 					((TableColumn) c).setSelectedRow(selectedRow);
 				}
 			}
+			if (selectedRow < firstRow) {
+			    firstRow = Math.min(selectedRow - height + 4, 0);
+			}
+			if (selectedRow > firstRow + height - 4) {
+			    firstRow = selectedRow;
+			}
 			redraw();
 		}
 	}




More information about the Swift-commit mailing list