mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
fixed notifications in OS X 10.8
This commit is contained in:
parent
42d297f192
commit
56d110efc2
1 changed files with 7 additions and 3 deletions
|
@ -289,12 +289,16 @@ void PsMacWindowPrivate::showNotify(uint64 peer, int32 msgId, const QPixmap &pix
|
||||||
[notification setTitle:QNSString(title).s()];
|
[notification setTitle:QNSString(title).s()];
|
||||||
[notification setSubtitle:QNSString(subtitle).s()];
|
[notification setSubtitle:QNSString(subtitle).s()];
|
||||||
[notification setInformativeText:QNSString(msg).s()];
|
[notification setInformativeText:QNSString(msg).s()];
|
||||||
[notification setContentImage:img];
|
if ([notification respondsToSelector:@selector(setContentImage:)]) {
|
||||||
|
[notification setContentImage:img];
|
||||||
|
}
|
||||||
|
|
||||||
if (withReply) [notification setHasReplyButton:YES];
|
if (withReply && [notification respondsToSelector:@selector(setHasReplyButton:)]) {
|
||||||
|
[notification setHasReplyButton:YES];
|
||||||
|
}
|
||||||
|
|
||||||
[notification setSoundName:nil];
|
[notification setSoundName:nil];
|
||||||
|
|
||||||
NSUserNotificationCenter *center = [NSUserNotificationCenter defaultUserNotificationCenter];
|
NSUserNotificationCenter *center = [NSUserNotificationCenter defaultUserNotificationCenter];
|
||||||
[center deliverNotification:notification];
|
[center deliverNotification:notification];
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue