Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 318634 - [ui] Dragging things from the Snippet or Palette view does not bring focus to the editor
Summary: [ui] Dragging things from the Snippet or Palette view does not bring focus to...
Status: RESOLVED FIXED
Alias: None
Product: WTP Source Editing
Classification: WebTools
Component: wst.sse (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.2.1   Edit
Assignee: Sarika Sinha CLA
QA Contact: Nitin Dahyabhai CLA
URL:
Whiteboard: PMC_approved
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-01 12:15 EDT by Sarika Sinha CLA
Modified: 2010-07-08 15:34 EDT (History)
2 users (show)

See Also:
nsand.dev: pmc_approved? (david_williams)
nsand.dev: pmc_approved? (raghunathan.srinivasan)
nsand.dev: pmc_approved? (naci.dai)
nsand.dev: pmc_approved? (deboer)
neil.hauge: pmc_approved+
nsand.dev: pmc_approved? (kaloyan)
nsand.dev: review+
thatnitind: review+


Attachments
Setting focus after drop (940 bytes, patch)
2010-07-01 13:11 EDT, Sarika Sinha CLA
nsand.dev: iplog+
Details | Diff
patch (1.74 KB, patch)
2010-07-02 11:55 EDT, Nick Sandonato CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sarika Sinha CLA 2010-07-01 12:15:50 EDT
Build Identifier: I20100602-1502

If we drag something from Snippet or Palette view to Source editor, focus does not change to source editor.

Reproducible: Always

Steps to Reproduce:
1.Drag a widget from palette to source editor.
2.Focus remains at Palette view, Focus should have changed to Editor.
Comment 1 Sarika Sinha CLA 2010-07-01 13:11:31 EDT
Created attachment 173241 [details]
Setting focus after drop

This patch sets the focus to the target editor after drop action.
Comment 2 Nick Sandonato CLA 2010-07-01 13:43:05 EDT
Thanks, Sarika. This patch looks good to me.

I think this can alleviate some user frustration when it comes to adding DND content to our editors.

Nitin, would you mind taking a look at this for 3.2.1?
Comment 3 Nitin Dahyabhai CLA 2010-07-02 11:13:50 EDT
How well does this work both in editors that are just the StructuredTextEditor and cases where it's a Source page?  Since it activates the editor, what about cases where the file's out of sync with the workspace?
Comment 4 Nick Sandonato CLA 2010-07-02 11:55:59 EDT
Created attachment 173315 [details]
patch

Checks for parent editor parts for cases like the XML editor.
Comment 5 Nitin Dahyabhai CLA 2010-07-02 14:04:28 EDT
Approved.  Please write-up the PMC review details.
Comment 6 Nick Sandonato CLA 2010-07-02 14:15:46 EDT
* Explain why you believe this is a stop-ship defect. Or, if it is a "hotbug" (requested by an adopter) please document it as such.

Needed for an adopter as a usability issue. Context is never switched back over to the editor when something is dragged onto it, which can prevent immediate typing without the user manually focusing the editor again.

* Is there a work-around? If so, why do you believe the work-around is insufficient?

No.

* How has the fix been tested? Is there a test case attached to the bugzilla record? Has a JUnit Test been added?

The existing unit tests have been run along with ad hoc testing of drag and drop features on various SSE-based editors.

Give a brief technical overview. Who has reviewed this fix?

Once an item has been dropped onto the editor, the drop target adapter for Structured Source Editors will now activate the editor part that the item was dropped on. This will allow the user to immediately begin typing into the source of the editor again. It's a small update to our implementation of the drop target adapter.

Nitin and I have both reviewed the patch.

* What is the risk associated with this fix?

Very low.
Comment 7 Nick Sandonato CLA 2010-07-06 10:13:18 EDT
Released to Maintenance and HEAD.