Transferred from the Adobe Open Source Subversion Repository

Revision: 12850
Author:   jimurphy@adobe.com
Date:     2009-12-11T14:57:14.623098Z

Log Message:
-----------
add 6 new DMV projects to the SDK:
automation
automation_air
automation_dmv
automation_flashflexkit
automation_spark
datavisualization

These projects are setup to build in an ant main call.  There are currently several warnings in the datavisualization project that will be cleaned up.  No checkintests exist for these projects as of yet.

I also modified the exisitng projects build files for easier management of the localization targets, bundle and fat-swc. If the projects that I updated:airframework,airspark,framework,playerglobal,rpc,and spark.  All the new projects have been implemented this same way.

QE notes: DMV folks should run through their tests
Doc notes: probably
Bugs: nope
Reviewer:
Tests run: ran the following targets: compile,checkintests,other.locales and doc
Is noteworthy for integration: no

Modified Paths:
--------------
1404 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1290555 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/advancedgrids/src/mx/olap/IOLAPQuery.as
+++ frameworks/projects/advancedgrids/src/mx/olap/IOLAPQuery.as
@@ -0,0 +1,68 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2009 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.olap
+{
+/**
+ *  The IOLAPQuery interface represents an OLAP query that is executed on an IOLAPCube.
+ *
+ *  @see mx.olap.OLAPQuery
+ *  @see mx.olap.IOLAPQueryAxis
+ *  @see mx.olap.OLAPQueryAxis
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public interface IOLAPQuery
+{
+	//--------------------------------------------------------------------------
+	//
+	//  Methods
+	//
+	//--------------------------------------------------------------------------
+
+    /**
+     *  Gets an axis from the query. You typically call this method to
+     *  obtain an uninitialized IOLAPQueryAxis instance, then configure the
+     *  IOLAPQueryAxis instance for the query.
+     *
+     *  @param axisOrdinal Specify OLAPQuery.COLUMN AXIS for a column axis,
+     *  OLAPQuery.ROW_AXIS for a row axis,
+     *  and OLAPQuery.SLICER_AXIS for a slicer axis.
+     *
+     *  @return The IOLAPQueryAxis instance.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    function getAxis(axisOridnal:int):IOLAPQueryAxis;
+
+    /**
+     *  Sets an axis to the query.
+     *
+     *  @param axisOrdinal Specify OLAPQuery.COLUMN AXIS for a column axis,
+     *  OLAPQuery.ROW_AXIS for a row axis,
+     *  and OLAPQuery.SLICER_AXIS for a slicer axis.
+     *
+     *  @param axis The IOLAPQueryAxis instance.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    function setAxis(axisOridnal:int, axis:IOLAPQueryAxis):void;
+}
+}


Transferred from the Adobe Open Source Subversion Repository

Revision: 14652
Author:   jszeto@adobe.com
Date:     2010-03-09T23:48:54.803563Z

Log Message:
-----------
Merging revision 14651 from 4.x to trunk

Partial Mirrored Window Resize Fix

http://bugs.adobe.com/jira/browse/SDK-25609 - WindowedApplication doesn’t properly resize when layoutDirection is rtl

This partially fixes using the gripper to resize the window. Checking in now so that windows are more functional for QE to test.

QE notes: n/a
Doc notes: n/a
Bugs: SDK-25609
Reviewer: Hans
Tests run: checkintests
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/Window.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airspark/src/spark/components/WindowedApplication.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airspark/src/spark/components/Window.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/airframework/src/mx/core/WindowedApplication.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1250538 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/airspark/src/spark/components/Window.as
+++ frameworks/projects/airspark/src/spark/components/Window.as
@@ -2444,7 +2444,8 @@
     {
         if (event.target == gripper)
         {
-            startResize(NativeWindowResize.BOTTOM_RIGHT);
+            startResize(layoutDirection == "rtl" ? NativeWindowResize.BOTTOM_LEFT
+                                                 : NativeWindowResize.BOTTOM_RIGHT);
             event.stopPropagation();
             return;
         }


Transferred from the Adobe Open Source Subversion Repository

Revision: 8385
Author:   smgilson@adobe.com
Date:     2009-07-06T19:38:43.090419Z

Log Message:
-----------
ASDoc updates for Spark layouts and core

QE Notes: None
Doc Notes: None
Bugs: -
checkintests: passed

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/BasicLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutElementHelper.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/RowAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/ISharedDisplayObject.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/VerticalAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/MaskType.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/NavigationUnit.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/TileLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/SpriteVisualElement.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/HorizontalAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/core/DisplayObjectSharingMode.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/VerticalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/ColumnAlign.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/TileOrientation.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/ILayoutElement.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1259393 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/core/ILayoutElement.as
+++ frameworks/projects/framework/src/mx/core/ILayoutElement.as
@@ -305,35 +305,39 @@
     function set includeInLayout(value:Boolean):void;

     /**
+     *  Returns the element's preferred width.
+     *
+     *  @param postLayoutTransform When postLayoutTransform is true the method returns
+     *  the element's bounding box width.  Bounding box is in element's parent
+     *  coordinate space and is calculated from  the element's perferred size and
+     *  layout transform matrix.
+     *
      *  @return Returns the element's preferred width.  Preferred width is
      *  usually based on the default element size and any explicit overrides.
      *  For UIComponent this is the same as getExplicitOrMeasuredWidth().
      *
-     *  @param postLayoutTransform When postLayoutTransform is true the method returns
-     *  the element's bounding box width.  Bounding box is in element's parent
+     *  @see #getPreferredHeight
+     *  @see #getLayoutMatrix
+     *  @see #getLayoutMatrix3D
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    function getPreferredBoundsWidth(postLayoutTransform:Boolean = true):Number;
+
+    /**
+     *  Returns the element's preferred height.
+     *
+     *  @param postLayoutTransform When postLayoutTransform is true the method returns
+     *  the element's bounding box height.  Bounding box is in element's parent
      *  coordinate space and is calculated from  the element's perferred size and
      *  layout transform matrix.
      *
-     *  @see #getPreferredHeight
-     *  @see #getLayoutMatrix
-     *  @see #getLayoutMatrix3D
-     *
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
-     */
-    function getPreferredBoundsWidth(postLayoutTransform:Boolean = true):Number;
-
-    /**
      *  @return Returns the element's preferred height.  Preferred height is
      *  usually based on the default element size and any explicit overrides.
      *  For UIComponent this is the same as getExplicitOrMeasuredHeight().
-     *
-     *  @param postLayoutTransform When postLayoutTransform is true the method returns
-     *  the element's bounding box height.  Bounding box is in element's parent
-     *  coordinate space and is calculated from  the element's perferred size and
-     *  layout transform matrix.
      *
      *  @see #getPreferredWidth
      *  @see #getLayoutMatrix


Transferred from the Adobe Open Source Subversion Repository

Revision: 23246
Author:   cframpto@adobe.com
Date:     2011-12-20T17:40:08.069454Z

Log Message:
-----------
Rollback 23243.  If comment followed header it was stripped as well.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1269966 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/mx/src/mx/skins/halo/TitleBackground.as
+++ frameworks/projects/mx/src/mx/skins/halo/TitleBackground.as
@@ -1,3 +1,13 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  ADOBE SYSTEMS INCORPORATED
+//  Copyright 2003-2007 Adobe Systems Incorporated
+//  All Rights Reserved.
+//
+//  NOTICE: Adobe permits you to use, modify, and distribute this file
+//  in accordance with the terms of the license agreement accompanying it.
+//
+////////////////////////////////////////////////////////////////////////////////

 package mx.skins.halo
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 14095
Author:   cframpto@adobe.com
Date:     2010-02-10T17:33:30.511669Z

Log Message:
-----------
Merge 14076 from 4.x branch to trunk.

Revision: 14076
Author:   cframpto@adobe.com
Date:     2010-02-09 15:23:15 -0800 (Tue, 09 Feb 2010)
Log Message:
***********
Add UIComponent.mapKeycodeForLayoutDirection().  This should be called by any keyDownHandlers() which handles Keyboard.LEFT and Keyboard.RIGHT, and optionally for Keyboard.UP and Keyboard.DOWN, if they behave like Keyboard.LEFT and Keyboard.RIGHT.  If the layoutDirection="rtl", it maps LEFT to RIGHT, RIGHT to LEFT, UP to RIGHT and DOWN to LEFT.  This allows the keyDownHandler() to perform the correct action without adding lots of special case code to the key handling code.

QE notes: For layoutDirection="rtl" need to test LEFT, RIGHT, UP and DOWN keys.
Doc notes: None
Bugs: SDK-25330
Reviewed By: Hans
Tests run: checkintests
Is noteworthy for integration: No

Ticket Links:
***********
    http://bugs.adobe.com/jira/browse/SDK-25330

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/MenuBar.as</path>
<path kind="dir" action="M">/flex/sdk/trunk/frameworks</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/RadioButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/RadioButton.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/HScrollBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Tree.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/ListBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ButtonBar.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/Accordion.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/colorPickerClasses/SwatchPanel.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/CalendarLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/Container.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/SliderBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/ColorPicker.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Spinner.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/listClasses/TileBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/sliderClasses/SliderThumb.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/core/UIComponent.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Scroller.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/supportClasses/ButtonBarBase.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1268561 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/mx/src/mx/controls/Tree.as
+++ frameworks/projects/mx/src/mx/controls/Tree.as
@@ -2909,7 +2909,11 @@

         if (itemEditorInstance)
             return;
-
+
+        // If rtl layout, need to swap LEFT for RIGHT so correct action
+        // is done.
+        var keyCode:int = mapKeycodeForLayoutDirection(event);
+
         // Keyboard handling is consistent with Windows Explorer.
         var item:Object = selectedItem;
         if (event.ctrlKey)
@@ -2917,7 +2921,7 @@
             // Ctrl keys always get sent to the List.
             super.keyDownHandler(event);
         }
-        else if (event.keyCode == Keyboard.SPACE)
+        else if (keyCode == Keyboard.SPACE)
         {
             // if user has moved the caret cursor from the selected item
             // move the cursor back to selected item
@@ -2944,7 +2948,7 @@
             }
             event.stopImmediatePropagation();
         }
-        else if (event.keyCode == Keyboard.LEFT)
+        else if (keyCode == Keyboard.LEFT)
         {
             // Left Arrow closes an open item.
             // Otherwise, selects the parent item if there is one.
@@ -2969,7 +2973,7 @@
             }
             event.stopImmediatePropagation();
         }
-        else if (event.keyCode == Keyboard.RIGHT)
+        else if (keyCode == Keyboard.RIGHT)
         {
             // Right Arrow has no effect on leaf items. Closed branch items are opened.
             //Opened branch items select the first child.
@@ -2994,7 +2998,7 @@

 					finishArrowKeySelection();
                 }
-                else
+            else
                 {
                     dispatchTreeEvent(TreeEvent.ITEM_OPENING,
                                         item,   //item
@@ -3007,11 +3011,11 @@
             }
             event.stopImmediatePropagation();
         }
-        else if (event.keyCode == Keyboard.NUMPAD_MULTIPLY)
+        else if (keyCode == Keyboard.NUMPAD_MULTIPLY)
         {
             expandChildrenOf(item, !isItemOpen(item));
         }
-        else if (event.keyCode == Keyboard.NUMPAD_ADD)
+        else if (keyCode == Keyboard.NUMPAD_ADD)
         {
             if (isBranch(item))
             {
@@ -3027,7 +3031,7 @@
                 }
             }
         }
-        else if (event.keyCode == Keyboard.NUMPAD_SUBTRACT)
+        else if (keyCode == Keyboard.NUMPAD_SUBTRACT)
         {
             if (isItemOpen(item))
             {


Effect.setPasses() now returns this

Effect.setPasses() now returns this

--- src/aerys/minko/render/effect/Effect.as
+++ src/aerys/minko/render/effect/Effect.as
@@ -44,10 +44,12 @@
 			return _passes[index];
 		}

-		public function setPasses(newPasses : Vector.<Shader>) : void
+		public function setPasses(newPasses : Vector.<Shader>) : Effect
 		{
 			_passes = newPasses.slice();
 			_passesChanged.execute(this);
+
+			return this;
 		}

 		public function addPass(pass : Shader) : uint


OFC-221 Entering remarks on a field with reason blank specified causes exception

--- collect-flex/collect-flex-client/src/main/flex/org/openforis/collect/presenter/InputFieldPresenter.as
+++ collect-flex/collect-flex-client/src/main/flex/org/openforis/collect/presenter/InputFieldPresenter.as
@@ -44,7 +44,8 @@
 		public static const SHORTCUT_DASH_ON_FORM:String = "-";
 		public static const SHORTCUT_ILLEGIBLE:String = "?";

-		public static const REASON_BLANK_SYMBOLS:Array = [SHORTCUT_BLANK_ON_FORM, SHORTCUT_DASH_ON_FORM, SHORTCUT_ILLEGIBLE];
+		public static const REASON_BLANK_SHORTCUTS:Array = [SHORTCUT_BLANK_ON_FORM, SHORTCUT_DASH_ON_FORM, SHORTCUT_ILLEGIBLE];
+		public static const REASON_BLANK_SYMBOLS:Array = [FieldSymbol.BLANK_ON_FORM, FieldSymbol.DASH_ON_FORM, FieldSymbol.ILLEGIBLE];

 		private var _view:InputField;
 		private var _changed:Boolean = false;
@@ -171,7 +172,7 @@

 		public function getApplySymbolOperation(symbol:FieldSymbol):UpdateRequestOperation {
 			var value:String = null;
-			if(ArrayUtil.isNotIn(REASON_BLANK_SYMBOLS, symbol)) {
+			if(! isReasonBlankSymbol(symbol)) {
 				value = textToRequestValue(); //preserve old value
 			}
 			var remarks:String = getRemarks(); //preserve old remarks
@@ -181,10 +182,10 @@

 		public function getApplyRemarksOperation(remarks:String):UpdateRequestOperation {
 			var value:String = null;
-			if(ArrayUtil.isNotIn(REASON_BLANK_SYMBOLS, symbol)) {
+			var symbol:FieldSymbol = getSymbol(); //preserve old symbol
+			if(! isReasonBlankSymbol(symbol)) {
 				value = textToRequestValue(); //preserve old value
 			}
-			var symbol:FieldSymbol = getSymbol(); //preserve old symbol
 			var o:UpdateRequestOperation = getUpdateFieldOperation(value, symbol, remarks);
 			return o;
 		}
@@ -315,7 +316,11 @@
 		}

 		public static function isShortCutForReasonBlank(text:String):Boolean {
-			return ArrayUtil.isIn(REASON_BLANK_SYMBOLS, text);
+			return ArrayUtil.isIn(REASON_BLANK_SHORTCUTS, text);
+		}
+
+		public static function isReasonBlankSymbol(symbol:FieldSymbol):Boolean {
+			return ArrayUtil.isIn(REASON_BLANK_SYMBOLS, symbol);
 		}

 		protected function get dataClient():DataClient {


explicit naming for multiply4x4, multiply3x3 and multiply3x4 ShaderPart methods arguments


Added setShutdownOnRemove(), which is disabled by default, but will
automatically shutdown (stop the loading and unload()) when removed from the stage.

git-svn-id: b675b909355d5cf946977f44a8ec5a6ceb3782e4@479 ed5b42cb-e716-0410-a449-f6a68f950b19

--- src/as/com/threerings/flash/MediaContainer.as
+++ src/as/com/threerings/flash/MediaContainer.as
@@ -180,6 +180,16 @@
     }

     /**
+     * Sets whether this MediaContainer automatically shuts down when removed
+     * from the stage. By default this is not enabled.
+     */
+    public function setShutdownOnRemove (enable :Boolean = true) :void
+    {
+        var fn :Function = enable ? addEventListener : removeEventListener;
+        fn(Event.REMOVED_FROM_STAGE, handleShutdownOnRemove);
+    }
+
+    /**
      * A place where subclasses can initialize things prior to showing new media.
      */
     protected function willShowNewMedia () :void
@@ -591,6 +601,15 @@
     }

     /**
+     * Handle shutting us down when we're removed. Only called if
+     * setShutdownOnRemove() was enabled.
+     */
+    protected function handleShutdownOnRemove (event :Event) :void
+    {
+        shutdown();
+    }
+
+    /**
      * Configure the mask for this object.
      */
     protected function configureMask (rect :Rectangle) :void


