Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initialize onboarding information for all stacks in shared area #1773 #1778

Merged

Conversation

HeikoKlare
Copy link
Contributor

The onboarding information is currently initialized for the primary editor stack in the shared area. When the shared area is split into multiple part stack showing editors side-by-side and closing the last editor in the original part stack, the onboarding information controls get lost together with that part stack.

With this change, onboarding information is embedded into every part stack of the onboarding area, such that when closing one of them, the information does not get lost. To this end, every part stack is in the shared area is tagged as an editor stack and the onboarding information is added to every tab folder of part stacks tagged as an editor stack.

Fixes #1773

Discussion of alternatives

The change relies on tagging multiple part stacks as "EditorStack". An alternative solution would be to not check for the "EditorStack" tag but to check for a part stack being placed in the shared area. Necessary adaptations to productive code would be of similar complexity, but test adaptation effort would increase as the tests currently encode the contract of identifying part stacks requiring onboarding information by the "EditorStack" tag rather than being placed in the shared area.

How to test / reproduce

You can experience the change with the following scenario (also documented in #1774):

  1. Start an Eclipse product, e.g., an SDK
    image
  2. Open two editors in the shared area. Then split the shared area placing the the two editors side by side via drag and drop.
    image
  3. Close the left editor first, then close the remaining (the originally right) editor. With the existing implementation, you will see that the onboarding information is lost.
    image
    With this change, the onboarding information is still present.
    image

Copy link
Contributor

github-actions bot commented Mar 25, 2024

Test Results

   921 files     921 suites   45m 59s ⏱️
 7 512 tests  7 361 ✅ 151 💤 0 ❌
23 688 runs  23 181 ✅ 507 💤 0 ❌

Results for commit ab0fc98.

♻️ This comment has been updated with latest results.

@HeikoKlare HeikoKlare marked this pull request as ready for review March 26, 2024 15:04
@HeikoKlare
Copy link
Contributor Author

@marcushoepfner since you have contributed the onboarding functionality, may I ask you to have a look at this fix?

@marcushoepfner
Copy link
Contributor

LGTM. Thanks @HeikoKlare
I don't have a runnable IDE currently. Could you kindly check, whether two windows still works. Eclipse -> Menu -> Window -> New Window.
There was a bug. Refer to #1180 (comment)

Thanks

@HeikoKlare
Copy link
Contributor Author

Thanks for your feedback and the hint to the issue!
I have executed the problematic scenario described in #1180 (comment) and played around with two workbench windows and did not find any issues (in particular not the one documented back then).

@HeikoKlare
Copy link
Contributor Author

Thanks @marcushoepfner!

I'd like to postpose the merge of this PR after #1775 since that one becomes hard to reproduce manually once this PR has been merged.

…se-platform#1773

The onboarding information is currently initialized for the primary
editor stack in the shared area. When the shared area is split into
multiple part stack showing editors side-by-side and closing the last
editor in the original part stack, the onboarding information controls
get lost together with that part stack.

With this change, onboarding information is embedded into every part
stack of the onboarding area, such that when closing one of them, the
information does not get lost. To this end, every part stack is in the
shared area is tagged as an editor stack and the onboarding information
is added to every tab folder of part stacks tagged as an editor stack.

Fixes eclipse-platform#1773
@HeikoKlare HeikoKlare merged commit abbb25f into eclipse-platform:master Apr 3, 2024
16 checks passed
@HeikoKlare HeikoKlare deleted the issue-1773-onboarding branch April 3, 2024 20:01
HeikoKlare added a commit to HeikoKlare/eclipse.platform.ui that referenced this pull request Apr 10, 2024
The functionality for creating and identifying editor stacks based on
the "EditorStack" tag is scattered across several code places. This
change centralizes the according functionality in the recently
introduced PartStackUtils, which currently contain functionality related
to the primary data stack, which also relies on the being an editor
stack.

In addition, this change reverts the preliminary fix for visible names
of open editors being to short (eclipse-platform#1712) as this became obsolete with the
recent improvements of handling primary data stacks and editor stacks
(eclipse-platform#1775, eclipse-platform#1778).

Contributes to
eclipse-platform#1570
Contributes to
eclipse-platform#1773
HeikoKlare added a commit to HeikoKlare/eclipse.platform.ui that referenced this pull request Apr 10, 2024
The functionality for creating and identifying editor stacks based on
the "EditorStack" tag is scattered across several code places. This
change centralizes the according functionality in the recently
introduced PartStackUtil, which currently contain functionality related
to the primary data stack, which also relies on the being an editor
stack.

In addition, this change reverts the preliminary fix for visible names
of open editors being to short (eclipse-platform#1712) as this became obsolete with the
recent improvements of handling primary data stacks and editor stacks
(eclipse-platform#1775, eclipse-platform#1778).

Contributes to
eclipse-platform#1570
Contributes to
eclipse-platform#1773
HeikoKlare added a commit to HeikoKlare/eclipse.platform.ui that referenced this pull request Apr 10, 2024
The functionality for creating and identifying editor stacks based on
the "EditorStack" tag is scattered across several code places. This
change centralizes the according functionality in the recently
introduced PartStackUtil. This utility class currently contains
functionality related
to the primary data stack, which also relies on being an editor
stack.

In addition, this change reverts the preliminary fix for visible names
of open editors being to short (eclipse-platform#1712) as this became obsolete with the
recent improvements of handling primary data stacks and editor stacks
(eclipse-platform#1775, eclipse-platform#1778).

Contributes to
eclipse-platform#1570
Contributes to
eclipse-platform#1773
HeikoKlare added a commit to HeikoKlare/eclipse.platform.ui that referenced this pull request Apr 16, 2024
The functionality for creating and identifying editor stacks based on
the "EditorStack" tag is scattered across several code places. This
change centralizes the according functionality in the recently
introduced PartStackUtil. This utility class currently contains
functionality related
to the primary data stack, which also relies on being an editor
stack.

In addition, this change reverts the preliminary fix for visible names
of open editors being to short (eclipse-platform#1712) as this became obsolete with the
recent improvements of handling primary data stacks and editor stacks
(eclipse-platform#1775, eclipse-platform#1778).

Contributes to
eclipse-platform#1570
Contributes to
eclipse-platform#1773
HeikoKlare added a commit to HeikoKlare/eclipse.platform.ui that referenced this pull request Apr 18, 2024
The functionality for creating and identifying editor stacks based on
the "EditorStack" tag is scattered across several code places. This
change centralizes the according functionality in the recently
introduced PartStackUtil. This utility class currently contains
functionality related
to the primary data stack, which also relies on being an editor
stack.

In addition, this change reverts the preliminary fix for visible names
of open editors being to short (eclipse-platform#1712) as this became obsolete with the
recent improvements of handling primary data stacks and editor stacks
(eclipse-platform#1775, eclipse-platform#1778).

Contributes to
eclipse-platform#1570
Contributes to
eclipse-platform#1773
HeikoKlare added a commit that referenced this pull request Apr 18, 2024
The functionality for creating and identifying editor stacks based on
the "EditorStack" tag is scattered across several code places. This
change centralizes the according functionality in the recently
introduced PartStackUtil. This utility class currently contains
functionality related
to the primary data stack, which also relies on being an editor
stack.

In addition, this change reverts the preliminary fix for visible names
of open editors being to short (#1712) as this became obsolete with the
recent improvements of handling primary data stacks and editor stacks
(#1775, #1778).

Contributes to
#1570
Contributes to
#1773
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Onboarding information (and primary data stack) lost when splitting editor area
2 participants