Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 320673

Summary: QuickAccess should restore previous focus when hitting Escape
Product: [Eclipse Project] Platform Reporter: Stefan Mücke <s.muecke>
Component: UIAssignee: Dean Roberts <dean.t.roberts>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: bokowski, dean.t.roberts, emoffatt, markus.kell.r, pwebster
Version: 4.2Flags: pwebster: review-
Target Milestone: 4.2 M5   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on: 362421, 365753    
Bug Blocks: 364029    
Attachments:
Description Flags
Patch to restore previous focus after Esc key none

Description Stefan Mücke CLA 2010-07-22 17:21:16 EDT
QuickAccess can be invoked with Ctrl+3. Thus it should be possible to return from QuickAccess by keyboard. In 3.6 you get a dialog which you can dismiss with the Escape key.
Comment 1 Boris Bokowski CLA 2010-07-22 17:43:07 EDT
I agree. ESC should put focus back to where it was.
Comment 2 Remy Suen CLA 2010-09-22 16:17:05 EDT
*** Bug 326006 has been marked as a duplicate of this bug. ***
Comment 3 Markus Keller CLA 2011-11-11 12:08:08 EST
Still in I20111110-2200.
Comment 4 Dean Roberts CLA 2011-11-11 14:17:14 EST
Created attachment 206868 [details]
Patch to restore previous focus after Esc key

This patch is built on top of 362421 plus 365382.

Functionality does not matter ... but if you don't apply the patches on those 2 defects 1st, this patch will have line number problems.
Comment 5 Paul Webster CLA 2011-11-18 09:32:38 EST
my usecase:

1) Hit CTRL+3
2) get the key assist dialog and pick Quick Access (I have a conflict)
3) start typing and get the dropdown
4) hit ESC.

Now my Search field has focus, for about 2 seconds, and then I get the key assist dialog for ESC (so the ESC key was not being consumed by whatever made the dialog go  away).

PW
Comment 6 Dean Roberts CLA 2011-11-30 13:59:53 EST
Hmm.

I don't see this at all running with the latest from HEAD and this patch on Ubuntu 11.10
Comment 7 Paul Webster CLA 2011-12-02 09:31:02 EST
It works for me if the package explorer has focus.  If the editor has focus, then I get the multi-key popup for ESC.

If I use key down to start picking a selection and then hit ESC, I don't get out of the dropdown at all.
PW
Comment 9 Dean Roberts CLA 2011-12-06 10:59:14 EST
This fix works if the user only types characters and then hits escape, focus will go back to the last thing that had focus.

However, if the user uses arrow keys to scroll up and down the drop down list and then hits escape focus ends up with the search field text area, and not the previous control.
Comment 10 Dean Roberts CLA 2011-12-06 11:01:33 EST
I believe this is related to bug 365753
Comment 11 Dean Roberts CLA 2011-12-09 10:34:06 EST
Confirmed that this was "fixed", and then broken by bug 365753.

Since this is not really a duplicate of 365753 I'll set up a dependency relationship and then retest this defect when 365753 is released.
Comment 12 Eric Moffatt CLA 2011-12-09 13:09:46 EST
Aggregate move to M5. Retarget to a different milestone if you wish...
Comment 13 Dean Roberts CLA 2012-02-13 15:18:42 EST
Retested after releasing 365753 and all is well.  Focus returns to last view after ESC is pressed in QuickAccess after using the arrow keys to move around.