Omigosh, let's capture any errors thrown while unloading media.
I was pretty sure the event handlers did this, but Annie sent me a trace
that would seem to indicate otherwise.

git-svn-id: b675b909355d5cf946977f44a8ec5a6ceb3782e4@573 ed5b42cb-e716-0410-a449-f6a68f950b19

--- src/as/com/threerings/flash/MediaContainer.as
+++ src/as/com/threerings/flash/MediaContainer.as
@@ -333,7 +333,11 @@
                 } catch (ioe :IOError) {
                     // ignore
                 }
-                loader.unload();
+                try {
+                    loader.unload();
+                } catch (e :Error) {
+                    // ignore
+                }
                 dispatchEvent(new Event(Event.UNLOAD));

                 removeChild(loader);


Change 20090220-bargull-Y8a by bargull@dell--p4--2-53 on 2009-02-20 00:53:38
    in /home/Admin/src/svn/openlaszlo/trunk
    for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: loadratio for swf9 and change for security check

New Features:

Bugs Fixed: LPP-7709, LPP-7716

Technical Reviewer: max
QA Reviewer: promanik
Doc Reviewer: (pending)

Documentation:

Release Notes:

Details:
Renamed sound playback related methods:
- "startPlay" to "startSoundPlay"
- "stopPlay" to "stopSoundPlay"
- "updatePlay" to "updateSoundPlay"
Removed "frames", "source", "lastreswidth", "lastresheight", "skiponload", "baseurl". All of them were either no longer needed or left-overs from the original dhtml kernel based sprite implementation.
Moved loadurl computation in "setSource" in a separate method ("getLoadURL").
Removed null-pointer check in "applyStretchResource" because it was done twice.
Moved framenumber computation and setting from "stop()" and "play()" into a separate method ("updateResourcePlay").

LPP-7709:
Add all loader-events immediately after constructing the Loader, even though the comment at "loaderInitHandler" says that it won't work (which is a lie). See event description for "init" (flash.display.LoaderInfo):
"Dispatched when the properties and methods of a loaded SWF file are accessible and ready for use."
So the "init"-event is dispatched far too late and therefore no "progress"-events were detected and therefore no "onloadratio"-events for users.
LPP-7716:
Don't use "parentAllowsChild"/"childAllowsParent" to avoid security exceptions, instead use a simple try-catch block when accessing the loaded content. Also moved the playback warning from "loaderEventHandler" to "stop"/"play", because otherwise these warnings did appear when loading a simple application in debug-mode (triggered by avm1movie assets for the debugger).

Tests:
testcase from LPP-7709, note that "onloadratio" events are generated
amazon-demo in swf9

git-svn-id: d62bde4b5aa582fdf07c8d403e53e0399a7ed285@12995 fa20e4f9-1d0a-0410-b5f3-dc9c16b8b17c

--- WEB-INF/lps/lfc/kernel/swf9/LzSprite.as
+++ WEB-INF/lps/lfc/kernel/swf9/LzSprite.as
@@ -30,7 +30,6 @@
   import flash.media.SoundTransform;
   import flash.media.SoundLoaderContext;
   import flash.media.ID3Info;
-
 }#

 #passthrough  {
@@ -48,18 +47,12 @@
       public var clickbutton:SimpleButton = null;
       public var clickregion:Shape = null;
       public var masksprite:Sprite = null;
-      public var frames:int = 1;
       public var resource:String = null;
-      public var source:String = null;
       public var clip:Boolean = false;
       public var resourcewidth:Number = 0;
       public var resourceheight:Number = 0;
       public var isroot:Boolean = false;
       public static var rootSprite:LzSprite = null;
-      var lastreswidth:Number = 0;
-      var lastresheight:Number = 0;
-      var skiponload = false;
-      var baseurl;

       // Used for workaround for contextmenu bug; use as a null hitArea for sprites that
       // we don't want to get mouse events.
@@ -84,7 +77,7 @@
       /* private */ var sound:Sound = null;
       /* private */ var soundChannel:SoundChannel = null;
       /* private */ var soundLoading:Boolean = false;
-
+
       //@field Boolean _setrescwidth: If true, the view does not set its
       //resource to the width given in a call to
       //<method>setAttribute</method>. By default, views do not scale their
