Allow NoticeWindow to be used without requiring super class.
This makes it hard (impossible?) to work with other libraries that also require a super class (e.g. SwiftTweaks).
Suggested solution
Put all logic in a separate class that can be encapsulated in a custom UIWindow subclass.
E.g. instead of:
class MyCustomWindow : NoticeWindow {
}
Have something like:
class MyCustomWindow : ThirdPartyWindow {
lazy var noticeWindowManager = NoticeWindowManger(window: self)
}
Allow NoticeWindow to be used without requiring super class.
This makes it hard (impossible?) to work with other libraries that also require a super class (e.g. SwiftTweaks).
Suggested solution
Put all logic in a separate class that can be encapsulated in a custom UIWindow subclass.
E.g. instead of:
Have something like: