Bug 545728 - [launch config] filtered features are not saved
Summary: [launch config] filtered features are not saved
Status: VERIFIED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.10   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.12 M1   Edit
Assignee: Julian Honnen CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-03-25 04:30 EDT by Julian Honnen CLA
Modified: 2019-05-21 04:12 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 Julian Honnen CLA 2019-03-25 04:30:10 EDT
1) create eclipse application launch configuration based on selected features
   (all features are selected by default)
2) enter some filter (e.g. "emf")
3) apply, close and reopen the launch config

--> only emf features are selected
Comment 1 Julian Honnen CLA 2019-03-25 05:10:55 EDT
The issue is caused because CheckboxTreeViewer#getChecked and #getCheckedElements omit filtered elements. The expectation when using CachedCheckboxTreeViewer is generally that filtering should only affect the UI, not the checked set.

Also affected are e.g the import feature and export plugin wizard: both skip selected but filtered elements. Import "Projects from Folder or Archive" for example does not.

@Andrey, WDYT is the correct behavior regarding the wizards? I would tend to override both methods in CachedCheckboxTreeViewer so they ignore filters.
Comment 2 Andrey Loskutov CLA 2019-03-25 05:42:10 EDT
(In reply to Julian Honnen from comment #1)
> The issue is caused because CheckboxTreeViewer#getChecked and
> #getCheckedElements omit filtered elements. The expectation when using
> CachedCheckboxTreeViewer is generally that filtering should only affect the
> UI, not the checked set.

This bug is related to bug 441684, but it is not about wizards. I also see that the "Restore" button with active filter set only restores the state for the filtered elements, same for "Select All/Deselect All/Select Required". I guess it would make sense to clear the filter first before performing actions, so that user immediately sees that they operate on the *all* elements, not just on filtered.

> Also affected are e.g the import feature and export plugin wizard: both skip
> selected but filtered elements. Import "Projects from Folder or Archive" for
> example does not.
> 
> @Andrey, WDYT is the correct behavior regarding the wizards? I would tend to
> override both methods in CachedCheckboxTreeViewer so they ignore filters.

Can we fix this one and create a separated bug for discussion about wizards behavior?
Comment 3 Julian Honnen CLA 2019-03-25 07:33:48 EDT
(In reply to Andrey Loskutov from comment #2)
> This bug is related to bug 441684, but it is not about wizards.

It is a bit, insofar that those wizards use the same filtered tree viewer - which should behave similarly across PDE.

> I also see
> that the "Restore" button with active filter set only restores the state for
> the filtered elements, same for "Select All/Deselect All/Select Required". I
> guess it would make sense to clear the filter first before performing
> actions, so that user immediately sees that they operate on the *all*
> elements, not just on filtered.

That is definitely inconsistent compared to a plugin based launch config. Please comment on bug 545735.


> Can we fix this one and create a separated bug for discussion about wizards
> behavior?

Sure. --> Bug 545736
Comment 4 Eclipse Genie CLA 2019-03-26 04:15:45 EDT
New Gerrit change created: https://git.eclipse.org/r/139469
Comment 6 Vikas Chandra CLA 2019-04-08 07:44:24 EDT
Can bug reporter or bug assignee please verify this defect for 4.12M1?
Comment 7 Julian Honnen CLA 2019-05-21 04:12:15 EDT
verified on I20190520-1805