Skip to content

Conversation

@typesupply
Copy link
Member

This needs a thorough review. Ultimately the solution was to set the view frames relative to the tab view's contentRect. The contentRect is only available after the view moves to a window, so I wait until then to adjust the frames.

The switch to view controllers for some objects (NSTabViewController, NSSplitViewController, etc.) removes the responsibility for creating the view from vanilla to the controller. We need to be able to do our setup on the view all the same, so this makes it possible.
This is for #172, but I'm not sure if it solves the Ventura problem yet.
@typesupply
Copy link
Member Author

This PR is for #172.

* viewDidMoveToWindow is also called when a view is removed from superview, so window() is None and no wrapper needs to call positionViews
* VanillaTabsDelegate is gone, all delegate actions goes to the controller, which is already set. Every tabView has already a delegate
* Removing some unnecessary imports and attributes
* Adding doc strings
@typemytype
Copy link
Member

looks good! thanks

@typesupply typesupply merged commit 049493e into master Nov 30, 2022
@typesupply typesupply deleted the tabs branch November 30, 2022 13:21
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.

3 participants