@@ -219,7 +212,6 @@
       public function setResource (r:String):void {
           if (this.resource == r) return;
           if (r.indexOf('http:') == 0 || r.indexOf('https:') == 0) {
-              this.skiponload = false;
               this.setSource( r );
               return;
           }
@@ -240,7 +232,7 @@
               }
               return;
           }
-
+
           if (LzAsset.isBitmapAsset(r)
                 || LzAsset.isMovieClipAsset(r)
                 || LzAsset.isMovieClipLoaderAsset(r)) {
@@ -258,7 +250,7 @@
                   // clear resource cache
                   this.resourceCache = null;
               }
-
+
               this.__isinternalresource = true;
               this.resource = r;
               // instantiate resource at frame 1
@@ -270,13 +262,13 @@
               this.unload();
               this.__isinternalresource = true;
               this.resource = r;
-
+
               this.sound = new res['assetclass']() as Sound;
               this.totalframes = Math.floor(this.getTotalTime() * MP3_FPS);

               // TODO: add condition on this
-              this.startPlay()
-
+              this.startSoundPlay()
+
               // send events, but skip onload
               this.sendResourceLoad(true);
           } else if ($debug) {
@@ -287,7 +279,8 @@

       public var imgLoader:Loader;
       public var loaderMC:MovieClip;
-      private var IMGDEPTH:int = 0;
+      private const IMGDEPTH:int = 0;
+      private static const MIME_SWF:String = "application/x-shockwave-flash";

       /** setSource( String:url )
           o Loads and displays media from the specified url
@@ -297,10 +290,50 @@
           if (url == null || url == 'null') {
               return;
           }
-          var loadurl = url;
-          var proxied = this.owner.__LZcheckProxyPolicy( url );
-          var proxyurl = this.owner.getProxyURL(url);
+          var loadurl:String = getLoadURL(url, cache, headers);
+          if (getFileType(url, filetype) == "mp3") {
+              // unload previous image-resource and sound-resource
+              this.unload();
+              this.__isinternalresource = false;
+              this.resource = url;
+              this.loadSound(loadurl);
+          } else {
+              if (this.isaudio) {
+                  // unload previous sound-resource
+                  this.unloadSound();
+              }
+
+              if (! imgLoader) {
+                  if (this.resourceContainer) {
+                      // unload previous internal image-resource
+                      this.unload();
+                  }
+                  imgLoader = new Loader();
+                  imgLoader.mouseEnabled = false;// @devnote: see LPP-7022
+                  imgLoader.mouseChildren = false;
+                  this.resourceContainer = imgLoader;
+                  this.addChildAt(imgLoader, IMGDEPTH);
+                  this.attachLoaderEvents(imgLoader.contentLoaderInfo);
+              } else {
+                  //TODO [20080911 anba] cancel current load?
+                  // imgLoader.close();
+              }
+              this.__isinternalresource = false;
+              this.resource = url;
+              var res = this.imgLoader;
+              if (res) {
+                  res.scaleX = res.scaleY = 1.0;
+              }
+
+              imgLoader.load(new URLRequest(loadurl), LzSprite.loaderContext);
+          }
+      }
+
+      private function getLoadURL (url:String, cache:String, headers:String) :String {
+          var loadurl:String = url;
+          var proxied:* = this.owner.__LZcheckProxyPolicy( url );
           if (proxied) {
+              var proxyurl:String = this.owner.getProxyURL(url);
               var params:Object = {serverproxyargs: {},
                                    timeout: canvas.medialoadtimeout,
                                    proxyurl: proxyurl,
@@ -326,49 +359,10 @@
               }
               loadurl = lz.Browser.makeProxiedURL(params);
           }
-
-          if (getFileType(url, filetype) == "mp3") {
-              // unload previous image-resource and sound-resource
-              this.unload();
-              this.__isinternalresource = false;
-              this.resource = url;
-              this.loadSound(loadurl);
-          } else {
-              if (this.isaudio) {
-                  // unload previous sound-resource
-                  this.unloadSound();
-              }
-
-              if (! imgLoader) {
-                  if (this.resourceContainer) {
-                      // unload previous internal image-resource
-                      this.unload();
-                  }
-                  imgLoader = new Loader();
-                  imgLoader.mouseEnabled = false;// @devnote: see LPP-7022
-                  imgLoader.mouseChildren = false;
-                  this.resourceContainer = imgLoader;
-                  this.addChildAt(imgLoader, IMGDEPTH);
-                  var info:LoaderInfo = imgLoader.contentLoaderInfo;
-                  info.addEventListener(Event.INIT, loaderInitHandler);
-                  info.addEventListener(IOErrorEvent.IO_ERROR, loaderEventHandler);
-              } else {
-                  //TODO [20080911 anba] cancel current load?
-                  // imgLoader.close();
-              }
-              this.__isinternalresource = false;
-              this.resource = url;
-              var res = this.imgLoader;
-              if (res) {
-                  res.scaleX = res.scaleY = 1.0;
-              }
-
-              imgLoader.load(new URLRequest(loadurl), LzSprite.loaderContext);
-          }
-      }
-
-
-      private function getFileType (url:String, filetype:String = null) :String {
+          return loadurl;
+      }
+
+      private function getFileType (url:String, filetype:String) :String {
           if (filetype != null) {
               return filetype.toLowerCase();
           } else {
@@ -377,23 +371,20 @@
           }
       }

-      public function loaderInitHandler(event:Event):void {
-          // These progress event listeners can only be installed after the init event
-          // has been received. You get an error if you try to add them before this.
-          var loader:Loader = Loader(event.target.loader);
-          var info:LoaderInfo = LoaderInfo(loader.contentLoaderInfo);
+      private function attachLoaderEvents (info:LoaderInfo) :void {
           info.addEventListener(ProgressEvent.PROGRESS, loaderEventHandler);
           info.addEventListener(Event.OPEN, loaderEventHandler);
-          info.addEventListener(Event.UNLOAD, loaderEventHandler);
+          // info.addEventListener(Event.UNLOAD, loaderEventHandler);
+          // info.addEventListener(Event.INIT, loaderEventHandler);
           info.addEventListener(Event.COMPLETE, loaderEventHandler);
           info.addEventListener(SecurityErrorEvent.SECURITY_ERROR, loaderEventHandler);
+          info.addEventListener(IOErrorEvent.IO_ERROR, loaderEventHandler);
           // @devnote: From the HTTPStatusEvent reference page:
           // > Some Flash Player environments may be unable to detect HTTP status codes;
           // > a status code of 0 is always reported in these cases.
           // Http status is actually only available for the IE Flash-Plugin.
           //info.addEventListener(HTTPStatusEvent.HTTP_STATUS, loaderEventHandler);
       }
-

       public function loaderEventHandler(event:Event):void {
           try {
@@ -411,29 +402,34 @@
                   }

                   var info:LoaderInfo = event.target as LoaderInfo;
-                  // avoid security exceptions
-                  if (info.parentAllowsChild) {
-                      if (info.content is AVM1Movie) {
-                          if ($debug) {
-                              Debug.warn("Playback control will not work for the resource.  Please update or recompile the resource for Flash 9.", this.resource);
-                          }
-                      } else if (info.content is MovieClip) {
+                  try {
+                      // accessing LoaderInfo.content may throw security exceptions
+                      var content:DisplayObject = info.content;
+                      if (content is AVM1Movie) {
+                          // no playback control
+                      } else if (content is MovieClip) {
                           // store a reference for playback control
-                          this.loaderMC = MovieClip(info.content);
+                          this.loaderMC = MovieClip(content);
                           this.totalframes = this.loaderMC.totalFrames;
                           this.loaderMC.addEventListener(Event.ENTER_FRAME, updateFrames);
                           this.owner.resourceevent('play', null, true);
                           this.playing = this.owner.playing = true;
-                      } else if (info.content is Bitmap) {
-                          (info.content as Bitmap).smoothing = true;
+                      } else if (content is Bitmap) {
+                          (content as Bitmap).smoothing = true;
                       }
+                  } catch (error:SecurityError) {
+                      // ignore for now
                   }

                   try {
-                      var loader:Loader = Loader(event.target.loader);
+                      // accessing LoaderInfo.loader may throw security exceptions
+                      // TODO [20090203 anba] why can't we use LoaderInfo.width/height,
+                      // which won't generate security exceptions?
+                      var loader:Loader = Loader(info.loader);
                       this.resourcewidth = loader.width;
                       this.resourceheight = loader.height;
-                  } catch (e) {
+                  } catch (error:SecurityError) {
+                      // TODO [20090203 anba] install default values?
                   }
                   // Apply stretch if needed, now that we know the asset dimensions.
                   this.applyStretchResource();
@@ -444,8 +440,8 @@
                          event.type == SecurityErrorEvent.SECURITY_ERROR) {
                   //TODO [20080911 anba] how can "owner" become null here?
                   if (this.owner != null) {
-                      // IOErrorEvent/SecurityErrorEvent -> ErrorEvent -> TextEvent
-                      this.owner.resourceloaderror( (event as TextEvent).text );
+                      // IOErrorEvent/SecurityErrorEvent -> ErrorEvent
+                      this.owner.resourceloaderror( (event as ErrorEvent).text );
                   }
               } else if (event.type == ProgressEvent.PROGRESS) {
                   var ev:ProgressEvent = event as ProgressEvent;
@@ -488,20 +484,20 @@
           this.sound.addEventListener(Event.COMPLETE, soundLoadHandler);
           this.sound.addEventListener(ProgressEvent.PROGRESS, soundLoadHandler);
           this.sound.addEventListener(IOErrorEvent.IO_ERROR, soundLoadHandler);
-
+
           this.sound.load(new URLRequest(url), LzSprite.soundLoaderContext);
-
+
           // TODO: add condition on this
-          this.startPlay();
-      }
-
+          this.startSoundPlay();
+      }
+
       /**
         * Stop current playback and unload sound
         */
       private function unloadSound () :void {
           if (this.playing) {
               // stop playing
-              this.stopPlay();
+              this.stopSoundPlay();
           }
           if (this.sound) {
               if (this.soundLoading) {
@@ -512,15 +508,15 @@
               this.sound = null;
           }
       }
-
+
       /**
         * Start sound playback and tracking
         * @param Number frame: frame/secs to start at playing
         * @param Boolean isFrame: if set to false, treat 'frame' as seconds
         */
-      private function startPlay (frame:Number = 0, isFrame:Boolean = true) :void {
+      private function startSoundPlay (frame:Number = 0, isFrame:Boolean = true) :void {
           var pos:Number = (isFrame ? (frame / MP3_FPS) : frame) * 1000;
-
+
           this.playing = this.owner.playing = true;
           this.soundChannel = this.sound.play(pos, 0, this.soundTransform);
           this.addEventListener(Event.ENTER_FRAME, soundFrameHandler);
@@ -531,31 +527,31 @@
         * Stop sound playback and tracking
         * @return Number: the current frame when playback was stopped
         */
-      private function stopPlay () :Number {
+      private function stopSoundPlay () :Number {
           var frame:Number = Math.floor(this.soundChannel.position * 0.001 * MP3_FPS);
-
+
           this.playing = this.owner.playing = false;
           this.removeEventListener(Event.ENTER_FRAME, soundFrameHandler);
           this.soundChannel.stop();
           this.soundChannel = null;
-
+
           return frame;
       }
-
+
       /**
         * Update sound play status
         */
-      private function updatePlay (play:Boolean, framenumber:*, rel:Boolean) :void {
+      private function updateSoundPlay (play:Boolean, framenumber:*, rel:Boolean) :void {
           var fr:Number;
           if (this.playing) {
               // stop previous playback
-              fr = this.stopPlay();
+              fr = this.stopSoundPlay();
           } else {
               // TODO: this.frame is initialized with 1, which
               // means we currently skip 33ms at the beginning
               fr = this.frame;
           }
-
+
           if (framenumber != null) {
               framenumber += rel ? fr : 0;
           } else if (play) {
@@ -565,14 +561,14 @@
           } else {
               framenumber = fr;
           }
-
+
           if (play) {
-              this.startPlay(framenumber);
+              this.startSoundPlay(framenumber);
           } else {
               this.frame = framenumber;
           }
       }
-
+
       /**
         * Progress sound loading
         */
@@ -600,10 +596,10 @@
                   this.owner.resourceloaderror( (event as IOErrorEvent).text );
               }
           } catch (error:Error) {
-              trace(event.type + " " + error);
-          }
-      }
-
+              if ($debug) Debug.warn(event.type + " " + error);
+          }
+      }
+
       /**
         * Track playback
         */
@@ -619,7 +615,7 @@
       private function soundCompleteHandler (event:Event) :void {
           // Event.SOUND_COMPLETE
           if (this.playing) {
-              this.stopPlay();
+              this.stopSoundPlay();
               this.frame = this.totalframes;

               // SoundChannel.position does not stop exactly at Sound.length,
@@ -629,7 +625,7 @@
               this.owner.resourceevent('lastframe', null, true);
           }
       }
-
+
       //// Mouse event trampoline
       public function attachMouseEvents(dobj:DisplayObject) :void {
           dobj.addEventListener(MouseEvent.CLICK, __mouseEvent, false);
@@ -963,24 +959,20 @@
       public function play (framenumber:* = null, rel:Boolean = false) :void {
           if (this.isaudio) {
               // audio-resource is attached
-              this.updatePlay(true, framenumber, rel);
-
+              this.updateSoundPlay(true, framenumber, rel);
+
               this.owner.resourceevent('play', null, true);
           } else if (this.__isinternalresource) {
               stop(framenumber, rel);
           } else if (this.loaderMC) {
               this.owner.resourceevent('play', null, true);
-              this.playing = this.owner.playing = true;
-              if (framenumber == null) {
-                  this.loaderMC.play();
-              } else {
-                  if (rel) framenumber += this.frame;
-                  if (framenumber > this.totalframes) {
-                      framenumber = this.totalframes;
-                  } else if (framenumber < 1) {
-                      framenumber = 1;
+              this.updateResourcePlay(true, framenumber, rel);
+          } else if (this.imgLoader) {
+              if ($debug) {
+                  var info:LoaderInfo = this.imgLoader.contentLoaderInfo;
+                  if (info.contentType == LzSprite.MIME_SWF && info.swfVersion < SWFVersion.FLASH9) {
+                      Debug.warn("Playback control will not work for the resource. Please update or recompile the resource for Flash 9.", this.resource);
                   }
-                  this.loaderMC.gotoAndPlay(framenumber);
               }
           } else {
               //Debug.write('unhandled play', framenumber, rel);
@@ -996,15 +988,15 @@
           if (this.isaudio) {
               // audio-resource is attached
               var p:Boolean = this.playing;
-              this.updatePlay(false, fn, rel);
-
+              this.updateSoundPlay(false, fn, rel);
+
               if (p) this.owner.resourceevent('stop', null, true);
           } else if (this.__isinternalresource) {
               var resinfo:Object = LzResourceLibrary[this.resource];

               // Frames are one based not zero based
               var frames:Array = resinfo.frames;
-              var origfn = fn;
+              var origfn:* = fn;
               if (fn == null || fn < 1) {
                   origfn = fn = 1;
               } else if (fn > frames.length) {
@@ -1030,7 +1022,7 @@
                   if (asset == null) {
                       //Debug.write('CACHE MISS, new ',assetclass);
                       asset = new assetclass();
-                      asset.scaleX = 1.0
+                      asset.scaleX = 1.0;
                       asset.scaleY = 1.0;
                       this.resourceCache[framenumber] = asset;
                   }
@@ -1043,7 +1035,7 @@
                       LzIdleKernel.addCallback(this, '__resetframe');
                       return;
                   }
-
+
                   if (this.resourceContainer != null) {
                       this.removeChild(this.resourceContainer);
                   }
@@ -1052,7 +1044,7 @@
                   if (asset is DisplayObjectContainer) DisplayObjectContainer(asset).mouseChildren = false;

                   this.resourceContainer = asset;
-                  this.addChildAt(asset,IMGDEPTH);
+                  this.addChildAt(asset, IMGDEPTH);

                   this.applyStretchResource();

@@ -1078,21 +1070,41 @@
               }
           } else if (this.loaderMC) {
               if ( this.playing ) this.owner.resourceevent('stop', null, true);
-              this.playing = this.owner.playing = false;
-              if (fn == null) {
-                  this.loaderMC.stop();
-              } else {
-                  if (rel) fn += this.frame;
-                  if (fn > this.totalframes) {
-                      fn = this.totalframes;
-                  } else if (fn < 1) {
-                      fn = 1;
+              this.updateResourcePlay(false, fn, rel);
+          } else if (this.imgLoader) {
+              if ($debug) {
+                  var info:LoaderInfo = this.imgLoader.contentLoaderInfo;
+                  if (info.contentType == LzSprite.MIME_SWF && info.swfVersion < SWFVersion.FLASH9) {
+                      Debug.warn("Playback control will not work for the resource. Please update or recompile the resource for Flash 9.", this.resource);
                   }
-                  this.loaderMC.gotoAndStop(fn);
               }
           } else {
               // This shouldn't happen - but it does, on roll over
               //Debug.write('unhandled stop', fn, rel);
+          }
+      }
+
+      private function updateResourcePlay (play:Boolean, framenumber:*, rel:Boolean) :void {
+          this.playing = this.owner.playing = play;
+
+          if (framenumber == null) {
+              if (play) {
+                  this.loaderMC.play();
+              } else {
+                  this.loaderMC.stop();
+              }
+          } else {
+              if (rel) framenumber += this.frame;
+              if (framenumber > this.totalframes) {
+                  framenumber = this.totalframes;
+              } else if (framenumber < 1) {
+                  framenumber = 1;
+              }
+              if (play) {
+                  this.loaderMC.gotoAndPlay(framenumber);
+              } else {
+                  this.loaderMC.gotoAndStop(framenumber);
+              }
           }
       }

@@ -1168,10 +1180,6 @@
       }

       public function applyStretchResource():void {
-          if (this.resourceContainer == null) {
-              return;
-          }
-
           var res = this.resourceContainer;

           // Don't try to do anything while an image is loading
@@ -1335,7 +1343,7 @@
         }
         if (this.isaudio) this.unloadSound();
         // clear out cached values
-        this.lastreswidth = this.lastresheight = this.resourcewidth = this.resourceheight = 0;
+        this.resourcewidth = this.resourceheight = 0;
         this.resource = null;
         this.__isinternalresource = null;
         if (this.loaderMC) {
@@ -1468,7 +1476,7 @@
       function getPan () :Number {
           return LzAudioKernel.getPan(this);
       }
-
+
       /**
         * @param Number secs:
         * @param Boolean playing:
@@ -1482,16 +1490,16 @@
               if (pos > total) pos = total;

               if (this.playing) {
-                  this.stopPlay();
+                  this.stopSoundPlay();
               }
               if (doplay) {
-                  this.startPlay(pos, false);
+                  this.startSoundPlay(pos, false);
               } else {
                   this.frame = Math.floor(pos * MP3_FPS);
               }
           }
       }
-
+
       /**
         * @return Number: time elapsed (in seconds)
         */
@@ -1507,14 +1515,14 @@
               return 0;
           }
       }
-
+
       /**
         * @return Number: length of the current sound (in seconds)
         */
       function getTotalTime () :Number {
           return this.isaudio ? this.sound.length * 0.001 : 0;
       }
-
+
       /**
         * @return ID3Info: id3-info of the current sound
         */


added method to transform color

added method to transform color

git-svn-id: e38e7cdd6ace00d8230583a2d3b43e9a55f5c011@513 bc4816be-ef27-423a-9c4d-fc420be121a2

--- src/reprise/utils/ColorUtil.as
+++ src/reprise/utils/ColorUtil.as
@@ -80,6 +80,20 @@
 		public static function randomColor() : Number
 		{
 			return (Math.random() * 255) << 16 | (Math.random() * 255) << 8 | (Math.random() * 255);
+		}
+
+		public static function transformColorByValue(color:int, value:int):int
+		{
+			var clr:Object = number2rgbObject(color);
+			for (var key:String in clr)
+			{
+				var clrValue:int = int(clr[key]);
+				clrValue += value;
+				clrValue = Math.max(0, clrValue);
+				clrValue = Math.min(255, clrValue);
+				clr[key] = clrValue;
+			}
+			return int(rgbObject2Number(clr));
 		}


Two hexdump methods for low-level debugging that have been extremely useful to me this evening.

git-svn-id: a1a4b28b82a3276cc491891159dd9963a0a72fae@5076 542714f4-19e9-0310-aa3c-eee0fc999fb1

--- src/as/com/threerings/util/StringUtil.as
+++ src/as/com/threerings/util/StringUtil.as
@@ -462,6 +462,42 @@
     }

     /**
+     * Return a hexadecimal representation of an unsigned int, potentially left-padded with
+     * zeroes to arrive at of precisely the requested width, e.g.
+     *       toHex(131, 4) -> "0083"
+     */
+    public static function toHex (n :uint, width :uint) :String
+    {
+        var result :String = "";
+        while (width > 0) {
+            result = HEX[n & 0x0f] + result;
+            n >>>= 4;
+            width --;
+        }
+        return result;
+    }
+
+    /**
+     * Create line-by-line hexadecimal output with a counter, much like the
+     * 'hexdump' Unix utility. For debugging purposes.
+     */
+    public static function hexdump (bytes :ByteArray) :String
+    {
+        var str :String = "";
+        for (var lineIx :int = 0; lineIx < bytes.length; lineIx += 16) {
+            str += toHex(lineIx, 4);
+            for (var byteIx :int = 0; byteIx < 16 && lineIx + byteIx < bytes.length; byteIx ++) {
+                var b :uint = bytes[lineIx + byteIx];
+                str += " " + HEX[b >> 4] + HEX[b & 0x0f];
+            }
+            str += "\n";
+        }
+        return str;
+
+    }
+
+
+    /**
      * Internal helper function for parseNumber.
      */
     protected static function validateDecimal (str :String, allowDot :Boolean, allowTrailingE :Boolean) :String


Added endsWith().

Added endsWith().

git-svn-id: a1a4b28b82a3276cc491891159dd9963a0a72fae@4226 542714f4-19e9-0310-aa3c-eee0fc999fb1

--- src/as/com/threerings/util/StringUtil.as
+++ src/as/com/threerings/util/StringUtil.as
@@ -10,6 +10,15 @@
     }

     /**
+     * Does the specified string end with the specified substring.
+     */
+    public static function endsWith (str :String, substr :String) :Boolean
+    {
+        var startDex :int = str.length - substr.length;
+        return (startDex >= 0) && (str.indexOf(substr, startDex) > 0);
+    }
+
+    /**
      * Utility function that strips whitespace from the ends of a String.
      */
     public static function trim (str :String) :String


fix https://code.google.com/p/gaforflash/issues/detail?id=104

--- src/com/google/analytics/core/Organic.as
+++ src/com/google/analytics/core/Organic.as
@@ -260,7 +260,7 @@
          */
         public function match( name:String ):Boolean
         {
-            if( name == "" )
+            if( !name )
             {
                 return false;
             }


Fullscreen event error

Fullscreen event error

Fixed an error where the fullscreenExited event didn't trigger when
pressing ESC.

--- src/Player.as
+++ src/Player.as
@@ -82,6 +82,7 @@
       this.stage.addEventListener(MouseEvent.DOUBLE_CLICK, fullscreen);
       this.stage.addEventListener(Event.FULLSCREEN, function(event:Event):void {
         videoResize();
+        (StageDisplayState.NORMAL === stage.displayState) ? callAPI(EVENT_FULLSCREEN_EXITED) : callAPI(EVENT_FULLSCREEN_ENTERED);
       });
     }

@@ -119,7 +120,6 @@
       if (config.allowFullscreen) {
         this.stage.displayState = (StageDisplayState.NORMAL === stage.displayState) ?
           StageDisplayState.FULL_SCREEN : StageDisplayState.NORMAL;
-          (StageDisplayState.NORMAL === stage.displayState) ? this.callAPI(EVENT_FULLSCREEN_EXITED) : this.callAPI(EVENT_FULLSCREEN_ENTERED);
       }
     }


clean-up URL loader when disposing

clean-up URL loader when disposing

--- src/org/mangui/hls/loader/LevelLoader.as
+++ src/org/mangui/hls/loader/LevelLoader.as
@@ -75,6 +75,7 @@
                 _urlloader.removeEventListener(ProgressEvent.PROGRESS, _loadProgressHandler);
                 _urlloader.removeEventListener(IOErrorEvent.IO_ERROR, _errorHandler);
                 _urlloader.removeEventListener(SecurityErrorEvent.SECURITY_ERROR, _errorHandler);
+                _urlloader = null;
             }
             _hls.removeEventListener(HLSEvent.PLAYBACK_STATE, _stateHandler);
             _hls.removeEventListener(HLSEvent.LEVEL_SWITCH, _levelSwitchHandler);


