// We need to keep reference to controller as Objective-C will only keep weak reference here.
// We need to keep reference to controller as Objective-C will only keep weak reference here.
lateinitprivatevarcontroller:NSObject
lateinitprivatevarcontroller:NSObject
actualfunattachTo(container:Any){
funinitLayer(viewController:SkikoViewController){
attachTo(containerasUIView)
this.view=viewController.view
}
funattachTo(view:UIView){
this.view=view
// See https://developer.apple.com/documentation/uikit/touches_presses_and_gestures/using_responders_and_the_responder_chain_to_handle_events?language=objc
// See https://developer.apple.com/documentation/uikit/touches_presses_and_gestures/using_responders_and_the_responder_chain_to_handle_events?language=objc