How to detect when MPNowPlayingInfoCenter on the TouchBar on Mac is accessed?

IvanIcinIvanIcin USMember ✭✭✭

As the bug that I have submitted about wrong implementation of MPNowPlayingInfoCenter on Xamarin is now fixed, I am starting out to look further on how to implement this. I have the working code on iOS for MPNowPlayingInfoCenter and the same code should work on Mac, but I am not sure how to interact with it.

On iOS there is RemoteControlReceived in UIViewController, but on Mac I don't find anything even in Apple docs. Anyone knows this?

Posts

  • TimothyRisiXMTimothyRisiXM USXamarin Team Xamurai
    edited September 2017

    From what I can tell looking at apple's MPRemoteCommandSample, you would use MPRemoteCommandCenter to register for events.

  • IvanIcinIvanIcin USMember ✭✭✭

    I believe that you are right, just you wrote 'MPRemoteCommandSample' instead of 'MPRemoteCommandCenter'. Thanks.

  • TimothyRisiXMTimothyRisiXM USXamarin Team Xamurai

    @IvanIcin said:
    I believe that you are right, just you wrote 'MPRemoteCommandSample' instead of 'MPRemoteCommandCenter'. Thanks.

    Whoops, you're right. Edited to fix it.

Sign In or Register to comment.