[
https://issues.apache.org/jira/browse/FLEX-33487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13630594#comment-13630594
]
Mark Kessler edited comment on FLEX-33487 at 4/12/13 10:31 PM:
---------------------------------------------------------------
I reviewed the DataGridEditor.as and found the code that affects you directly
[1]. It looks to be done intentionally. The new method
"editorActivationMouseEvent" can have it's value changed to support a
"doubleClick" [2], however is available from the GIT flex-dev source or when a
new SDK is release. There is also a "editOnDoubleClick" mx_internal variable
inside the DataGrid.as that will allow doubleclick editing as well when set to
true. This variable looks like it was brought over from the SDK 4.6, so it
already exists in your current version.
[1]
// If double click is not enabled or we want a double click
to open an
// editor, then open the editor directly now. Otherwise
start a timer
// and wait to see if a double click comes in that will
cancel the edit.
if (dataGrid.editOnDoubleClick ||
InteractiveObject(lastItemDown).doubleClickEnabled ==
false)
{
// we don't need to wait on the time since editing
double click is ok.
dataGrid.startItemEditorSession(rowIndex, columnIndex);
}
else
{
doubleClickTimer = new Timer(dataGrid.doubleClickTime,
1);
doubleClickTimer.addEventListener(TimerEvent.TIMER,
doubleClickTimerHandler);
doubleClickTimer.start();
}
[2] enumeration="doubleClick,none,singleClick,singleClickOnSelectedCell",
defaultValue="singleClickOnSelectedCell".
<s:DataGrid editable="true" doubleClickEnabled="true"
editorActivationMouseEvent="doubleClick">
</s:DataGrid>
[3] mx_internal var editOnDoubleClick:Boolean = false;
was (Author: paeros):
Here is a temp work around that you can use now, while I sort out a proper
fix. Althought current method editorActivationMouseEvent is only available to
the current GIT development branch. Didn't notice it's flex 5 tag.
<s:DataGrid dataProvider="{acTestData}" editable="true"
doubleClickEnabled="true" editorActivationMouseEvent="doubleClick">
</s:DataGrid>
> Double-click does not trigger DataGrid item editor session if
> doubleClickEnabled is true
> ----------------------------------------------------------------------------------------
>
> Key: FLEX-33487
> URL: https://issues.apache.org/jira/browse/FLEX-33487
> Project: Apache Flex
> Issue Type: Bug
> Components: Spark: DataGrid
> Affects Versions: Apache Flex 4.9.0
> Reporter: JC Franco
> Assignee: Mark Kessler
> Priority: Minor
> Labels: DataGrid, Editable, Spark
>
> Editable DataGrid does not behave as expected if doubleClickEnabled is set to
> true. Double-clicking on an item does not immediately start the editor
> session.
> Workaround:
> Use triple-click to trigger item editor session.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira