You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ma...@apache.org on 2013/11/19 09:38:15 UTC

[1/2] git commit: [flex-sdk] [refs/heads/develop] - FIX FLEX-33166 Mobile TextInput with native StageTextInput cannot be included in scrollable forms - fixed failing mustella test: mobile/SoftKeyboard/properties/SK_StageText_Properties SoftKeyboard_Stag

Updated Branches:
  refs/heads/develop bbf2c5332 -> df7e9a6d4


FIX  FLEX-33166 Mobile TextInput with native StageTextInput cannot be included in scrollable forms
- fixed failing mustella test: mobile/SoftKeyboard/properties/SK_StageText_Properties SoftKeyboard_StageText_property_resizeForSoftKeyboard_false
   -> added check for ScrollableStageText in addtion to StyleableStageText  in Mustella FakeSoftKeyboard
- fixed issue when finger is pressed on TI, then scrolled, then released on the same TI (thanks Om)


Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/40f2927e
Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/40f2927e
Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/40f2927e

Branch: refs/heads/develop
Commit: 40f2927e869cbed9a5e9ed999683374aeb72d336
Parents: 9d6c2d3
Author: mamsellem <ma...@systar.com>
Authored: Tue Nov 19 02:33:58 2013 +0100
Committer: mamsellem <ma...@systar.com>
Committed: Tue Nov 19 02:33:58 2013 +0100

----------------------------------------------------------------------
 .../supportClasses/ScrollableStageText.as       | 21 ++++++++++++--------
 mustella/as3/src/mustella/FakeSoftKeyboard.as   |  3 ++-
 2 files changed, 15 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/40f2927e/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ScrollableStageText.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ScrollableStageText.as b/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ScrollableStageText.as
index 28ed07a..518f6a7 100644
--- a/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ScrollableStageText.as
+++ b/frameworks/projects/mobilecomponents/src/spark/components/supportClasses/ScrollableStageText.as
@@ -1376,9 +1376,6 @@ public class ScrollableStageText extends UIComponent  implements IStyleableEdita
         if (stageText != null)
         {
             stageText.assignFocus();      // will trigger stageTextfocusIn
-            //TODO what happens when setting focus to a component in a popup that is not visible yet
-            //   else
-            //   pendingFocusedStageText = stageText;
         }
     }
 
@@ -1402,10 +1399,7 @@ public class ScrollableStageText extends UIComponent  implements IStyleableEdita
 
             // Move the cursor to the end of the appended text.
             stageText.selectRange(_text.length, _text.length);
-
             dispatchEvent(new TextOperationEvent(TextOperationEvent.CHANGE));
-
-
             invalidateProxy();
         }
     }
@@ -1785,6 +1779,7 @@ public class ScrollableStageText extends UIComponent  implements IStyleableEdita
         // always create proxy image
 
         // register listeners
+        addEventListener(MouseEvent.CLICK, mouseClickHandler);
         addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
         addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
         if (stageText != null)
@@ -1813,8 +1808,9 @@ public class ScrollableStageText extends UIComponent  implements IStyleableEdita
 
 
         stageText.stage = null;
-
-        removeEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
+       removeEventListener(MouseEvent.CLICK, mouseClickHandler);
+       removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
+       removeEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
 
         stageText.removeEventListener(Event.CHANGE, stageText_changeHandler);
         stageText.removeEventListener(Event.COMPLETE, stageText_completeHandler);
@@ -1847,6 +1843,10 @@ public class ScrollableStageText extends UIComponent  implements IStyleableEdita
     private function mouseUpHandler(event:MouseEvent):void
     {
         isMouseDown = false;
+    }
+
+    private function mouseClickHandler(event:MouseEvent):void
+    {
         setFocus();
     }
 
@@ -1876,6 +1876,11 @@ public class ScrollableStageText extends UIComponent  implements IStyleableEdita
     private function stageText_focusInHandler(event:FocusEvent):void
     {
         startTextEdit();
+        // Focus events are documented as bubbling. However, all events coming
+        // from StageText are set to not bubble. So we need to create an
+        // appropriate bubbling event here.
+        dispatchEvent(new FocusEvent(event.type, true, event.cancelable,
+                event.relatedObject, event.shiftKey, event.keyCode, event.direction));
     }
 
     private function stageText_focusOutHandler(event:FocusEvent):void

http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/40f2927e/mustella/as3/src/mustella/FakeSoftKeyboard.as
----------------------------------------------------------------------
diff --git a/mustella/as3/src/mustella/FakeSoftKeyboard.as b/mustella/as3/src/mustella/FakeSoftKeyboard.as
index a5cf9cf..6f7629e 100644
--- a/mustella/as3/src/mustella/FakeSoftKeyboard.as
+++ b/mustella/as3/src/mustella/FakeSoftKeyboard.as
@@ -68,7 +68,8 @@ public class FakeSoftKeyboard
 		var comp:Object = event.target;
 		if (comp is TextField || comp is InteractiveObject)
 		{
-			if (!(comp.needsSoftKeyboard || getQualifiedClassName(comp).indexOf("StyleableStageText") > 0))
+            var className: String = getQualifiedClassName(comp);
+			if (!(comp.needsSoftKeyboard || className.indexOf("StyleableStageText") > 0 || className.indexOf("ScrollableStageText") > 0 ))
 				return;
 			
 			if (!comp.dispatchEvent(new SoftKeyboardEvent(SoftKeyboardEvent.SOFT_KEYBOARD_ACTIVATING, 


[2/2] git commit: [flex-sdk] [refs/heads/develop] - Merge branch 'develop' of https://git-wip-us.apache.org/repos/asf/flex-sdk into develop

Posted by ma...@apache.org.
Merge branch 'develop' of https://git-wip-us.apache.org/repos/asf/flex-sdk into develop


Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/df7e9a6d
Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/df7e9a6d
Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/df7e9a6d

Branch: refs/heads/develop
Commit: df7e9a6d425aab6ca4d4df0f051c1cff17046e6a
Parents: 40f2927 bbf2c53
Author: mamsellem <ma...@systar.com>
Authored: Tue Nov 19 09:37:12 2013 +0100
Committer: mamsellem <ma...@systar.com>
Committed: Tue Nov 19 09:37:12 2013 +0100

----------------------------------------------------------------------
 mustella/jenkins.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------