NSUserNotification customisable app icon?
Asked Answered
S

1

9

I just noticed that iTunes' notification icon was replaced by album covers:

iTunes Notification

And it's app icon was a small one near the title, which is a bit different from the ones I knew of:

Normal Notification

Where I can only add images as part of the content, not the app icon.

Is there an undocumented NSUserNotification API that I didn't know?

Suckle answered 24/7, 2014 at 2:4 Comment(0)
S
16

NVM, I found the answer.

iTunes use private APIs.

NSUserNotification *notification = [NSUserNotification new];
[notification setValue:anImage forKey:@"_identityImage"];
Suckle answered 24/7, 2014 at 18:2 Comment(5)
is it possible to get approved by the store with this?Earthiness
PRIVATE APIs are not allowed in MAS except Apple's in house apps.Suckle
I've submitted a radar asking Apple to make this public openradar.me/radar?id=6424021574877184Foretopsail
Just out of curiosity, how exactly did you find out about this private API?Gerlach
@Palleas class-dump on a Foundation framework binary.Catchword

© 2022 - 2024 — McMap. All rights reserved.