Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Play Button iTunes Patch not working on MacBook Pro Touch Bar w/ Mojave #46

Open
kenmhaggerty opened this issue Oct 7, 2018 · 22 comments

Comments

@kenmhaggerty
Copy link

I will have to double-check if the patch is working on my 2012 MacBook Pro running Mojave, but on my 2018 MacBook Pro running Mojave, the Touch Bar's play button still launches iTunes even after going through the regular setup process w/o error. (Disable SIP → Run patch → Re-enable SIP)

Please let me know what info I can provide to help debug.

@petersg83
Copy link

Same here :)

@thebitguru
Copy link
Owner

Sorry, things seem to have changed recently and I haven't had time to find a workaround. I did notice that Apple has lately released an API to properly handle the keys without launching iTunes, thus mostly eliminating the need for this patch. Is the app that you are using not handling media keys properly? If so, can you share which app this is?

@kenmhaggerty
Copy link
Author

I checked on my iMac with a Bluetooth keyboard and can confirm that the play button doesn't launch iTunes, but my MacBook Pro's touch bar will launch iTunes via the play button even from Finder.

@thebitguru
Copy link
Owner

Which media player are you using that doesn't respond to the key in the first place?

@kenmhaggerty
Copy link
Author

I'm a little confused? My understanding is that this patch simply stops iTunes from launching when the play button is pressed and iTunes is not open. I am not using a media player when this happens.

@thebitguru
Copy link
Owner

Oh, I see the confusion. In previous macOS versions, Apple would launch iTunes when you used the media keys even if you had a different media player (e.g. Nightingale) running. That was my intented use case for creating this patch.

In your case it sounds like you don't want iTunes to start in any scenario...?

@kenmhaggerty
Copy link
Author

Yes! Sometimes I accidentally tap the play button, and it shouldn't do anything if there's no media player launched. I think that should be the default macOS behavior... but in the absence of that I've been relying on this patch to do that!

@thebitguru
Copy link
Owner

Ah, OK. I was thinking of archiving this project now that macOS supports originally intended use case out of the box, but I will take another look hopefully soon and report back here.

@petersg83
Copy link

Hi, I found the patch for the same reason as kenmhaggerty's.
I have to add that I use Spotify and if I haven't done anything with Spotify for a while (while it is open somewhere in my spaces) and I press play to play the music on spotify, many times it launches iTunes. Even though Spotify is open! I don't know if the patch you created fixes this behavior but I'm interested if it does.
Also, I would love to never launch iTunes with the play button, and if it's possible, to even choose what to launch with it (Spotify for example). If you know something that does that, I would be really interested too.
In any case, thanks for your work :)

@thebitguru
Copy link
Owner

I am debating creating a simple replacement menu bar app that can monitor the media keys and either ignore them (so iTunes doesn't launch) or letting another app handle it. This would also eliminate the need for patching an OS released file like this project does. But, it would add another app that would have to run all the time. Would such an app be of interest?

@petersg83
Copy link

petersg83 commented Nov 24, 2018

For my use it would be perfect, just an icon in the top bar wouldn't bother me :)

@thebitguru
Copy link
Owner

OK, I will do some research and see if that can be a replacement app. No commitments though :)

@petersg83
Copy link

Awesome thanks :)

@benlk
Copy link

benlk commented Nov 28, 2018

I did notice that Apple has lately released an API to properly handle the keys without launching iTunes,

Are there any links for this new API? I've searched Apple's documentation, but couldn't find anything more recent than Snow Leopard. https://developer.apple.com/library/archive/technotes/tn2450/_index.html

@thebitguru
Copy link
Owner

MPRemoteCommandCenter is what I had in mind.

@thebitguru
Copy link
Owner

FYI, BeardedSpice is an option for ignoring media keys. I created a simple "strategy" script for it that can accomplish this. Given BeardedSpice's original use case, the interface isn't ideal (shows the title of the first tab), but it's a proof of concept. This is the strategy gist.

@pleasejust
Copy link

Yes, please, if you have time, create something, anything that'll prevent iTunes from launching when you press the play button, even when there's no other media player open. Of course when iTunes or other media players are open the keys should work. I'm holding off upgrading to Mojave because of this. Thanks a lot.

@kaiserkiwi
Copy link

I have the exact same issue as petersg83 and hoped to find any solution here. Are there any news on this?

@pickanothername
Copy link

I also have the same issue as those above me.

@m1guelpf
Copy link

m1guelpf commented Apr 7, 2019

Any update on this?

@yougotwill
Copy link

Not a perfect solution but recently discovered https://github.com/tombonez/noTunes.

@AlecRust
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants