Update check
This commit is contained in:
parent
ef8ddaf380
commit
483f681400
@ -93,6 +93,9 @@ $(document).ready(function() {
|
|||||||
request.onsuccess = function() {
|
request.onsuccess = function() {
|
||||||
var app = this.result[0];
|
var app = this.result[0];
|
||||||
var latest = $.ajax({url:'manifest-web.webapp'});
|
var latest = $.ajax({url:'manifest-web.webapp'});
|
||||||
|
var selfApp = navigator.mozApps.getSelf();
|
||||||
|
selfApp.onsuccess = function() {
|
||||||
|
if(this.result) {
|
||||||
latest.onload = function() {
|
latest.onload = function() {
|
||||||
if( this.response ) {
|
if( this.response ) {
|
||||||
var lapp = JSON.parse(this.response);
|
var lapp = JSON.parse(this.response);
|
||||||
@ -111,6 +114,8 @@ $(document).ready(function() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
if( !app && confirm('Do you want to Install this app?') ) {
|
if( !app && confirm('Do you want to Install this app?') ) {
|
||||||
var ins = navigator.mozApps.install('http://mdibaiee.github.io/Sketchy/Web/manifest-web.webapp');
|
var ins = navigator.mozApps.install('http://mdibaiee.github.io/Sketchy/Web/manifest-web.webapp');
|
||||||
ins.onsuccess = function() {
|
ins.onsuccess = function() {
|
||||||
|
Loading…
Reference in New Issue
Block a user