You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(124) |
Jun
(201) |
Jul
(168) |
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
---|
From: Richard K. <ric...@us...> - 2005-06-29 07:00:27
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6981 Modified Files: NSBox.as Log Message: added support for the title spacing and a groove box Index: NSBox.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSBox.as,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** NSBox.as 10 Jun 2005 06:56:12 -0000 1.8 --- NSBox.as 29 Jun 2005 07:00:19 -0000 1.9 *************** *** 375,379 **** var txtSize:NSSize = titleFont().getTextExtent(title()); // Get the text size. ! var txtLoc:NSPoint = new NSPoint(10, 0); var bdrRect:NSRect = m_bounds.clone(); var cntRect:NSRect = m_bounds.clone(); --- 375,380 ---- var txtSize:NSSize = titleFont().getTextExtent(title()); // Get the text size. ! txtSize.width+=1; ! var txtLoc:NSPoint = new NSPoint((m_bounds.size.width - txtSize.width)/2, 0); var bdrRect:NSRect = m_bounds.clone(); var cntRect:NSRect = m_bounds.clone(); *************** *** 477,489 **** case NSBorderType.NSLineBorder: ! ASDraw.outlineRectWithRect(m_mcBounds, aRect, [0]); break; case NSBorderType.NSBezelBorder: ! ASDraw.outlineRectWithRect(m_mcBounds, aRect, [0]); break; case NSBorderType.NSGrooveBorder: ! ASDraw.outlineRectWithRect(m_mcBounds, aRect, [0]); break; --- 478,506 ---- case NSBorderType.NSLineBorder: ! if (excludeRect != undefined) { ! ASDraw.outlineRectWithRectExcludingRect(m_mcBounds, aRect, excludeRect, [0]); ! } else { ! ASDraw.outlineRectWithRect(m_mcBounds, aRect, [0]); ! } break; case NSBorderType.NSBezelBorder: ! if (excludeRect != undefined) { ! ASDraw.outlineRectWithRectExcludingRect(m_mcBounds, aRect, excludeRect, [0]); ! } else { ! ASDraw.outlineRectWithRect(m_mcBounds, aRect, [0]); ! } break; case NSBorderType.NSGrooveBorder: ! if (excludeRect != undefined) { ! ASDraw.outlineRectWithRectExcludingRect(m_mcBounds, aRect, excludeRect, [0xDDDDDD]); ! ASDraw.outlineRectWithRectExcludingRect(m_mcBounds, new NSRect(aRect.origin.x+1, aRect.origin.y+1, aRect.size.width, aRect.size.height), excludeRect, [0xDDDDDD]); ! ASDraw.outlineRectWithRectExcludingRect(m_mcBounds, new NSRect(aRect.origin.x, aRect.origin.y, aRect.size.width-1, aRect.size.height-1), excludeRect, [0x333333]); ! } else { ! ASDraw.outlineRectWithRect(m_mcBounds, aRect, [0xDDDDDD]); ! ASDraw.outlineRectWithRect(m_mcBounds, new NSRect(aRect.origin.x+1, aRect.origin.y+1, aRect.size.width, aRect.size.height), [0xDDDDDD]); ! ASDraw.outlineRectWithRect(m_mcBounds, new NSRect(aRect.origin.x, aRect.origin.y, aRect.size.width-1, aRect.size.height-1), [0x333333]); ! } break; |
From: Richard K. <ric...@us...> - 2005-06-29 06:59:48
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6691 Modified Files: ASTextRenderer.as Log Message: does not draw background if drawsBackground is false and add convenience function to set a CSS style as a string Index: ASTextRenderer.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASTextRenderer.as,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** ASTextRenderer.as 22 Jun 2005 18:12:09 -0000 1.3 --- ASTextRenderer.as 29 Jun 2005 06:59:39 -0000 1.4 *************** *** 138,141 **** --- 138,151 ---- return m_style; } + + public function setStyleCSS(css:String):Boolean { + var style:TextField.StyleSheet = new TextField.StyleSheet(); + if (style.parseCSS(css)) { + setStyleSheet(style); + return true; + } else { + return false; + } + } public function setText(text:String) { *************** *** 164,168 **** public function drawRect(rect:NSRect) { ! ASTheme.current().drawListWithRectInView(rect, this); } --- 174,180 ---- public function drawRect(rect:NSRect) { ! if (m_drawsBackground) { ! ASTheme.current().drawListWithRectInView(rect, this); ! } } |
From: Richard K. <ric...@us...> - 2005-06-29 06:58:35
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6370 Modified Files: ASDraw.as Log Message: added outlineRectWithExcludeRect Index: ASDraw.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASDraw.as,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** ASDraw.as 22 Jun 2005 08:02:05 -0000 1.12 --- ASDraw.as 29 Jun 2005 06:58:26 -0000 1.13 *************** *** 733,736 **** --- 733,787 ---- /////////////////////////////////////////// // OUTLINE RECT METHODS + + public static function outlineRectWithRectExcludingRect(mc:MovieClip, rect:NSRect, exclude:NSRect, colors:Array) { + var x = rect.origin.x; + var y = rect.origin.y; + var width = rect.size.width; + var height = rect.size.height; + colors = getArrayOfFour(colors); + var alphas:Array = buildArray(colors.length, 100); + + var iRect:NSRect = rect.intersectionRect(exclude); + var excludeTop = true; + if (iRect.maxY() == rect.maxY()) { + excludeTop = false; + } + + //change width and height so that the total width/height, including line thickness is the given width/height. + var x2 = x + width -1; + var y2 = y + height -1; + var lineThickness = 1; + + mc.lineStyle(lineThickness, colors[0], alphas[0]); + mc.moveTo( x, y); + if (excludeTop) { + mc.lineTo(iRect.minX(), y); + mc.moveTo(iRect.maxX(), y); + } + mc.lineTo(x2, y); + + //TODO Why the eff won't the bottom right pixel draw? + mc.lineStyle(lineThickness, colors[1], alphas[1]); + mc.lineTo(x2, y2); + + + mc.lineStyle(lineThickness, colors[2], alphas[2]); + if (!excludeTop) { + mc.lineTo(iRect.maxX(), y2); + mc.moveTo(iRect.minX(), y2); + } + mc.lineTo( x, y2); + + mc.lineStyle(lineThickness, colors[3], alphas[3]); + mc.lineTo( x, y); + + // need to draw the bottom right pixel separately for some reason. + // I can't get any line to draw there, so I'm using the 'pixel' method, which is actually a fill. + + drawPointWithAlpha(mc, x2, y2, colors[1], alphas[1]); + + + } + public static function outlineRectWithRect(mc:MovieClip, rect:NSRect, colors:Array, ratios:Array){ outlineRect(mc, rect.origin.x, rect.origin.y, rect.size.width, rect.size.height, colors); |
From: Richard K. <ric...@us...> - 2005-06-29 06:58:07
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6209 Modified Files: ASEventMonitor.as Log Message: changed the move box to 10x10 Index: ASEventMonitor.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASEventMonitor.as,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** ASEventMonitor.as 28 Jun 2005 00:41:53 -0000 1.14 --- ASEventMonitor.as 29 Jun 2005 06:57:47 -0000 1.15 *************** *** 120,125 **** if ((getTimer() - m_lastMouseDownTime) < m_multiClickSpeed && ! (Math.abs(x - m_lastMouseDownEvent.mouseLocation.x)) < 20 && ! (Math.abs(y - m_lastMouseDownEvent.mouseLocation.y)) < 20) { m_lastMouseDownEvent.clickCount++; m_lastMouseDownTime = getTimer(); --- 120,125 ---- if ((getTimer() - m_lastMouseDownTime) < m_multiClickSpeed && ! (Math.abs(x - m_lastMouseDownEvent.mouseLocation.x)) < 10 && ! (Math.abs(y - m_lastMouseDownEvent.mouseLocation.y)) < 10) { m_lastMouseDownEvent.clickCount++; m_lastMouseDownTime = getTimer(); |
From: Scott H. <sco...@us...> - 2005-06-29 05:04:48
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18865/src/org/actionstep Modified Files: ASUtils.as Log Message: Added -indicesOfString() - returns an array containing the indices of the found token in a string -countIndicesOf() - returns the number of instances of a token found in a string Index: ASUtils.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASUtils.as,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ASUtils.as 24 Jun 2005 02:06:52 -0000 1.10 --- ASUtils.as 29 Jun 2005 05:04:37 -0000 1.11 *************** *** 100,102 **** --- 100,134 ---- if(!f) TRACE("not found"); } + + + /** + * Returns the number of occurences of token in str. + */ + public static function countIndicesOf(str:String, token:String):Number + { + return ASUtils.indicesOfString(str, token).length; + } + + + /** + * Returns the indicies of one sting in another. + */ + public static function indicesOfString(str:String, token:String):Array + { + var result:Array = new Array(); + var curpos:Number = 0; + + while (curpos != -1 && curpos < str.length) + { + curpos = str.indexOf(token, curpos); + + if (curpos != -1) + { + result.push(curpos); + ++curpos; + } + } + + return result; + } } \ No newline at end of file |
From: Scott H. <sco...@us...> - 2005-06-29 02:21:01
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep/test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3485/src/org/actionstep/test Added Files: ASTestArray.as ASTestArrayElement.as Log Message: Classes used to test array sorting --- NEW FILE: ASTestArray.as --- (This appears to be a binary file; contents omitted.) --- NEW FILE: ASTestArrayElement.as --- (This appears to be a binary file; contents omitted.) |
From: Scott H. <sco...@us...> - 2005-06-29 02:19:53
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3007/src/org/actionstep Modified Files: NSSortDescriptor.as Log Message: Changed selector stuff Updated compareObjectToObject to use sort order Added static internal method to handle multiple sorts Index: NSSortDescriptor.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSSortDescriptor.as,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** NSSortDescriptor.as 28 Jun 2005 23:33:42 -0000 1.1 --- NSSortDescriptor.as 29 Jun 2005 02:19:44 -0000 1.2 *************** *** 32,36 **** --- 32,38 ---- */ + import org.actionstep.NSArray; import org.actionstep.NSCopying; + import org.actionstep.NSEnumerator; import org.actionstep.NSObject; import org.actionstep.constants.NSComparisonResult; *************** *** 49,53 **** private var m_key:String; private var m_ascending:Boolean; ! private var m_selector:Function; --- 51,55 ---- private var m_key:String; private var m_ascending:Boolean; ! private var m_selector:String; *************** *** 69,73 **** m_key = key; m_ascending = ascending; ! m_selector = NSSortDescriptor.defaultSelector; // default return this; --- 71,75 ---- m_key = key; m_ascending = ascending; ! m_selector = "compare"; // default return this; *************** *** 79,83 **** * sort order of ascending, a the selector selector used to perform the sort. */ ! public function initWithKeyAscendingSelector(key:String, ascending:Boolean, selector:Function) :NSSortDescriptor { --- 81,85 ---- * sort order of ascending, a the selector selector used to perform the sort. */ ! public function initWithKeyAscendingSelector(key:String, ascending:Boolean, selector:String) :NSSortDescriptor { *************** *** 136,140 **** * Returns the selector the NSSortDescriptor will use to compare objects. */ ! public function selector():Function { return m_selector; --- 138,142 ---- * Returns the selector the NSSortDescriptor will use to compare objects. */ ! public function selector():String { return m_selector; *************** *** 155,162 **** :NSComparisonResult { if (m_key == null) ! return m_selector(object1, object2); else ! return m_selector(object1[m_key], object2[m_key]); } --- 157,183 ---- :NSComparisonResult { + var res:NSComparisonResult; + if (m_key == null) ! res = object1[m_selector](object2); else ! res = object1[m_selector].call(object1[m_key], object2[m_key]); //! this seems wrong to me ! ! // ! // Flip ascending to descending and vice-versa if sort order is descending. ! // ! if (!m_ascending) ! { ! if (res == NSComparisonResult.NSOrderedSame) ! { ! // do nothing ! } ! else if (res == NSComparisonResult.NSOrderedAscending) ! res = NSComparisonResult.NSOrderedDescending; ! else if (res == NSComparisonResult.NSOrderedDescending) ! res = NSComparisonResult.NSOrderedAscending; ! } ! ! return res; } *************** *** 191,193 **** --- 212,236 ---- return NSComparisonResult.NSOrderedSame; } + + //****************************************************** + //* Internal Static Methods + //****************************************************** + + public static function compareObjectToObjectWithDescriptors(object1:Object, + object2:Object, descriptors:NSArray):NSComparisonResult + { + var en:NSEnumerator = descriptors.objectEnumerator(); + var sd:NSSortDescriptor; + var ret:NSComparisonResult; + + while (null != (sd = NSSortDescriptor(en.nextObject()))) + { + ret = sd.compareObjectToObject(object1, object2); + + if (ret != NSComparisonResult.NSOrderedSame) + break; + } + + return ret; + } } |
From: Scott H. <sco...@us...> - 2005-06-29 02:19:09
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2578/src/org/actionstep Modified Files: NSArray.as Log Message: Added and tested sorting methods Index: NSArray.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSArray.as,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** NSArray.as 10 Jun 2005 02:56:17 -0000 1.14 --- NSArray.as 29 Jun 2005 02:19:00 -0000 1.15 *************** *** 33,39 **** import org.actionstep.NSEnumerator; import org.actionstep.NSObject; import org.actionstep.NSRange; ! import org.actionstep.NSException; /** --- 33,41 ---- import org.actionstep.NSEnumerator; + import org.actionstep.NSException; import org.actionstep.NSObject; import org.actionstep.NSRange; ! import org.actionstep.NSSortDescriptor; ! import org.actionstep.constants.NSComparisonResult; /** *************** *** 57,61 **** //****************************************************** ! //* Properties * //****************************************************** --- 59,63 ---- //****************************************************** ! //* Properties //****************************************************** *************** *** 136,140 **** //****************************************************** ! //* Public Methods * //****************************************************** --- 138,142 ---- //****************************************************** ! //* Public Methods //****************************************************** *************** *** 149,154 **** insertObjectAtIndex(anObject, m_list.length); } - /** * Clears the collection. --- 151,156 ---- insertObjectAtIndex(anObject, m_list.length); } + /** * Clears the collection. *************** *** 159,163 **** public function clear():Void { ! m_list = new Array(); } --- 161,165 ---- public function clear():Void { ! removeAllObjects(); } *************** *** 403,406 **** --- 405,443 ---- /** + * Clears the collection. + * + * This operation should not be performed while the collection is being + * enumerated. + */ + public function removeAllObjects():Void + { + m_list = new Array(); + } + + + /** + * Removes the last object in the collection. + * + * An exception is raised if the collection is empty. + */ + public function removeLastObject():Void + { + if (m_list.length == 0) + { + var e:NSException = NSException.exceptionWithNameReasonUserInfo( + "RangeException", + "NSArray::removeLastObject - This method cannot be called " + + "when the collection is empty.", + null); + TRACE(e); + throw e; + } + + //! this could be faster with splice, but is better practice this way + removeObjectAtIndex(m_list.length - 1); + } + + + /** * Removes the object anObject from the collection. */ *************** *** 425,437 **** // if (index < 0 || index >= m_list.length) ! return; m_list.splice(index, 1); // Remove the object. } ! public function replaceObject(index:Number, anObject:Object):Void { ! replaceObjectAtIndexWithObject(index, anObject); } /** * Replaces the object at index index with anObject. --- 462,490 ---- // if (index < 0 || index >= m_list.length) ! { ! var e:NSException = NSException.exceptionWithNameReasonUserInfo( ! "RangeException", ! "NSArray::removeObjectAtIndex - The index " + index + ! " is out of range.", ! null); ! TRACE(e); ! throw e; ! } m_list.splice(index, 1); // Remove the object. } ! ! /** ! * //! ! * I'm not really sure why this is here since it is the same as ! * replaceObjectAtIndexWithObject. ! */ ! public function replaceObject(index:Number, anObject:Object):Void ! { ! replaceObjectAtIndexWithObject(index, anObject); } + /** * Replaces the object at index index with anObject. *************** *** 458,463 **** //****************************************************** ! //* Events * //****************************************************** //****************************************************** //* Protected Methods * --- 511,564 ---- //****************************************************** ! //* Sorting Functions //****************************************************** + + /** + * + */ + public function sortUsingDescriptors(sortDescriptors:NSArray):Void + { + // + // Can't sort if there are no descriptors. + // + if (sortDescriptors.count() == 0) + { + return; + } + + NSArray.quickSort(m_list, 0, m_list.length - 1, sortDescriptors); + } + + + /** + * Sorts the collection in ascending order using the comparison function + * compare. The comparison method prototype should be as follows: + * + * compare(object1:Object, object2:Object[, context:Object]):NSComparisonResult + * + * The optional context argument is that specified by context, and can contain + * additional information relating to the sort. + */ + public function sortUsingFunctionContext(compare:Function, context:Object):Void + { + NSArray.quickSort(m_list, 0, m_list.length - 1, compare, context); + } + + + /** + * Sorts the array using the comparison method specified by comparator. + * + * The method named comparator is called on each object in the array with the + * single argument of another object in the array. It should return + * NSComparisonResult.NSOrderedAscending if the receiver is smaller than the + * argument, NSComparisonResult.NSOrderedEqual if they are equal, and + * NSComparisonResult.NSOrderedDescending if the receiver is less than the + * argument. + */ + public function sortUsingSelector(comparator:String):Void + { + NSArray.quickSort(m_list, 0, m_list.length - 1, comparator); + } + //****************************************************** //* Protected Methods * *************** *** 484,491 **** return NSArray.arrayWithArray(newArray); } ! //****************************************************** //* Private Static Methods * ! //****************************************************** //****************************************************** //* Class Constructors * --- 585,712 ---- return NSArray.arrayWithArray(newArray); } ! //****************************************************** //* Private Static Methods * ! //****************************************************** ! ! /** ! * This is the standard quicksort algorithm modified a little bit ! * to support selectors and custom comparing methods. ! * ! * @param arr The array to sort. ! * @param first The starting index of the sort. ! * @param last The last index of the sort. ! * @param compare This argument can be a selector string or a comparison function. ! * Please see NSArray.sortUsingSelector() and ! * NSArray.sortUsingFunctionContext() for further details. ! * @param context This is an optional piece of information that is passed on every ! * call to the comparison function. ! * @param sortMode Used internally. Do not pass a value. ! */ ! public static function quickSort(arr:Array, first:Number, last:Number, ! compare:Object, context:Object, sortMode:Number):Void ! { ! var f:Number = first; ! var l:Number = last; ! var item:Object = arr[Math.round((f + l) / 2)]; ! ! // ! // Determine sort mode if applicable ! // ! if (sortMode == undefined) ! { ! if(typeof(compare) == "string" || compare instanceof String) ! { ! sortMode = 1; // selector ! } ! else if (typeof(compare) == "function" || compare instanceof Function) ! { ! sortMode = 2; // compare function ! } ! else if (compare instanceof NSArray) ! { ! sortMode = 3; // array of descriptors ! } ! } ! ! // ! // Sort the array. ! // ! do ! { ! switch (sortMode) ! { ! // ! // Sort using selectors ! // ! case 1: ! ! while (arr[f][compare](item) == NSComparisonResult.NSOrderedAscending) ! f++; ! ! while (item[compare](arr[l]) == NSComparisonResult.NSOrderedAscending) ! l--; ! ! break; ! ! // ! // Sort using a compare function (and context) ! // ! case 2: ! ! var compareFunc:Function = Function(compare); ! ! while (compareFunc(arr[f], item, context) == NSComparisonResult.NSOrderedAscending) ! f++; ! ! while (compareFunc(item, arr[l], context) == NSComparisonResult.NSOrderedAscending) ! l--; ! ! break; ! ! // ! // Sort using an array of NSSortDescriptors ! // ! case 3: ! ! var arrDesc:NSArray = NSArray(compare); ! ! while (NSSortDescriptor.compareObjectToObjectWithDescriptors( ! arr[f], item, arrDesc) == NSComparisonResult.NSOrderedAscending) ! { ! f++; ! } ! ! while (NSSortDescriptor.compareObjectToObjectWithDescriptors( ! item, arr[l], arrDesc) == NSComparisonResult.NSOrderedAscending) ! { ! l--; ! } ! ! break; ! } ! ! if (f <= l) ! { ! // ! // swap ! // ! var temp:Object = arr[f]; ! arr[f] = arr[l]; ! arr[l] = temp; ! ! f++; ! l--; ! } ! } ! while (f <= l) ! ! if (first < l) ! quickSort(arr, first, l, compare, context, sortMode); ! ! if (f < last) ! quickSort(arr, f, last, compare, context, sortMode); ! } ! //****************************************************** //* Class Constructors * |
From: Scott H. <sco...@us...> - 2005-06-28 23:34:26
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep/constants In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12755/src/org/actionstep/constants Added Files: NSComparisonResult.as Log Message: Created Values returned by selectors to determine sort order --- NEW FILE: NSComparisonResult.as --- (This appears to be a binary file; contents omitted.) |
From: Scott H. <sco...@us...> - 2005-06-28 23:33:52
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12281/src/org/actionstep Added Files: NSSortDescriptor.as Log Message: Created Describes how an array sort should be performed --- NEW FILE: NSSortDescriptor.as --- (This appears to be a binary file; contents omitted.) |
From: Tay R. C. <rc...@us...> - 2005-06-28 10:05:56
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3571 Modified Files: NSImageRep.as Log Message: NSPoint.ZeroPoint no longer used as a function Index: NSImageRep.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSImageRep.as,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** NSImageRep.as 5 May 2005 16:30:03 -0000 1.4 --- NSImageRep.as 28 Jun 2005 10:05:42 -0000 1.5 *************** *** 57,61 **** public function setFocus(clip:MovieClip) { m_drawClip = clip; ! m_drawPoint = NSPoint.ZeroPoint(); if (m_defaultRect == null) { m_defaultRect = new NSRect(0,0,size().width, size().height); --- 57,61 ---- public function setFocus(clip:MovieClip) { m_drawClip = clip; ! m_drawPoint = NSPoint.ZeroPoint; if (m_defaultRect == null) { m_defaultRect = new NSRect(0,0,size().width, size().height); |
From: Tay R. C. <rc...@us...> - 2005-06-28 10:03:46
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2590 Modified Files: NSPoint.as NSRect.as NSSize.as NSRange.as Log Message: Implements NSCopying interface Index: NSRange.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSRange.as,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** NSRange.as 4 May 2005 02:33:05 -0000 1.1.1.1 --- NSRange.as 28 Jun 2005 10:03:34 -0000 1.2 *************** *** 30,35 **** import org.actionstep.NSObject; ! class org.actionstep.NSRange extends NSObject { public static var NSNotFound = 0x7fffffff; --- 30,36 ---- import org.actionstep.NSObject; + import org.actionstep.NSCopying; ! class org.actionstep.NSRange extends NSObject implements NSCopying{ public static var NSNotFound = 0x7fffffff; *************** *** 46,51 **** public function clone():NSRange { ! return new NSRange(location, length); } public function description():String { --- 47,56 ---- public function clone():NSRange { ! return copy(); } + + public function copyWithZone():NSRange { + return new NSRange(location, length); + } public function description():String { Index: NSRect.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSRect.as,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** NSRect.as 20 Jun 2005 02:11:20 -0000 1.16 --- NSRect.as 28 Jun 2005 10:03:34 -0000 1.17 *************** *** 32,37 **** import org.actionstep.NSSize; import org.actionstep.NSPoint; ! class org.actionstep.NSRect extends NSObject { /** --- 32,38 ---- import org.actionstep.NSSize; import org.actionstep.NSPoint; + import org.actionstep.NSCopying; ! class org.actionstep.NSRect extends NSObject implements NSCopying{ /** *************** *** 70,73 **** --- 71,78 ---- public function clone():NSRect { + return copy(); + } + + public function copyWithZone():NSRect { return NSRect.withOriginSize(origin, size); } Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** NSPoint.as 28 Jun 2005 09:21:39 -0000 1.10 --- NSPoint.as 28 Jun 2005 10:03:33 -0000 1.11 *************** *** 30,38 **** import org.actionstep.NSObject; /** * Represents a point in 2D space. Contains an x-coordinate and a y-coordinate. */ ! class org.actionstep.NSPoint extends NSObject { /** A point with location (0, 0). */ --- 30,39 ---- import org.actionstep.NSObject; + import org.actionstep.NSCopying; /** * Represents a point in 2D space. Contains an x-coordinate and a y-coordinate. */ ! class org.actionstep.NSPoint extends NSObject implements NSCopying { /** A point with location (0, 0). */ *************** *** 61,66 **** */ public function clone():NSPoint { ! return new NSPoint(x, y); } /** --- 62,71 ---- */ public function clone():NSPoint { ! return copy(); } + + public function copyWithZone():NSPoint { + return new NSPoint(x, y); + } /** Index: NSSize.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSSize.as,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** NSSize.as 27 May 2005 01:33:06 -0000 1.3 --- NSSize.as 28 Jun 2005 10:03:34 -0000 1.4 *************** *** 30,35 **** import org.actionstep.NSObject; ! class org.actionstep.NSSize extends NSObject { public static var ZeroSize:NSSize = new NSSize(0,0); --- 30,36 ---- import org.actionstep.NSObject; + import org.actionstep.NSCopying; ! class org.actionstep.NSSize extends NSObject implements NSCopying{ public static var ZeroSize:NSSize = new NSSize(0,0); *************** *** 44,49 **** public function clone():NSSize { ! return new NSSize(width, height); } public function description():String { --- 45,54 ---- public function clone():NSSize { ! return copy(); } + + public function copyWithZone():NSSize { + return new NSSize(width, height); + } public function description():String { |
From: Tay R. C. <rc...@us...> - 2005-06-28 10:01:51
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1819 Modified Files: NSObject.as Log Message: Has copy method Index: NSObject.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSObject.as,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** NSObject.as 10 Jun 2005 02:56:17 -0000 1.10 --- NSObject.as 28 Jun 2005 10:01:36 -0000 1.11 *************** *** 138,140 **** --- 138,149 ---- return NSObject(res); } + + public function copy() { + var f = this["copyWithZone"]; + if(f instanceof Function) { + return f.call(this); + } else { + throw new Error("Class doesn't implement NSCopying"); + } + } } \ No newline at end of file |
From: Tay R. C. <rc...@us...> - 2005-06-28 10:01:17
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1661 Added Files: NSCopying.as Log Message: Contains only copyWithZone --- NEW FILE: NSCopying.as --- /* * Copyright (c) 2005, InfoEther, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, * are permitted provided that the following conditions are met: * * 1) Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * 2) Redistributions in binary form must reproduce the above copyright notice, * this list of conditions and the following disclaimer in the documentation * and/or other materials provided with the distribution. * * 3) The name InfoEther, Inc. may not be used to endorse or promote products * derived from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ interface org.actionstep.NSCopying { public function copyWithZone(); } |
From: Tay R. C. <rc...@us...> - 2005-06-28 09:21:48
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12234 Modified Files: NSPoint.as Log Message: Uses getter, distanceToPoint Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** NSPoint.as 26 Jun 2005 12:47:25 -0000 1.9 --- NSPoint.as 28 Jun 2005 09:21:39 -0000 1.10 *************** *** 37,41 **** /** A point with location (0, 0). */ ! public static var ZeroPoint = new NSPoint(0,0); /** The x-coordinate. */ --- 37,44 ---- /** A point with location (0, 0). */ ! //please see NSRect for reasons on using getter func ! public static function get ZeroPoint ():NSPoint { ! return new NSPoint(0,0); ! } /** The x-coordinate. */ *************** *** 101,103 **** --- 104,110 ---- return new NSPoint(x + dx, y + dy); } + + public function distanceToPoint(pt:NSPoint):Number { + return Math.sqrt((x-pt.x)*(x-pt.x), (y-pt.y)*(y-pt.y)); + } } \ No newline at end of file |
From: Richard K. <ric...@us...> - 2005-06-28 00:42:04
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv429 Modified Files: ASEventMonitor.as Log Message: bounded location for double-click to 20 pixels x or y Index: ASEventMonitor.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASEventMonitor.as,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** ASEventMonitor.as 27 Jun 2005 21:25:08 -0000 1.13 --- ASEventMonitor.as 28 Jun 2005 00:41:53 -0000 1.14 *************** *** 116,120 **** } ! if ((getTimer() - m_lastMouseDownTime) < m_multiClickSpeed) { m_lastMouseDownEvent.clickCount++; m_lastMouseDownTime = getTimer(); --- 116,125 ---- } ! var x = _root._xmouse; ! var y = _root._ymouse; ! ! if ((getTimer() - m_lastMouseDownTime) < m_multiClickSpeed && ! (Math.abs(x - m_lastMouseDownEvent.mouseLocation.x)) < 20 && ! (Math.abs(y - m_lastMouseDownEvent.mouseLocation.y)) < 20) { m_lastMouseDownEvent.clickCount++; m_lastMouseDownTime = getTimer(); *************** *** 125,129 **** var modifierFlags = buildModifierFlags(); ! m_lastMouseDownEvent = NSEvent.mouseEventWithType(NSEvent.NSLeftMouseDown, new NSPoint(_root._xmouse, _root._ymouse), modifierFlags, (new Date()).getTime(), eval(targetPath).view, null /* context */, m_eventCounter++, 1 /*click count*/, 0).memberwiseClone(); --- 130,134 ---- var modifierFlags = buildModifierFlags(); ! m_lastMouseDownEvent = NSEvent.mouseEventWithType(NSEvent.NSLeftMouseDown, new NSPoint(x, y), modifierFlags, (new Date()).getTime(), eval(targetPath).view, null /* context */, m_eventCounter++, 1 /*click count*/, 0).memberwiseClone(); |
From: Richard K. <ric...@us...> - 2005-06-27 21:25:30
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6909 Modified Files: ASEventMonitor.as Log Message: enabled double-click with a default time of 500 millis Index: ASEventMonitor.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASEventMonitor.as,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** ASEventMonitor.as 27 Jun 2005 19:29:10 -0000 1.12 --- ASEventMonitor.as 27 Jun 2005 21:25:08 -0000 1.13 *************** *** 44,47 **** --- 44,51 ---- private var m_filter; private var m_index:Number; + private var m_multiClickSpeed:Number; + + private var m_lastMouseDownTime:Number; + private var m_lastMouseDownEvent:NSEvent; public static function instance():ASEventMonitor { *************** *** 56,61 **** --- 60,74 ---- } + public function multiClickSpeed():Number { + return m_multiClickSpeed; + } + + public function setMultiClickSpeed(value:Number) { + m_multiClickSpeed = value; + } + private function ASEventMonitor() { m_app = NSApplication.sharedApplication(); + m_multiClickSpeed = 500; // OS X default m_mouseTrackingClip = null; m_currentMouseTargetPath = ""; *************** *** 64,67 **** --- 77,81 ---- m_index = _root._target.length; if (m_index == 1) m_index = 0; + m_lastMouseDownTime = 0; } *************** *** 102,111 **** } var modifierFlags = buildModifierFlags(); ! var event = NSEvent.mouseEventWithType(NSEvent.NSLeftMouseDown, new NSPoint(_root._xmouse, _root._ymouse), modifierFlags, (new Date()).getTime(), eval(targetPath).view, ! null /* context */, m_eventCounter++, 1 /*click count*/, 0); ! m_app.sendEvent(event); } --- 116,133 ---- } + if ((getTimer() - m_lastMouseDownTime) < m_multiClickSpeed) { + m_lastMouseDownEvent.clickCount++; + m_lastMouseDownTime = getTimer(); + m_app.sendEvent(m_lastMouseDownEvent); + return; + } + var modifierFlags = buildModifierFlags(); ! m_lastMouseDownEvent = NSEvent.mouseEventWithType(NSEvent.NSLeftMouseDown, new NSPoint(_root._xmouse, _root._ymouse), modifierFlags, (new Date()).getTime(), eval(targetPath).view, ! null /* context */, m_eventCounter++, 1 /*click count*/, 0).memberwiseClone(); ! m_lastMouseDownTime = getTimer(); ! m_app.sendEvent(m_lastMouseDownEvent); } |
From: Richard K. <ric...@us...> - 2005-06-27 19:29:25
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23639 Modified Files: ASEventMonitor.as Log Message: check for _root._target and eval mouse targets based on relative path Index: ASEventMonitor.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/ASEventMonitor.as,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** ASEventMonitor.as 23 Jun 2005 01:21:10 -0000 1.11 --- ASEventMonitor.as 27 Jun 2005 19:29:10 -0000 1.12 *************** *** 43,46 **** --- 43,47 ---- private var m_eventCounter; private var m_filter; + private var m_index:Number; public static function instance():ASEventMonitor { *************** *** 61,64 **** --- 62,67 ---- m_eventCounter = 1; m_filter = null; + m_index = _root._target.length; + if (m_index == 1) m_index = 0; } *************** *** 95,98 **** --- 98,105 ---- private function mouseDown(targetPath:String) { + if (m_index > 0) { + targetPath = targetPath.slice(m_index); + } + var modifierFlags = buildModifierFlags(); *************** *** 104,107 **** --- 111,117 ---- private function mouseUp(targetPath:String) { + if (m_index > 0) { + targetPath = targetPath.slice(m_index); + } var modifierFlags = buildModifierFlags(); *************** *** 112,116 **** } ! private function mouseMove(targetPath:String) { var event; // MouseEnter/exit messages --- 122,129 ---- } ! private function mouseMove(targetPath:String) { ! if (m_index > 0) { ! targetPath = targetPath.slice(m_index); ! } var event; // MouseEnter/exit messages |
From: Richard K. <ric...@us...> - 2005-06-27 04:08:40
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3582 Modified Files: NSMatrix.as Log Message: commented out all TRACE statements and added sendAction() to mouseDown event handler for target/action capability Index: NSMatrix.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSMatrix.as,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** NSMatrix.as 10 Jun 2005 02:56:17 -0000 1.21 --- NSMatrix.as 27 Jun 2005 04:08:27 -0000 1.22 *************** *** 231,235 **** private function postInit():Void { ! TRACE(m_frame); // --- 231,235 ---- private function postInit():Void { ! //TRACE(m_frame); // *************** *** 971,980 **** if (cnt > 0 && (m_numrows == 0 || m_numcols == 0)) { ! TRACE("cnt > 0 && (m_numrows == 0 || m_numcols == 0)"); renewRowsColumnsRowSpaceColSpace(cnt, 1, 0, cnt); } else { ! TRACE("num rows: " + m_numrows + ", column: " + i); renewRowsColumnsRowSpaceColSpace(m_numrows == 0 ? 1 : m_numrows, i, 0, cnt); --- 971,980 ---- if (cnt > 0 && (m_numrows == 0 || m_numcols == 0)) { ! //TRACE("cnt > 0 && (m_numrows == 0 || m_numcols == 0)"); renewRowsColumnsRowSpaceColSpace(cnt, 1, 0, cnt); } else { ! //TRACE("num rows: " + m_numrows + ", column: " + i); renewRowsColumnsRowSpaceColSpace(m_numrows == 0 ? 1 : m_numrows, i, 0, cnt); *************** *** 1256,1261 **** public function cellFrameAtRowColumn(row:Number, column:Number):NSRect { ! TRACE("cell space: " + m_cellspacing); ! TRACE("cell size: " + m_cellsize); var iniX:Number = m_cellspacing.width; var iniY:Number = m_cellspacing.height; --- 1256,1261 ---- public function cellFrameAtRowColumn(row:Number, column:Number):NSRect { ! //TRACE("cell space: " + m_cellspacing); ! //TRACE("cell size: " + m_cellsize); var iniX:Number = m_cellspacing.width; var iniY:Number = m_cellspacing.height; *************** *** 1363,1367 **** public function drawCellAtRowColumn(row:Number, column:Number):Void { ! TRACE("row: " + row + ", column: " + column); if (m_mcBounds == null) --- 1363,1367 ---- public function drawCellAtRowColumn(row:Number, column:Number):Void { ! //TRACE("row: " + row + ", column: " + column); if (m_mcBounds == null) *************** *** 1375,1379 **** var frame:NSRect = cellFrameAtRowColumn(row, column); ! TRACE(frame); // --- 1375,1379 ---- var frame:NSRect = cellFrameAtRowColumn(row, column); ! //TRACE(frame); // *************** *** 1566,1575 **** if (row == -1 || column == -1) { ! TRACE("Deselecting all cells"); deselectAllCells(); return; } ! TRACE("Selecting cell at ("+row+", "+column+")"); var cell:NSCell = cellAtRowColumn(row, column); --- 1566,1575 ---- if (row == -1 || column == -1) { ! //TRACE("Deselecting all cells"); deselectAllCells(); return; } ! //TRACE("Selecting cell at ("+row+", "+column+")"); var cell:NSCell = cellAtRowColumn(row, column); *************** *** 1600,1608 **** m_selcell_column = column; var idx:Number = indexFromRowColumn(row, column); ! TRACE("idx: " + idx); m_sel.addObject(idx); ! TRACE("m_sel: " + m_sel); // --- 1600,1608 ---- m_selcell_column = column; var idx:Number = indexFromRowColumn(row, column); ! //TRACE("idx: " + idx); m_sel.addObject(idx); ! //TRACE("m_sel: " + m_sel); // *************** *** 1716,1726 **** var ss:NSSize = m_cellspacing; ! TRACE("cell size: " + cs); ! TRACE("cell spacing: " + ss); frameSize.width += cs.width * m_numcols + ss.width * (m_numcols + 1); frameSize.height += cs.height * m_numrows + ss.height * (m_numrows + 1); ! TRACE(frameSize); this.setFrameSize(frameSize); --- 1716,1726 ---- var ss:NSSize = m_cellspacing; ! //TRACE("cell size: " + cs); ! //TRACE("cell spacing: " + ss); frameSize.width += cs.width * m_numcols + ss.width * (m_numcols + 1); frameSize.height += cs.height * m_numrows + ss.height * (m_numrows + 1); ! //TRACE(frameSize); this.setFrameSize(frameSize); *************** *** 1764,1768 **** public function mouseDown(theEvent:NSEvent):Void { ! TRACE(theEvent); // debug info // --- 1764,1768 ---- public function mouseDown(theEvent:NSEvent):Void { ! //TRACE(theEvent); // debug info // *************** *** 1794,1798 **** if (loc != null) { ! TRACE("row: " + loc.row + ", column: " + loc.column); var cell:NSCell = cellAtRowColumn(loc.row, loc.column); --- 1794,1798 ---- if (loc != null) { ! //TRACE("row: " + loc.row + ", column: " + loc.column); var cell:NSCell = cellAtRowColumn(loc.row, loc.column); *************** *** 1805,1809 **** m_mousedownflags = theEvent.modifierFlags; // record flags ! //super.mouseDown(theEvent); } --- 1805,1809 ---- m_mousedownflags = theEvent.modifierFlags; // record flags ! sendAction(); //super.mouseDown(theEvent); } *************** *** 1814,1818 **** if (m_mode != NSMatrixMode.NSTrackModeMatrix) { ! TRACE(m_highlightedrow+", "+m_highlightedcolumn); highlightCellAtRowColumn(false, m_highlightedrow, m_highlightedcolumn); m_highlightedcell = null; --- 1814,1818 ---- if (m_mode != NSMatrixMode.NSTrackModeMatrix) { ! //TRACE(m_highlightedrow+", "+m_highlightedcolumn); highlightCellAtRowColumn(false, m_highlightedrow, m_highlightedcolumn); m_highlightedcell = null; *************** *** 1868,1872 **** var cell:NSCell, highlight:NSCell; var pt:NSPoint = convertPointFromView(theEvent.mouseLocation); ! TRACE(pt); var loc:Object = getRowColumnForPoint(pt); --- 1868,1872 ---- var cell:NSCell, highlight:NSCell; var pt:NSPoint = convertPointFromView(theEvent.mouseLocation); ! //TRACE(pt); var loc:Object = getRowColumnForPoint(pt); *************** *** 1984,1988 **** //! TESTING CODE //watch.stop(); ! //TRACE("cell draw time: " + watch.getTimeInMilliSeconds()); //watch.reset(); } --- 1984,1988 ---- //! TESTING CODE //watch.stop(); ! ////TRACE("cell draw time: " + watch.getTimeInMilliSeconds()); //watch.reset(); } *************** *** 2003,2007 **** rows:Number, columns:Number, rowSpace:Number, colSpace:Number):Void { ! TRACE(rows + ", " + columns); // --- 2003,2007 ---- rows:Number, columns:Number, rowSpace:Number, colSpace:Number):Void { ! //TRACE(rows + ", " + columns); // *************** *** 2056,2060 **** { var cell:NSCell = NSCell(m_cells.objectAtIndex(removalPoint)); ! TRACE(cell); cell.release(); m_cells.removeObjectAtIndex(removalPoint); --- 2056,2060 ---- { var cell:NSCell = NSCell(m_cells.objectAtIndex(removalPoint)); ! //TRACE(cell); cell.release(); m_cells.removeObjectAtIndex(removalPoint); *************** *** 2083,2087 **** { var cell:NSCell = NSCell(m_cells.objectAtIndex(removalPoint)); ! TRACE(cell); cell.release(); m_cells.removeObjectAtIndex(removalPoint); --- 2083,2087 ---- { var cell:NSCell = NSCell(m_cells.objectAtIndex(removalPoint)); ! //TRACE(cell); cell.release(); m_cells.removeObjectAtIndex(removalPoint); *************** *** 2091,2095 **** m_numrows = rows; ! TRACE("cells: " + m_cells); //deselectAllCells(); } --- 2091,2095 ---- m_numrows = rows; ! //TRACE("cells: " + m_cells); //deselectAllCells(); } *************** *** 2376,2381 **** private function rowColumnFromIndex(index:Number):Object { ! TRACE("num rows: " + m_numrows + ", num cols: " + m_numcols); ! TRACE("index: " + index); var ret:Object = new Object(); --- 2376,2381 ---- private function rowColumnFromIndex(index:Number):Object { ! //TRACE("num rows: " + m_numrows + ", num cols: " + m_numcols); ! //TRACE("index: " + index); var ret:Object = new Object(); |
From: Richard K. <ric...@us...> - 2005-06-27 03:37:14
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21024 Modified Files: NSButtonCell.as Log Message: got on off buttons working Index: NSButtonCell.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSButtonCell.as,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** NSButtonCell.as 18 Jun 2005 14:04:20 -0000 1.22 --- NSButtonCell.as 27 Jun 2005 03:37:02 -0000 1.23 *************** *** 635,639 **** } } else if (m_bezeled) { ! if (m_highlighted || !m_enabled) { m_textField._x += 1; m_textField._y += 1; --- 635,639 ---- } } else if (m_bezeled) { ! if (m_highlighted || !m_enabled || (mask & (NSChangeGrayCellMask | NSChangeBackgroundCellMask))) { m_textField._x += 1; m_textField._y += 1; *************** *** 642,646 **** } if (m_enabled) { ! if (m_highlighted) { ASTheme.current().drawBezelButtonDownWithRectInViewHasShadow(cellFrame, inView, m_bezelStyle != NSBezelStyle.NSShadowlessSquareBezelStyle); } else { --- 642,646 ---- } if (m_enabled) { ! if (m_highlighted || (mask & (NSChangeGrayCellMask | NSChangeBackgroundCellMask))) { ASTheme.current().drawBezelButtonDownWithRectInViewHasShadow(cellFrame, inView, m_bezelStyle != NSBezelStyle.NSShadowlessSquareBezelStyle); } else { |
From: Richard K. <ric...@us...> - 2005-06-26 12:47:33
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3314 Modified Files: NSPoint.as Log Message: added translate function Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** NSPoint.as 26 Jun 2005 12:06:46 -0000 1.8 --- NSPoint.as 26 Jun 2005 12:47:25 -0000 1.9 *************** *** 93,95 **** --- 93,103 ---- return new NSPoint(x - point.x, y - point.y); } + + /** + * Translates point with supplied dx, dy and returns a new NSPoint. + * This does not change the value of the receiver. + */ + public function translate(dx:Number, dy:Number):NSPoint { + return new NSPoint(x + dx, y + dy); + } } \ No newline at end of file |
From: Richard K. <ric...@us...> - 2005-06-26 12:07:00
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14575 Modified Files: NSPoint.as Log Message: made add/subtract member functions not static Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** NSPoint.as 26 Jun 2005 10:30:22 -0000 1.7 --- NSPoint.as 26 Jun 2005 12:06:46 -0000 1.8 *************** *** 77,95 **** /** ! * Adds point1 to point2 and returns the result. */ ! public static function add(point1:NSPoint, point2:NSPoint):NSPoint { ! return new NSPoint(point2.x + point1.x, point2.y + point1.y); } /** ! * Subtracts point2 from point1 and returns the result. ! */ ! public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! //BUG!! this line of code doesn't do what the comment above says, so I'm changing it (again). ! // return new NSPoint(point2.x - point1.x, point2.y - point1.y); ! return new NSPoint(point1.x - point2.x, point1.y - point2.y); } } \ No newline at end of file --- 77,95 ---- /** ! * Adds point to receiver and returns a new NSPoint. ! * This does not change the value of the receiver. */ ! public function add(point:NSPoint):NSPoint { ! return new NSPoint(x + point.x, y + point.y); } /** ! * Subtracts point from receiver and returns a new NSPoint. ! * This does not change the value of the receiver. ! */ ! public function subtract(point:NSPoint):NSPoint { ! return new NSPoint(x - point.x, y - point.y); } } \ No newline at end of file |
From: U5eR <u5...@us...> - 2005-06-26 10:30:31
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22855/src/org/actionstep Modified Files: NSPoint.as Log Message: NSPoint.subtract was subtracting in the wrong order. Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** NSPoint.as 26 Jun 2005 01:31:29 -0000 1.6 --- NSPoint.as 26 Jun 2005 10:30:22 -0000 1.7 *************** *** 89,93 **** public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! return new NSPoint(point2.x - point1.x, point2.y - point1.y); } } \ No newline at end of file --- 89,95 ---- public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! //BUG!! this line of code doesn't do what the comment above says, so I'm changing it (again). ! // return new NSPoint(point2.x - point1.x, point2.y - point1.y); ! return new NSPoint(point1.x - point2.x, point1.y - point2.y); } } \ No newline at end of file |
From: Tay R. C. <rc...@us...> - 2005-06-26 01:31:37
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28061 Modified Files: NSPoint.as Log Message: Subtracting order... Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** NSPoint.as 25 Jun 2005 18:58:54 -0000 1.5 --- NSPoint.as 26 Jun 2005 01:31:29 -0000 1.6 *************** *** 89,93 **** public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! return new NSPoint(point1.x - point2.x, point1.y - point2.y); } } \ No newline at end of file --- 89,93 ---- public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! return new NSPoint(point2.x - point1.x, point2.y - point1.y); } } \ No newline at end of file |
From: U5eR <u5...@us...> - 2005-06-25 18:59:02
|
Update of /cvsroot/actionstep/actionstep/src/org/actionstep In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20608/src/org/actionstep Modified Files: NSPoint.as Log Message: NSPoint.subtract was subtracting in the wrong order. Index: NSPoint.as =================================================================== RCS file: /cvsroot/actionstep/actionstep/src/org/actionstep/NSPoint.as,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** NSPoint.as 27 May 2005 01:33:06 -0000 1.4 --- NSPoint.as 25 Jun 2005 18:58:54 -0000 1.5 *************** *** 89,93 **** public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! return new NSPoint(point2.x - point1.x, point2.y - point1.y); } } \ No newline at end of file --- 89,93 ---- public static function subtract(point1:NSPoint, point2:NSPoint):NSPoint { ! return new NSPoint(point1.x - point2.x, point1.y - point2.y); } } \ No newline at end of file |