You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by to...@apache.org on 2013/10/08 22:37:07 UTC

git commit: [flex-sdk] [refs/heads/develop] - Fix #FLEX-33654 - allow ctrl/command key presses to be recieved and acted uppon in datagrid cells

Updated Branches:
  refs/heads/develop 7639423c7 -> 10ff6e41b


Fix #FLEX-33654 - allow ctrl/command key presses to be recieved and acted uppon in datagrid cells


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

Branch: refs/heads/develop
Commit: 10ff6e41b8fbd58ad68d49771df0887f7458ad16
Parents: 7639423
Author: Tom Chiverton <to...@apache.org>
Authored: Tue Oct 8 21:13:02 2013 +0100
Committer: Tom Chiverton <to...@apache.org>
Committed: Tue Oct 8 21:13:02 2013 +0100

----------------------------------------------------------------------
 .../src/spark/components/gridClasses/DataGridEditor.as   | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/10ff6e41/frameworks/projects/spark/src/spark/components/gridClasses/DataGridEditor.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/spark/src/spark/components/gridClasses/DataGridEditor.as b/frameworks/projects/spark/src/spark/components/gridClasses/DataGridEditor.as
index c727988..2971962 100644
--- a/frameworks/projects/spark/src/spark/components/gridClasses/DataGridEditor.as
+++ b/frameworks/projects/spark/src/spark/components/gridClasses/DataGridEditor.as
@@ -1695,7 +1695,14 @@ public class DataGridEditor
         // Prevent the DataGrid from processing any keystrokes that were 
         // received by the editor. We don't cancel the keystokes here 
         // because on AIR that cancels text input into the text field.
-        event.stopPropagation();
+    	// We need to let the copy/cut/past combinations pass through
+    	// because they need to reach the NativeApplication in order to
+    	// be correctly processed by the item editors.
+        // Note on Mac OS ctrlKey covers ctrl and command keys
+    	if (!event.ctrlKey) 
+    	{
+    		event.stopPropagation();
+    	}
     }
     
     /**
@@ -1785,4 +1792,4 @@ public class DataGridEditor
     }
    
 }
-}
\ No newline at end of file
+}