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

Save zoom and focused window from layout so that it can be restored #143

Merged
merged 3 commits into from
Aug 10, 2024

Conversation

Andrew-Collins
Copy link
Contributor

Hi,

This PR is to support restoring layouts with with zoom and focus.
Related issues:

A new struct WindowLayoutStorage has been created to store: the windows layout, which window is in focus, and if the focused window is zoomed.

TabLayoutDescription has been updated to hold this struct in place of WindowLayoutStorage as well as store the currently selected tab.

I am not set on the name WindowLayoutStorage; would you be open to naming it TabLayoutDescription, and rename TablayoutDescription to AppLayoutDescription or something similar?

This seems more logical to me as currently TabLayoutDescription does not hold the layout of a tab, but rather the layout of the top level application.

Keen to hear your thoughts. :)

@ulyssa ulyssa changed the title Update layout save/restore to support zoom & focus Save zoom and focused window from layout so that it can be restored Aug 10, 2024
@ulyssa
Copy link
Owner

ulyssa commented Aug 10, 2024

Thank you for doing this, this is a really great addition! 🥳 I'll make sure to pull it into iamb so those issues can be resolved.

I am not set on the name WindowLayoutStorage; would you be open to naming it TabLayoutDescription, and rename TablayoutDescription to AppLayoutDescription or something similar?

This seems more logical to me as currently TabLayoutDescription does not hold the layout of a tab, but rather the layout of the top level application.

I think you're right that having it be a singular Tab is not quite right, but I like having Tab in the name for the thing that actually knows about tabs, so I've renamed it to TabbedLayoutDescription. I also renamed WindowLayoutStorage to WindowLayoutRoot so that it mirrors the tree structure in its naming.

@ulyssa ulyssa enabled auto-merge (squash) August 10, 2024 03:25
@ulyssa ulyssa merged commit b71afe6 into ulyssa:main Aug 10, 2024
3 checks passed
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.

2 participants