swift-win32
swift-win32 copied to clipboard
Make ViewController open
This PR makes the ViewController
class open
, so that it can be overriden.
This is work in progress. Before submitting for review, I would like to audit the whole ViewController
class and write some more unit tests for it.
@tomaszpieczykolan would you mind rebasing the change? I think that the new features that I've enabled will be nice to take advantage of.
Codecov Report
Merging #544 (6b9c15d) into main (fda786e) will increase coverage by
1.19%
. The diff coverage isn/a
.
@@ Coverage Diff @@
## main #544 +/- ##
==========================================
+ Coverage 13.79% 14.98% +1.19%
==========================================
Files 111 111
Lines 4443 4443
==========================================
+ Hits 613 666 +53
+ Misses 3830 3777 -53
Impacted Files | Coverage Δ | |
---|---|---|
...s/SwiftWin32/View Controllers/ViewController.swift | 46.75% <ø> (+46.75%) |
:arrow_up: |
...n32/Views and Controls/DirectionalEdgeInsets.swift | 43.75% <0.00%> (+12.50%) |
:arrow_up: |
...in32/App and Environment/ApplicationDelegate.swift | 17.54% <0.00%> (+17.54%) |
:arrow_up: |
...ces/SwiftWin32/Views and Controls/EdgeInsets.swift | 33.33% <0.00%> (+33.33%) |
:arrow_up: |
The ability to subclass ViewController
& override buildMenu(with: MenuBuilder)
is really helpful for menus, it would be great to merge this PR if there is no concern left.
I that that when the class is being marked open
, we need to ensure that the members are properly marked as open
as well, which is not the case yet. Furthermore, @tomaszpieczykolan has this marked as a draft still. I definitely am waiting on this change as I have some changes sitting around that require this to be open.