发布v2.6.8版本
This commit is contained in:
@@ -22,6 +22,7 @@ function notifyClass(opts){
|
||||
this.sounderr= '';
|
||||
this.soundbo = true;
|
||||
this.showbool= false;
|
||||
this.macos = false;
|
||||
this._init=function(){
|
||||
if(opts)for(var o1 in opts)this[o1]=opts[o1];
|
||||
var strsr = '';
|
||||
@@ -32,6 +33,8 @@ function notifyClass(opts){
|
||||
strsr = '<audio id="notify_sound_audio" src="web/res/sound/wu.mp3" autoplay="autoplay" hidden="true"></audio>';
|
||||
}
|
||||
if(this.sound)$('body').append(strsr);
|
||||
var llq = navigator.userAgent.toLowerCase();
|
||||
if(llq.indexOf('reimclient')>0)this.macos = true;
|
||||
};
|
||||
this.setsound = function(bo){
|
||||
this.soundbo=bo;
|
||||
@@ -90,6 +93,13 @@ function notifyClass(opts){
|
||||
me.notification=false;
|
||||
});
|
||||
});
|
||||
}else if(this.macos){
|
||||
rockclient.rockFun("Notification",{
|
||||
title:can.title,
|
||||
msg:can.body
|
||||
}, function(ret){
|
||||
|
||||
});
|
||||
}else{
|
||||
var notification= new Notification(title, can);
|
||||
notification.onclick = function(){
|
||||
|
||||
Reference in New Issue
Block a user