From: Richard K. <ric...@us...> - 2005-05-27 20:53:21
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18966 Modified Files: NSClipView.as Log Message: Got scroller working Index: NSClipView.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSClipView.as,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** NSClipView.as 27 May 2005 01:47:09 -0000 1.2 --- NSClipView.as 27 May 2005 20:53:12 -0000 1.3 *************** *** 93,97 **** public function scrollToPoint(point:NSPoint) { ! setBoundsOrigin(constrainScrollPoint(point)); } --- 93,100 ---- public function scrollToPoint(point:NSPoint) { ! TRACE("point: "+point); ! point = constrainScrollPoint(point); ! TRACE("point constrained: "+point); ! setBoundsOrigin(point); } *************** *** 107,111 **** } else if (point.x <= documentFrame.origin.x) { newPoint.x = documentFrame.origin.x; ! } else if (point.x + m_bounds.size.width >= documentFrame.maxX()) { newPoint.x = documentFrame.maxX() - m_bounds.size.width; } --- 110,114 ---- } else if (point.x <= documentFrame.origin.x) { newPoint.x = documentFrame.origin.x; ! } else if ((point.x + m_bounds.size.width) >= documentFrame.maxX()) { newPoint.x = documentFrame.maxX() - m_bounds.size.width; } *************** *** 115,119 **** } else if (point.y <= documentFrame.origin.y) { newPoint.y = documentFrame.origin.y; ! } else if (point.y + m_bounds.size.height >= documentFrame.maxY) { newPoint.y = documentFrame.maxY() - m_bounds.size.height; } --- 118,122 ---- } else if (point.y <= documentFrame.origin.y) { newPoint.y = documentFrame.origin.y; ! } else if ((point.y + m_bounds.size.height) >= documentFrame.maxY()) { newPoint.y = documentFrame.maxY() - m_bounds.size.height; } *************** *** 191,195 **** } super.setBoundsOrigin(point); ! m_documentView.setNeedsDisplay(true); NSScrollView(m_superview).reflectScrolledClipView(this); } --- 194,198 ---- } super.setBoundsOrigin(point); ! //m_documentView.setNeedsDisplay(true); NSScrollView(m_superview).reflectScrolledClipView(this); } |