-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSmartScroller.ctxt
20 lines (20 loc) · 2.54 KB
/
SmartScroller.ctxt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#BlueJ class context
comment0.target=SmartScroller
comment0.text=\n\ The\ SmartScroller\ will\ attempt\ to\ keep\ the\ viewport\ positioned\ based\ on\n\ the\ users\ interaction\ with\ the\ scrollbar.\ The\ normal\ behaviour\ is\ to\ keep\n\ the\ viewport\ positioned\ to\ see\ new\ data\ as\ it\ is\ dynamically\ added.\n\n\ Assuming\ vertical\ scrolling\ and\ data\ is\ added\ to\ the\ bottom\:\n\n\ -\ when\ the\ viewport\ is\ at\ the\ bottom\ and\ new\ data\ is\ added,\n\ then\ automatically\ scroll\ the\ viewport\ to\ the\ bottom\n\ -\ when\ the\ viewport\ is\ not\ at\ the\ bottom\ and\ new\ data\ is\ added,\n\ then\ do\ nothing\ with\ the\ viewport\n\n\ Assuming\ vertical\ scrolling\ and\ data\ is\ added\ to\ the\ top\:\n\n\ -\ when\ the\ viewport\ is\ at\ the\ top\ and\ new\ data\ is\ added,\n\ then\ do\ nothing\ with\ the\ viewport\n\ -\ when\ the\ viewport\ is\ not\ at\ the\ top\ and\ new\ data\ is\ added,\ then\ adjust\n\ the\ viewport\ to\ the\ relative\ position\ it\ was\ at\ before\ the\ data\ was\ added\n\n\ Similiar\ logic\ would\ apply\ for\ horizontal\ scrolling.\n
comment1.params=scrollPane
comment1.target=SmartScroller(javax.swing.JScrollPane)
comment1.text=\n\ Convenience\ constructor.\n\ Scroll\ direction\ is\ VERTICAL\ and\ viewport\ position\ is\ at\ the\ END.\n\n\ @param\ scrollPane\ the\ scroll\ pane\ to\ monitor\n
comment2.params=scrollPane\ viewportPosition
comment2.target=SmartScroller(javax.swing.JScrollPane,\ int)
comment2.text=\n\ Convenience\ constructor.\n\ Scroll\ direction\ is\ VERTICAL.\n\n\ @param\ scrollPane\ the\ scroll\ pane\ to\ monitor\n\ @param\ viewportPosition\ valid\ values\ are\ START\ and\ END\n
comment3.params=scrollPane\ scrollDirection\ viewportPosition
comment3.target=SmartScroller(javax.swing.JScrollPane,\ int,\ int)
comment3.text=\n\ Specify\ how\ the\ SmartScroller\ will\ function.\n\n\ @param\ scrollPane\ the\ scroll\ pane\ to\ monitor\n\ @param\ scrollDirection\ indicates\ which\ JScrollBar\ to\ monitor.\n\ \ \ \ \ \ \ \ Valid\ values\ are\ HORIZONTAL\ and\ VERTICAL.\n\ @param\ viewportPosition\ indicates\ where\ the\ viewport\ will\ normally\ be\n\ \ \ \ \ \ \ \ positioned\ as\ data\ is\ added.\n\ \ \ \ \ \ \ \ Valid\ values\ are\ START\ and\ END\n
comment4.params=e
comment4.target=void\ adjustmentValueChanged(java.awt.event.AdjustmentEvent)
comment5.params=
comment5.target=void\ run()
comment6.params=e
comment6.target=void\ checkScrollBar(java.awt.event.AdjustmentEvent)
comment6.text=\n\ Analyze\ every\ adjustment\ event\ to\ determine\ when\ the\ viewport\n\ needs\ to\ be\ repositioned.\n
numComments=7