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

UI Panel Refactor #207

Merged
merged 2 commits into from
Oct 24, 2024
Merged

Conversation

SpectralVectors
Copy link

Updated UI Panel code to a more 'Blender'-codestyle.

Previously each panel was drawn by calling a series of functions - many of these functions referenced the same scene properties and could be replaced by a series of scene variables collected by the parent CAMButtonsPanel.

Now all panels (with one exception - Operation Properties) have only one function: draw, and it references the scene and draws or hides various UI elements based on the context.scene.interface.level directly, rather than calling a helper function to look it up.

This will simplify any future changes to the UI, align with Blender's UI recommendations, and should allow for a quick and easy revamp of the Pie Menu.

@SpectralVectors
Copy link
Author

Found an issue with the pull - the headers for hidden panels are still showing, not a showstopping bug, but an annoying one that I'd like to fix.
I'll update the pull once I have a solution for it.

@SpectralVectors
Copy link
Author

OK, that should do it.

The only visible changes should be removal of: the Update button from the Info panel, the Warning text from the Bas Relief panel.

Otherwise all changes are 'under the hood' and should not affect UI or functionality.

@pppalain pppalain merged commit 953d9c2 into pppalain:master Oct 24, 2024
0 of 2 checks passed
@SpectralVectors SpectralVectors deleted the ui-panel-refactor branch October 24, 2024 16:52
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