flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@apache.org
Subject svn commit: r1446311 - /flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/TextAreaBead.as
Date Thu, 14 Feb 2013 20:02:19 GMT
Author: pent
Date: Thu Feb 14 20:02:19 2013
New Revision: 1446311

URL: http://svn.apache.org/r1446311
Log:
Improved TextArea scrolling

Modified:
    flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/TextAreaBead.as

Modified: flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/TextAreaBead.as
URL: http://svn.apache.org/viewvc/flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/TextAreaBead.as?rev=1446311&r1=1446310&r2=1446311&view=diff
==============================================================================
--- flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/TextAreaBead.as
(original)
+++ flex/asjs/branches/develop/frameworks/as/src/org/apache/flex/html/staticControls/beads/TextAreaBead.as
Thu Feb 14 20:02:19 2013
@@ -132,16 +132,14 @@ package org.apache.flex.html.staticContr
 		
 		private function textScrollHandler(event:Event):void
 		{
-			/* This needs work. the calculation is still off. Reverting to basic
-			   values for scrolling and scroll position.
-			*/
-			//trace("numLines="+textField.numLines+", scrollV="+textField.scrollV+", bottom="+textField.bottomScrollV+",
max="+textField.maxScrollV);
 			var visibleLines:int = textField.bottomScrollV - textField.scrollV + 1;
 			var scrollableLines:int = textField.numLines - visibleLines + 1;
-			//trace("-- scrollableLines="+scrollableLines+", visibleLines="+visibleLines);
 			var vsbm:ScrollBarModel = ScrollBarModel(vScrollBar.model);
-			vsbm.maximum = textField.numLines;//scrollableLines;
+			vsbm.minimum = 0;
+			vsbm.maximum = textField.numLines+1;
 			vsbm.value = textField.scrollV;
+			vsbm.pageSize = visibleLines;
+			vsbm.pageStepSize = visibleLines;
 		}
 		
 		private function sizeChangedHandler(event:Event):void



Mime
View raw message