REPRISE RadioButtonGroup super.reset() removed

git-svn-id: e38e7cdd6ace00d8230583a2d3b43e9a55f5c011@612 bc4816be-ef27-423a-9c4d-fc420be121a2

--- src/reprise/controls/RadioButtonGroup.as
+++ src/reprise/controls/RadioButtonGroup.as
@@ -64,7 +64,6 @@

 		public function reset():void
 		{
-			super.reset();
 			for (var i:int = 0; i < m_radioButtons.length; i++)
 			{
 				var rbtn:RadioButton = m_radioButtons[i] as RadioButton;


Add a missing break that caused the waiting state to perform logic for "winning".


buffer parameters

buffer parameters

4 buffer parameters are ready for implementation
initialBufferTime
expandedBufferTime
maxBufferTime
segmentBuffer renamed to liveSegmentBuffer

--- KalturaHLSPlugin/src/KalturaHLSPlugin.as
+++ KalturaHLSPlugin/src/KalturaHLSPlugin.as
@@ -29,8 +29,10 @@
         private static const HLS_PLUGIN_INFO:String = "com.kaltura.hls.HLSPluginInfo";
 		private var _pluginResource:MediaResourceBase;

-		private var _segmentBuffer:int = -1;
-		private var _overrideTargetDuration:int = -1;
+		private var _liveSegmentBuffer:int = -1; // Live only - number of segments to download and process before start playing
+		private var _initialBufferTime:int = -1; // initial buffer length till the moment the video starts playing
+		private var _expandedBufferTime:int = -1; // acctual buffer length while the video is playing
+		private var _maxBufferTime:int = -1; // maximum buffer length while the video is playing
 		private var _sendLogs:Boolean = false;

         public function KalturaHLSPlugin()
@@ -39,22 +41,42 @@
             _pluginInfo = new HLSPluginInfo();
         }

-		public function get segmentBuffer():int
+		public function get liveSegmentBuffer():int
 		{
-			return _segmentBuffer;
+			return _liveSegmentBuffer;
 		}

-		public function set segmentBuffer(value:int):void
+		public function set liveSegmentBuffer(value:int):void
 		{
-			_segmentBuffer = value;
+			_liveSegmentBuffer = value;
 		}

-		public function get overrideTargetDuration():int{
-			return _overrideTargetDuration;
+		public function get initialBufferTime():int
+		{
+			return _initialBufferTime;
+		}
+
+		public function set initialBufferTime(value:int):void
+		{
+			_initialBufferTime = value;
+		}
+
+		public function get expandedBufferTime():int
+		{
+			return _expandedBufferTime;
+		}
+
+		public function set expandedBufferTime(value:int):void
+		{
+			_expandedBufferTime = value;
+		}
+
+		public function get maxBufferTime():int{
+			return _maxBufferTime;
 		}

-		public function set overrideTargetDuration(value:int):void{
-			_overrideTargetDuration = value;
+		public function set maxBufferTime(value:int):void{
+			_maxBufferTime = value;
 		}

 		public function get sendLogs():Boolean{
@@ -94,12 +116,12 @@
         {
 			if ( e.resource && e.resource == _pluginResource ) {
 				e.target.removeEventListener(MediaFactoryEvent.PLUGIN_LOAD, onOSMFPluginLoaded);
-				if (segmentBuffer != -1){
-					HLSManifestParser.MAX_SEG_BUFFER = segmentBuffer; // if passed by JS, update static MAX_SEG_BUFFER with the new value
+				if (liveSegmentBuffer != -1){
+					HLSManifestParser.MAX_SEG_BUFFER = liveSegmentBuffer; // if passed by JS, update static MAX_SEG_BUFFER with the new value (relevant for LIVE only)
 				}
-				if (overrideTargetDuration != -1){
-					HLSManifestParser.OVERRIDE_TARGET_DURATION = overrideTargetDuration;
-				}
+				//if (initialBufferTime != -1){
+				//	HLSManifestParser.OVERRIDE_TARGET_DURATION = initialBufferTime;
+				//}
 				if (sendLogs){
 					M2TSFileHandler.SEND_LOGS = true;
 					HLSManifestParser.SEND_LOGS = true;


Transferred from the Adobe Open Source Subversion Repository

Revision: 1570
Author:   jimurphy@adobe.com
Date:     2008-05-06T17:43:41.713917Z

Log Message:
-----------
Merge 3.0.x revision [1569] -> trunk

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/MenuBar.as</path>
<path kind="dir" action="M">/flex/sdk/trunk</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/TitleWindow.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/DataGrid.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Tree.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/DragManager.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/DividedBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/FormItem.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/Menu.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/SWFLoader.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1258867 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/controls/SWFLoader.as
+++ frameworks/projects/framework/src/mx/controls/SWFLoader.as
@@ -145,7 +145,7 @@
 /**
  *  The name of the class to use as the SWFLoader skin if the control cannot load
  *  the content.
- *  @default BrokenImageSkin
+ *  The default value is the "__brokenImage" symbol in the Assets.swf file.
  */
 [Style(name="brokenImageSkin", type="Class", inherit="no")]

@@ -256,7 +256,7 @@
  *
  *    Styles
  *    brokenImageBorderSkin="BrokenImageBorderSkin"
- *    brokenImageSkin="BrokenImageSkin"
+ *    brokenImageSkin="'__brokenImage' symbol in Assets.swf"
  *    horizontalAlign="left|center|right"
  *    verticalAlign="top|middle|bottom"
  *


Transferred from the Adobe Open Source Subversion Repository

Revision: 23243
Author:   cframpto@adobe.com
Date:     2011-12-20T00:59:57.384047Z

Log Message:
-----------
In frameworks, remove Adobe headers from all files except xml/mxml file types.  There are also a few .txt files that are license files that I didn't touch yet.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1259214 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/core/FlexTextField.as
+++ frameworks/projects/framework/src/mx/core/FlexTextField.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2006 Adobe Systems Incorporated
-//  All Rights Reserved.
-//
-//  NOTICE: Adobe permits you to use, modify, and distribute this file
-//  in accordance with the terms of the license agreement accompanying it.
-//
-////////////////////////////////////////////////////////////////////////////////

 package mx.core
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 4520
Author:   gosmith@adobe.com
Date:     2009-01-14T01:07:53.388463Z

Log Message:
-----------
Accessibility changes to List, DataGrid, Menu, and Tree, as requested by Freedom Scientific, to behave more like their corresponding standard Windows controls.

List, DataGrid, and Menu no longer report an accessibility value, either for the control itself or for its child items.

Tree no longer reports a value value for itself. For tree items the value is the indentation level as a String: "0", "1", "2", etc. Previously the top-level items had value "1" instead of "0".

QE Notes: None
Doc Notes: None
Bugs: SDK-17755
Reviewer: Deepa

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/DataGridAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/TreeAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/MenuAccImpl.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/framework/src/mx/accessibility/ListBaseAccImpl.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1267505 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/mx/src/mx/accessibility/TreeAccImpl.as
+++ frameworks/projects/mx/src/mx/accessibility/TreeAccImpl.as
@@ -14,8 +14,9 @@

 import flash.accessibility.Accessibility;
 import flash.events.Event;
+
+import mx.collections.CursorBookmark;
 import mx.collections.ICollectionView;
-import mx.collections.CursorBookmark;
 import mx.collections.IViewCursor;
 import mx.controls.Tree;
 import mx.controls.listClasses.IListItemRenderer;
@@ -185,8 +186,8 @@
 	 *  @private
 	 *  IAccessible method for returning the value of the TreeItem/Tree
 	 *  which is spoken out by the screen reader
-	 *  The Tree should return the name of the currently selected item
-	 *  with m of n string with level info as value when focus moves to Tree.
+	 *  A Tree item reports its depth as its value.
+	 *  The Tree itself reports no value.
 	 *
 	 *  @param childID uint
 	 *
@@ -196,36 +197,19 @@
 	{
 		var accValue:String;

-		var tree:Tree = Tree(master);
-		var index:int;
-		var item:Object;
-
-		if (childID == 0)
-		{
-			index = tree.selectedIndex;
-			if (index > -1)
-			{
-				item = getItemAt(index);
-				if (!item)
-					return accValue;
-
-				if (tree.itemToLabel(item))
-					accValue = tree.itemToLabel(item)
-
-				accValue += getMOfN(item);
-			}
-		}
-		else
+		if (childID != 0)
 		{
 			// Assuming childID is always ItemID + 1
 			// because getChildIDArray is not always invoked.
-			index = childID - 1;
-
-			item = getItemAt(index);
+			var index:int = childID - 1;
+			var item:Object = getItemAt(index);
 			if (!item)
 				return accValue;

-			accValue = tree.getItemDepth(item, index - tree.verticalScrollPosition) + "";
+			var tree:Tree = Tree(master);
+			var depth:int = tree.getItemDepth(
+				item, index - tree.verticalScrollPosition);
+			accValue = String(depth - 1);
 		}

 		return accValue;


Transferred from the Adobe Open Source Subversion Repository

Revision: 3539
Author:   clucier@adobe.com
Date:     2008-10-09T17:58:31.015346Z

Log Message:
-----------
Updated RadioButtonGroup to account for recent changes to LayoutManager priority queue.  The order that a RadioButtonGroup was traversed was always dependent on what order that the radio buttons properties were validated. Since this assumption no longer holds true, we are now very specific about how the group orders the RadioButtons (breadth-first for consistency with Flex 2 and Flex 3).
Check-in Tests: Pass
Mustella Tests: (RadioButton, RadioButtonGroup) Pass
Reviewer: Glenn
QA: Yes
Bugs: SDK-17248

Modified Paths:
--------------
/flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/RadioButtonGroup.as

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1268445 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/mx/src/mx/controls/RadioButtonGroup.as
+++ frameworks/projects/mx/src/mx/controls/RadioButtonGroup.as
@@ -12,12 +12,16 @@
 package mx.controls
 {

+import flash.display.DisplayObject;
+import flash.display.DisplayObjectContainer;
 import flash.events.Event;
 import flash.events.EventDispatcher;
 import mx.core.Application;
 import mx.core.IFlexDisplayObject;
 import mx.core.IMXMLObject;
+import mx.core.IRawChildrenContainer;
 import mx.core.mx_internal;
+import mx.core.UIComponent;
 import mx.events.FlexEvent;
 import mx.events.ItemClickEvent;

@@ -137,12 +141,6 @@
      */
     private var radioButtons:Array /* of RadioButton */ = [];

-    /**
-     *  @private
-     *  Index for the next RadioButton added to this group.
-     */
-    private var indexNumber:int = 0;
-
     //--------------------------------------------------------------------------
     //
     //  Properties
@@ -398,10 +396,14 @@
      */
     mx_internal function addInstance(instance:RadioButton):void
     {
-        instance.indexNumber = indexNumber++;
         instance.addEventListener(Event.REMOVED, radioButton_removedHandler);
-        radioButtons.push(instance);
-
+        radioButtons.push(instance);
+
+        // Apply group indices in "breadth-first" order.
+        radioButtons.sort(breadthOrderCompare);
+        for (var i:int = 0; i < radioButtons.length; i++)
+            radioButtons[i].indexNumber = i;
+
         if (_selectedValue != null)
             selectedValue = _selectedValue;

@@ -438,7 +440,6 @@
                     // Remove the radio button from the internal array
                     radioButtons.splice(i,1);
                     foundInstance = true;
-                    indexNumber--;
                     // redo the same index because we removed the previous item at this index
                     i--;
                 }
@@ -520,6 +521,38 @@
         }
     }

+    /**
+     *  @private
+     */
+    private function breadthOrderCompare(a:DisplayObject, b:DisplayObject):Number
+    {
+        var aParent:DisplayObject = a.parent;
+        var bParent:DisplayObject = b.parent;
+
+        if (!aParent || !bParent)
+            return 0;
+
+        var aNestLevel:int = (a is UIComponent) ? UIComponent(a).nestLevel : -1;
+        var bNestLevel:int = (b is UIComponent) ? UIComponent(b).nestLevel : -1;
+
+        var aIndex:int = aParent is IRawChildrenContainer ?
+            IRawChildrenContainer(aParent).rawChildren.getChildIndex(a) :
+            DisplayObjectContainer(aParent).getChildIndex(a);
+
+        var bIndex:int = bParent is IRawChildrenContainer ?
+            IRawChildrenContainer(bParent).rawChildren.getChildIndex(b) :
+            DisplayObjectContainer(bParent).getChildIndex(b);
+
+        if (aNestLevel > bNestLevel || (a.parent == b.parent && aIndex > bIndex))
+            return 1;
+        else if (aNestLevel < bNestLevel ||  (a.parent == b.parent && bIndex > aIndex))
+            return -1;
+        else if (a == b)
+            return 0;
+        else // Nest levels are identical, compare ancestors.
+            return breadthOrderCompare(aParent, bParent);
+    }
+
     //--------------------------------------------------------------------------
     //
     //  Event Handlers


Transferred from the Adobe Open Source Subversion Repository

Revision: 18139
Author:   hmuller@adobe.com
Date:     2010-10-12T19:02:33.052295Z

Log Message:
-----------
Data,Grid variableRowHeight is now false by default.

The DefaultGridItemRenderer and UITextFieldItemRenderer classes now configure their wordWrap property to match variableRowHeight, unless wordWrap is explicitly specified.

Fixed layoutItemRenderers() which had never (!) called the prepare()/discard() IGridItemRenderer methods.

Fixed GridDimensions/getTypicalContentHeight() - removed dependency on variableRowHeight.

QE notes: This commit's cyclone failures have been vetted
Doc notes:
Bugs: SDK-28179
Reviewer: Kevin
Tests run: checkin, mustella cyclone
Is noteworthy for integration: no

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/IGridItemRenderer.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/skins/spark/UITextFieldGridItemRenderer.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Grid.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GridDimensions.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/skins/spark/TextFieldGridItemRendererInclude.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GridLayout.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/DataGrid.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/skins/spark/DefaultGridItemRenderer.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1278557 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/DataGrid.as
+++ frameworks/projects/spark/src/spark/components/DataGrid.as
@@ -640,7 +640,7 @@
         rowHeight: NaN,
         showDataTips: false,
         typicalItem: null,
-        variableRowHeight: true,
+        variableRowHeight: false,
         dataTipField: null,
         dataTipFunction: null
     };


Transferred from the Adobe Open Source Subversion Repository

Revision: 4284
Author:   gosmith@adobe.com
Date:     2008-12-10T22:45:46.490650Z

Log Message:
-----------
From now on we'll use the TLF team's release SWCs rather than their debug ones.

I've updated to today's Build 323.

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/libs/textLayout_core.swc</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/TextGraphic.as</path>
<path kind="file" action="M">/flex/sdk/trunk/development/eclipse/flex/flex4test/src/flex4test.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/libs/textLayout_conversion.swc</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/libs/textLayout_edit.swc</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/TextView.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1280308 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/RichText.as
+++ frameworks/projects/spark/src/spark/components/RichText.as
@@ -105,12 +105,6 @@
     private static var staticConfiguration:Configuration =
         new Configuration();

-    /**
-     *  @private
-     *  Used for determining whitespace processing during import.
-     */
-    private static var staticImportExportConfiguration:ImportExportConfiguration;
-
     //--------------------------------------------------------------------------
     //
     //  Constructor
@@ -122,17 +116,6 @@
      */
     public function TextGraphic()
     {
-        // Initialize staticImportExportConfiguration at instance-creation
-        // time rather than at static initialization time, to avoid
-        // any class-initialization-order problems.
-        if (!staticImportExportConfiguration)
-        {
-            staticImportExportConfiguration =
-                ImportExportConfiguration.defaultConfiguration;
-
-            ImportExportConfiguration.restoreDefaults();
-        }
-
         super();

         _content = textFlow = createEmptyTextFlow();
@@ -497,8 +480,6 @@
             getStyle("whiteSpaceCollapse");
 		staticConfiguration.textFlowInitialCharacterFormat =
             staticCharacterFormat;
-		staticImportExportConfiguration.textFlowConfiguration =
-            staticConfiguration;

         if (markup is String)
         {
@@ -536,7 +517,7 @@
         }

         return TextFilter.importToFlow(markup, TextFilter.TEXT_LAYOUT_FORMAT,
-                                       staticImportExportConfiguration);
+                                       staticConfiguration);
     }

     /**


Transferred from the Adobe Open Source Subversion Repository

Revision: 3711
Author:   mhorn@adobe.com
Date:     2008-10-17T17:55:26.712310Z

Log Message:
-----------
asdoc updates; fix examples; add new examples

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/LineExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/ArrowExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/BitmapGraphicExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/EllipseExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/RectExample.mxml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/TextBoxExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/TextBox.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/CircleExample.mxml</path>
<path kind="file" action="A">/flex/sdk/trunk/frameworks/projects/flex4/asdoc/en_US/mx/graphics/examples/TextGraphicExample.mxml</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/graphics/TextGraphic.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/TextView.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1280295 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/RichText.as
+++ frameworks/projects/spark/src/spark/components/RichText.as
@@ -64,10 +64,18 @@
  *  defined by parent elements, and clipped to any clipping content defined on its parent elements. TextGraphic content is only filled,
  *  not stroked.

  *
+ *
TextGraphic does not support drawing a background or border; it only renders text and inline graphics. If you want a simpler text class,
+ *  use the TextBox class. If you want a text control with more capabilities, use the TextView class.

+ *
  *
The TextGraphic element automatically clips the text rendering to the bounds of the text box.

  *
  *
If you do not specify the value of the width or height properties, or if the specified value
  *  of these properties is 0, the width and height are calculated based on the text content.

+ *
+ *  @see mx.components.TextView
+ *  @see mx.graphics.TextBox
+ *
+ *  @includeExample examples/TextGraphicExample.mxml
  */
 public class TextGraphic extends TextGraphicElement
 {


Transferred from the Adobe Open Source Subversion Repository

Revision: 8313
Author:   srahim@adobe.com
Date:     2009-06-26T17:36:11.687304Z

Log Message:
-----------
ASDoc updates

QE Notes: None
Doc Notes: None
Bugs: -
Checkintests: passed

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/TextArea.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Spinner.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/TextInput.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/components/Scroller.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1280882 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/TextArea.as
+++ frameworks/projects/spark/src/spark/components/TextArea.as
@@ -104,6 +104,26 @@
  *  for changing the formatting of text; text can be changed programmatically
  *  only.

  *
+ *  @mxml
+ *
+ *
The <TextArea> tag inherits all of the tag
+ *  attributes of its superclass and adds the following tag attributes:

+ *
+ *

+ *  <TextArea
+ *    Properties
+ *    heightInLines=""
+ *    textFlow="24"
+ *    widthInChars=""
+ *
+ *    Styles
+ *    horizontalScrollPolicy="No default"
+ *    symbolColor=""
+ *    verticalScrollPolicy="No default"
+ *  />
+ *

+ *
+ *  @see spark.skins.spark.TextAreaSkin
  *  @see spark.primitives.RichText
  *  @see spark.primitives.RichEditableText
  *  @see spark.primitives.SimpleText


Transferred from the Adobe Open Source Subversion Repository

Revision: 8483
Author:   smgilson@adobe.com
Date:     2009-07-09T17:52:48.367800Z

Log Message:
-----------
Second checkin to update the namespace in ASDoc MXML syntax descriptions for Spark components

QE Notes: None
Doc Notes: None
Bugs: -
Checkintests: passed

Modified Paths:
--------------
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/easing/EaseInOutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Fade.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/animation/MotionPath.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/ColorMatrixFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/easing/Power.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/BlurFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/DisplacementMapFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/ShaderFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/DropShadowFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/CallAction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/GradientBevelFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateColor.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Scale3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Animate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateTransitionShader.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Rotate3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AddAction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Scale.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/VerticalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/primitives/Graphic.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Move3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Rotate.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/BasicLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Resize.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateTransform3D.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Wipe.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/easing/Sine.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/Move.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/GlowFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/HorizontalLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/AnimateTransform.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/TileLayout.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/ConvolutionFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/easing/Linear.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/animation/Keyframe.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/layouts/supportClasses/LayoutBase.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/GradientGlowFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/SetAction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/effects/RemoveAction.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/BevelFilter.as</path>
<path kind="file" action="M">/flex/sdk/trunk/frameworks/projects/spark/src/spark/filters/GradientFilter.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1284098 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/effects/easing/Sine.as
+++ frameworks/projects/spark/src/spark/effects/easing/Sine.as
@@ -24,7 +24,7 @@
  *  and adds the following tag attributes:

  *
  *

- *  <mx:Sine
+ *  <s:Sine
  *    id="ID"
  *   />
  *


- Oh right, change WARNING to WARN (be more like our Java logging)
- Added an ERROR level, along with an error() method.

git-svn-id: a1a4b28b82a3276cc491891159dd9963a0a72fae@5395 542714f4-19e9-0310-aa3c-eee0fc999fb1

--- src/as/com/threerings/util/Log.as
+++ src/as/com/threerings/util/Log.as
@@ -56,7 +56,8 @@
     public static const DEBUG :int = 0;
     public static const INFO :int = 1;
     public static const WARNING :int = 2;
-    public static const OFF :int = 3;
+    public static const ERROR :int = 3;
+    public static const OFF :int = 4;
     // if you add to this, update LEVEL_NAMES and stringToLevel() at the bottom...

     /**
@@ -205,7 +206,26 @@
     }

     /**
+     * Log a message with 'error' priority.
+     *
+     * @param args The first argument is the actual message to log. After that, each pair
+     * of parameters is printed in key/value form, the benefit being that if no log
+     * message is generated then toString() will not be called on the values.
+     * A final parameter may be an Error, in which case the stack trace is printed.
+     *
+     * @example
+     * <listing version="3.0">
+     *    log.error("Message", "key1", value1, "key2", value2, optionalError);
+     * </listing>
+     */
+    public function error (... args) :void
+    {
+        doLog(ERROR, args);
+    }
+
+    /**
      * Log just a stack trace with 'warning' priority.
+     * Deprecated, sorta. Just use warning("Message", error);
      */
     public function logStackTrace (error :Error) :void
     {
@@ -300,6 +320,7 @@
         case "debug": return DEBUG;
         case "info": return INFO;
         case "warning": case "warn": return WARNING;
+        case "error": return ERROR;
         case "off": return OFF;
         }
     }
@@ -317,6 +338,6 @@
     protected static var _setLevels :Object = { "": DEBUG }; // global: debug

     /** The outputted names of each level. The last one isn't used, it corresponds with OFF. */
-    protected static const LEVEL_NAMES :Array = [ "debug", "INFO", "WARNING", false ];
+    protected static const LEVEL_NAMES :Array = [ "debug", "INFO", "WARN", "ERROR", false ];
 }
 }


Transferred from the Adobe Open Source Subversion Repository

Revision: 5101
Author:   gauravj@adobe.com
Date:     2009-02-27T05:22:45.887116Z

Log Message:
-----------
Update action script files with asdoc version tags.

QE Notes: None.
Doc Notes: Please review and update as necessary.
tests: checkintests

Modified Paths:
--------------
663 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1258642 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/framework/src/mx/collections/CursorBookmark.as
+++ frameworks/projects/framework/src/mx/collections/CursorBookmark.as
@@ -19,6 +19,11 @@
  *
  *  @see mx.collections.IViewCursor#bookmark
  *  @see mx.collections.IViewCursor#seek()
+ *
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
  */
 public class CursorBookmark
 {
@@ -32,6 +37,11 @@
      *  A bookmark for the first item in an ICollectionView.
      *
      *  @return The bookmark to the first item.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public static function get FIRST():CursorBookmark
     {
@@ -45,6 +55,11 @@
      * If the view has no items, the cursor is at this bookmark.
      *
      *  @return The bookmark to the last item.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public static function get LAST():CursorBookmark
     {
@@ -58,6 +73,11 @@
      *  an ICollectionView.
      *
      *  @return The bookmark to the current item.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public static function get CURRENT():CursorBookmark
     {
@@ -70,6 +90,11 @@
      *  Creates a new instance of a bookmark with the specified value.
      *
      *  @param value The value of this bookmark.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public function CursorBookmark(value:Object)
     {
@@ -93,6 +118,11 @@
      *  The underlying marker representation of the bookmark.
      *  This value is generally understood only by the IViewCursor
      *  or ICollectionView implementation.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public function get value():Object
     {
@@ -112,6 +142,11 @@
      *
      *  @return The index of the item. If the item is not in the current view, this method returns
      *  -1. This method also returns -1 if index-based location is not possible.
+     *
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
      */
     public function getViewIndex():int
     {


Transferred from the Adobe Open Source Subversion Repository

Revision: 16560
Author:   smgilson@adobe.com
Date:     2010-06-14T21:14:37.093170Z

Log Message:
-----------
Fix ASDoc version tags for several Flex 4 classes makred as Flex 3

QE notes:
Doc notes:
Bugs:
Reviewer:
Tests run: checkintests
Is noteworthy for integration:

Modified Paths:
--------------
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/NavigatorContent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/DataGroup.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/RadioButtonGroup.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/core/SpriteVisualElement.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/events/LoaderInvalidationEvent.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Group.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/skins/spark/ListDropIndicator.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/GroupBase.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/Application.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/SkinnableDataContainer.as</path>
<path kind="file" action="M">/private/flex/sdk/branches/hero_private/frameworks/projects/spark/src/spark/components/supportClasses/SkinnableComponent.as</path>

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1279721 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/spark/src/spark/components/NavigatorContent.as
+++ frameworks/projects/spark/src/spark/components/NavigatorContent.as
@@ -132,9 +132,9 @@
      *  @default null
      *
      *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
      */
     public function get icon():Class
     {
@@ -176,9 +176,9 @@
      *  @default ""
      *
      *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Flex 3
+     *  @playerversion Flash 10
+     *  @playerversion AIR 1.5
+     *  @productversion Flex 4
      */
     public function get label():String
     {


Issue #175: Avoid unnecessary transition when widget is preloaded with the minimize option.

--- src/com/esri/viewer/WidgetTemplate.as
+++ src/com/esri/viewer/WidgetTemplate.as
@@ -103,7 +103,7 @@

     private var _widgetId:Number;

-    private var _widgetState:String = WIDGET_OPENED;
+    private var _widgetState:String;

     private var _cursorID:int = 0;


Transferred from the Adobe Open Source Subversion Repository

Revision: 23243
Author:   cframpto@adobe.com
Date:     2011-12-20T00:59:57.384047Z

Log Message:
-----------
In frameworks, remove Adobe headers from all files except xml/mxml file types.  There are also a few .txt files that are license files that I didn't touch yet.

Modified Paths:
--------------
2361 paths were modified

git-svn-id: 7146a936b37d36e51ea0d66f8acbe0b8281bc7b7@1252128 13f79535-47bb-0310-9956-ffa450edef68

--- frameworks/projects/automation_spark/src/spark/automation/delegates/components/SparkLabelAutomationImpl.as
+++ frameworks/projects/automation_spark/src/spark/automation/delegates/components/SparkLabelAutomationImpl.as
@@ -1,13 +1,3 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  ADOBE SYSTEMS INCORPORATED
-//  Copyright 2009 Adobe Systems Incorporated
-//  All Rights Reserved.
-//
-//  NOTICE: Adobe permits you to use, modify, and distribute this file
-//  in accordance with the terms of the license agreement accompanying it.
-//
-////////////////////////////////////////////////////////////////////////////////

 package spark.automation.delegates.components
 {


added isApplicable method

added isApplicable method

--- collect-flex/collect-flex-client/src/generated/flex/org/openforis/collect/metamodel/proxy/ModelVersionProxy.as
+++ collect-flex/collect-flex-client/src/generated/flex/org/openforis/collect/metamodel/proxy/ModelVersionProxy.as
@@ -7,6 +7,10 @@

 package org.openforis.collect.metamodel.proxy {
 	import mx.collections.IList;
+	import mx.utils.StringUtil;
+
+	import org.openforis.collect.util.StringUtil;
+	import org.osmf.utils.Version;

     [Bindable]
     [RemoteClass(alias="org.openforis.collect.metamodel.proxy.ModelVersionProxy")]
@@ -38,6 +42,23 @@
 			return 0;
 		}

+		public function isApplicable(versionable:NodeDefinitionProxy):Boolean {
+			var since:ModelVersionProxy = versionable.sinceVersion;
+			var deprecated:ModelVersionProxy = versionable.deprecatedVersion;
+			if (since == null && deprecated == null) {
+				return true;
+			} else {
+				var sinceResult:int = 1;
+				var deprecatedResult:int = -1;
+				if (since != null) {
+					sinceResult = date.localeCompare(since.date);
+				}
+				if (deprecated != null) {
+					deprecatedResult = date.localeCompare(deprecated.date);
+				}
+				return sinceResult >= 0 && deprecatedResult < 0;
+			}
+		}

     }
 }


frag width/height : reduce log verbosity related to https://github.com/mangui/flashls/issues/59

--- src/org/mangui/hls/stream/FragmentLoader.as
+++ src/org/mangui/hls/stream/FragmentLoader.as
@@ -730,12 +730,14 @@

         /** triggered by demux, it should return video width/height */
         private function _fragParsingVideoMetadataHandler(width : uint, height : uint) : void {
-            CONFIG::LOGGING {
-                Log.debug("frag width/height retrieved from demux:" + width + "/" + height);
-            }
             var fragData : FragmentData = _frag_current.data;
-            fragData.video_width = width;
-            fragData.video_height = height;
+            if (fragData.video_width == 0) {
+                CONFIG::LOGGING {
+                    Log.debug("AVC: width/height:" + width + "/" + height);
+                }
+                fragData.video_width = width;
+                fragData.video_height = height;
+            }
         }

         /** triggered when demux has retrieved some tags from fragment **/
@@ -911,7 +913,7 @@
                 var tagsMetrics : HLSLoadMetrics = new HLSLoadMetrics(_level, fragMetrics.bandwidth, fragData.pts_max - fragData.pts_min, fragMetrics.processing_duration);

                 if (fragData.tags.length) {
-                    _tags_callback(_level, _frag_current.continuity, _frag_current.seqnum, !fragData.video_found, fragData.video_width, fragData.video_height,_frag_current.tag_list, fragData.tags, fragData.tag_pts_min, fragData.tag_pts_max, _hasDiscontinuity, start_offset + fragData.tag_pts_start_offset / 1000, _frag_current.program_date + fragData.tag_pts_start_offset);
+                    _tags_callback(_level, _frag_current.continuity, _frag_current.seqnum, !fragData.video_found, fragData.video_width, fragData.video_height, _frag_current.tag_list, fragData.tags, fragData.tag_pts_min, fragData.tag_pts_max, _hasDiscontinuity, start_offset + fragData.tag_pts_start_offset / 1000, _frag_current.program_date + fragData.tag_pts_start_offset);
                     _hls.dispatchEvent(new HLSEvent(HLSEvent.TAGS_LOADED, tagsMetrics));
                     fragData.tags_pts_min_audio = fragData.tags_pts_max_audio;
                     fragData.tags_pts_min_video = fragData.tags_pts_max_video;


prevent RangeError: Error #1125: The index 0 is out of range 0 when loading a playlist that does not contain any fragment fix #105

--- src/org/mangui/hls/model/Level.as
+++ src/org/mangui/hls/model/Level.as
@@ -178,23 +178,29 @@
             updateFragmentsProgramDate(_fragments);

             fragments = _fragments;
-            start_seqnum = _fragments[0].seqnum;
-            end_seqnum = _fragments[len - 1].seqnum;
-
-            if (idx_with_metrics != -1) {
-                frag = fragments[idx_with_metrics];
-                // if at least one fragment contains PTS info, recompute PTS information for all fragments
-                CONFIG::LOGGING {
-                    Log.debug("updateFragments: found PTS info from previous playlist,seqnum/PTS:" + frag.seqnum + "/" + frag.data.pts_start);
-                }
-                updateFragment(frag.seqnum, true, frag.data.pts_start, frag.data.pts_start + 1000 * frag.duration);
+
+            if (len > 0) {
+                start_seqnum = _fragments[0].seqnum;
+                end_seqnum = _fragments[len - 1].seqnum;
+
+                if (idx_with_metrics != -1) {
+                    frag = fragments[idx_with_metrics];
+                    // if at least one fragment contains PTS info, recompute PTS information for all fragments
+                    CONFIG::LOGGING {
+                        Log.debug("updateFragments: found PTS info from previous playlist,seqnum/PTS:" + frag.seqnum + "/" + frag.data.pts_start);
+                    }
+                    updateFragment(frag.seqnum, true, frag.data.pts_start, frag.data.pts_start + 1000 * frag.duration);
+                } else {
+                    CONFIG::LOGGING {
+                        Log.debug("updateFragments: unknown PTS info for this level");
+                    }
+                    duration = _fragments[len - 1].start_time + _fragments[len - 1].duration;
+                }
+                averageduration = duration / len;
             } else {
-                CONFIG::LOGGING {
-                    Log.debug("updateFragments: unknown PTS info for this level");
-                }
-                duration = _fragments[len - 1].start_time + _fragments[len - 1].duration;
-            }
-            averageduration = duration / len;
+                duration = 0;
+                averageduration = 0;
+            }
         }

         private function updateFragmentsProgramDate(_fragments : Vector.<Fragment>) : void {


Change 20090108-hqm-B by hqm@badtzmaru.home on 2009-01-08 22:48:00 EST
    in /Users/hqm/openlaszlo/trunk5
    for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: canvas resize bug

New Features:

Bugs Fixed: LPP-7499

Technical Reviewer: max
QA Reviewer: (pending)
Doc Reviewer: (pending)

Documentation:

Release Notes:

Details:

+ call         LzScreenKernel.handleResizeEvent() as last thing in initLFC

Tests:

debugger and canvas size to browser width for
test/hello.lzx?debug=true&lzr=swf9
test/hello.lzx?debug=true&lzr=swf10

git-svn-id: d62bde4b5aa582fdf07c8d403e53e0399a7ed285@12374 fa20e4f9-1d0a-0410-b5f3-dc9c16b8b17c


fixed key label function

fixed key label function

--- collect-flex/collect-flex-client/src/main/flex/org/openforis/collect/ui/component/datagrid/RecordSummaryDataGrid.as
+++ collect-flex/collect-flex-client/src/main/flex/org/openforis/collect/ui/component/datagrid/RecordSummaryDataGrid.as
@@ -72,9 +72,9 @@
 			var dataField:String = gridColumn.dataField;
 			if(dataField.indexOf(dataFieldPrefix) == 0) {
 				var key:String = dataField.substring(dataFieldPrefix.length);
-				var count:Number = map.get(key);
-				if(! isNaN(count)) {
-					return String(count);
+				var value:Object = map.get(key);
+				if((value is Number && !isNaN(Number(value))) || value != null) {
+					return String(value);
 				}
 			}
 			return "";


fixed TextureResource to use GPU compressed textures when working with ATF and BGRA textures otherwise

--- src/aerys/minko/render/resource/texture/TextureResource.as
+++ src/aerys/minko/render/resource/texture/TextureResource.as
@@ -15,8 +15,10 @@
 	 */
 	public final class TextureResource implements ITextureResource
 	{
-		private static const MAX_SIZE	: uint		= 2048;
-		private static const TMP_MATRIX	: Matrix	= new Matrix();
+		private static const MAX_SIZE			: uint		= 2048;
+		private static const TMP_MATRIX			: Matrix	= new Matrix();
+		private static const FORMAT_BGRA		: String	= Context3DTextureFormat.BGRA
+		private static const FORMAT_COMPRESSED	: String	= Context3DTextureFormat.COMPRESSED;

 		private var _texture	: Texture	= null;
 		private var _mipmap		: Boolean;
@@ -111,8 +113,8 @@
 				_texture = context.createTexture(
 					_width,
 					_height,
-					Context3DTextureFormat.BGRA,
-					_bitmapData == null
+					_atf ? FORMAT_COMPRESSED : FORMAT_BGRA,
+					_bitmapData == null && _atf == null
 				);

 				_update = true;