Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-23834

mx.controls.DateField with editable=true and DataGrid itemEditor

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • Adobe Flex SDK 3.3 (Release)
    • Apache Flex 4.10.0
    • mx: DateField
    • None
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Steps to reproduce:
      <mx:Array id="data">
      <mx:Object date="

      {new Date()}

      " />
      </mx:Array>
      <mx:DataGrid dataProvider="

      {data}

      " editable="true">
      <mx:columns>
      <mx:DataGridColumn headerText="correct" dataField="date" editorDataField="selectedDate" itemEditor="mx.controls.DateField" />
      <mx:DataGridColumn headerText="incorrect" dataField="date" editorDataField="selectedDate" >
      <mx:itemEditor>
      <mx:Component>
      <mx:DateField editable="true" />
      </mx:Component>
      </mx:itemEditor>
      </mx:DataGridColumn>
      </mx:columns>
      </mx:DataGrid>

      Actual Results:
      When you start editing "correct" column(in example above) and press Escape, editing is cancelled. But when you start editing "incorrect" column and press Escape nothing happens and editing continues.

      Expected Results:
      Editing should be cancelled in both cases.

      Workaround (if any):
      mx.controls.DateField class overrides keyDownHandler and checks for Escape key. But the problem is it calls event.stopPropagation() which prevents DataGrid to get Escape key down event inorder to cancel editing mode. Workaround is to comment that one line or extend DateField class, override keyDownHandler and not call super.keyDownHandler. In this case you loose key navigation in DateField but get editing cancellation in case of DataGrid item editor.

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: