Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 321045 - [CellEditors] CellEditorActionHandler is deactivated after clicking on Coolbar
Summary: [CellEditors] CellEditorActionHandler is deactivated after clicking on Coolbar
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.0   Edit
Hardware: PC Windows Vista
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform UI Triaged CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-27 12:14 EDT by Vladimír Hájek CLA
Modified: 2020-04-19 16:30 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimír Hájek CLA 2010-07-27 12:14:14 EDT
Build Identifier: 20100617-1415

CellEditorActionHandler is listening SWT.Activate and SWT.Deactivate events. Event SWT.Activate sets activeEditor. Event SWT.Deactivate resets activeEditor to null. Clicking anywhere on Coolbar (main toolbar) causes SWT.Deactivate event => all actions defined in CellEditorActionHandler are disabled.

Suggestion:
Instead of events SWT.Activate and SWT.Deactivate use events focusGained and focusLost of FocusListener. It works perfectly - at least for my case of direct editing Label in BIRT report designer.

Reproducible: Always

Steps to Reproduce:
1. Open BIRT Report Designer and create new report.
2. Insert Label report item and write some text into it.
3. Doubleclick on written text to select it all.
4. Open menu Edit - actions cut and copy are enabled.
5. Click anywhere on Coolbar.
6. Open menu Edit - actions cut and copy are disabled.

There is much worse scenario when actions cut and copy are inserted to Coolbar.
1-4. Same as above.
5. Click on button Cut in Coolbar which is enabled.
6. Button Cut in Coolbar changes to disabled. Cut is not executed.
Comment 1 CLA 2011-11-02 08:59:27 EDT
I just got bitten by this one in Eclipse 3.7.1. Might there be a workaround or fix?
Comment 2 CLA 2011-12-11 07:43:39 EST
As suggested in Comment #1, I copied the class CellEditorActionHandler and substituted SWT.FocusIn and SWT.FocusOut for SWT.Activate and SWT.Deactivate events. It works perfectly. Perhaps this could be a fix?
Comment 3 Eclipse Genie CLA 2020-04-19 16:30:10 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.