You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by Alex Harui <ah...@adobe.com> on 2013/04/22 08:21:07 UTC

Re: git commit: [flex-sdk] - Fixes FLEX-33370. Refactors MAX_DRAG_RATE to be a protected variable so that it is extenable by other components.

Hi Nick,

Welcome back.  I think protected vars don't go in the list in the class
header.  Also, git seems to show different indentation than the rest of the
file.

-Alex


On 4/21/13 2:23 PM, "quetwo@apache.org" <qu...@apache.org> wrote:

> Updated Branches:
>   refs/heads/develop 024a49261 -> e6c5be9c2
> 
> 
> Fixes FLEX-33370.  Refactors MAX_DRAG_RATE to be a protected variable so that
> it is extenable by other components.
> 
> 
> Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo
> Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/e6c5be9c
> Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/e6c5be9c
> Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/e6c5be9c
> 
> Branch: refs/heads/develop
> Commit: e6c5be9c2aeaf01171554db5b36ca35b4035a201
> Parents: 024a492
> Author: quetwo <ni...@theflexgroup.org>
> Authored: Sun Apr 21 17:23:16 2013 -0400
> Committer: quetwo <ni...@theflexgroup.org>
> Committed: Sun Apr 21 17:23:16 2013 -0400
> 
> ----------------------------------------------------------------------
>  .../spark/components/supportClasses/SliderBase.as  |   21 +++++++++-----
>  1 files changed, 13 insertions(+), 8 deletions(-)
> ----------------------------------------------------------------------
> 
> 
> http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/e6c5be9c/frameworks/proje
> cts/spark/src/spark/components/supportClasses/SliderBase.as
> ----------------------------------------------------------------------
> diff --git 
> a/frameworks/projects/spark/src/spark/components/supportClasses/SliderBase.as
> b/frameworks/projects/spark/src/spark/components/supportClasses/SliderBase.as
> index 90df795..7c69827 100644
> --- 
> a/frameworks/projects/spark/src/spark/components/supportClasses/SliderBase.as
> +++ 
> b/frameworks/projects/spark/src/spark/components/supportClasses/SliderBase.as
> @@ -125,6 +125,7 @@ include
> "../../styles/metadata/BasicInheritingTextStyles.as"
>   *    dataTipPrecision="2"
>   *    maximum="10"
>   *    showDataTip="true"
> + *    maxDragRate=30
>   * 
>   *    <strong>Styles</strong>
>   *    alignmentBaseline="USE_DOMINANT_BASELINE"
> @@ -232,6 +233,17 @@ public class SliderBase extends TrackBase implements
> IFocusManagerComponent
>      //
>      
> //--------------------------------------------------------------------------
>  
> + /**
> +  *  Maximum number of times per second we will change the slider position
> +  *  and update the display while dragging.
> +  *
> +  *  @langversion 3.0
> +  *  @playerversion Flash 10
> +  *  @playerversion AIR 1.5
> +  *  @productversion Flex 4
> +  */
> + protected var maxDragRate:Number = 30;
> +
>      /**
>       *  @private
>       */
> @@ -288,13 +300,6 @@ public class SliderBase extends TrackBase implements
> IFocusManagerComponent
>       */
>      private var dragPending:Boolean = false;
>  
> -    /**
> -     *  @private
> -     *  Maximum number of times per second we will change the slider position
> -     *  and update the display while dragging.
> -     */
> -    private static const MAX_DRAG_RATE:Number = 30;
> -    
>      
> //--------------------------------------------------------------------------
>      //
>      //  Overridden properties
> @@ -732,7 +737,7 @@ public class SliderBase extends TrackBase implements
> IFocusManagerComponent
>          mostRecentMousePoint = track.globalToLocal(new Point(event.stageX,
> event.stageY));
>          if (!dragTimer)
>          {
> -            dragTimer = new Timer(1000/MAX_DRAG_RATE, 0);
> +            dragTimer = new Timer(1000/maxDragRate, 0);
>              dragTimer.addEventListener(TimerEvent.TIMER, dragTimerHandler);
>          }
>          
> 

-- 
Alex Harui
Flex SDK Team
Adobe Systems, Inc.
http://blogs.adobe.com/aharui