googleads / googleads-ima-tvos-client-side

5 stars 8 forks source link

pressesBegan(_:with:) is not forwarded when paused using the Siri remote. #17

Open JulianRex-John opened 2 years ago

JulianRex-John commented 2 years ago

We are trying to perform certain action on pressesBegan(_:with:) of our view controller. There is an inconsistency in this method call reaching to our view controller.

Device: Apple TV 4k tvOS version: 15 & 16

WHEN the video is playing(not on AD) THEN we press the Play/Pause button on the Siri remote RESULT the video pauses but pressesBegan(_:with:) is not called on the view controller. ❌

WHEN the video is paused(not on AD) THEN we press the Play/Pause button again RESULT the video resumes and the pressesBegan(_:with:) is called on the view controller. ✅

EXPECTED RESULT pressesBegan(_:with:) should be called on every button press.

To reproduce this issue add the following extension in the ViewController.swift in your sample app.

extension ViewController {
    override func pressesBegan(_ presses: Set<UIPress>, with event: UIPressesEvent?) {
        print("Debug pressesBegan")
    }
}

Please let me know if you need further information on this. Thank you.