mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-05-06 02:12:57 +08:00
escordova
This commit is contained in:
parent
26ed8ed648
commit
d12fc3a0cd
3
src/cordova.js
vendored
3
src/cordova.js
vendored
@ -12,10 +12,11 @@ const promisifyCordova = (pluginObj, pluginName, methodName) => {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!pluginOjb.installed()) {
|
if(!pluginObj.installed()) {
|
||||||
console.warn('Cordova: tried calling', '"' + pluginName + '.' + methodName + '"', 'but the ' + pluginObj.plugin + ' plugin is not installed.');
|
console.warn('Cordova: tried calling', '"' + pluginName + '.' + methodName + '"', 'but the ' + pluginObj.plugin + ' plugin is not installed.');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
console.log('Cordova: exec(' + pluginName + ', ' + methodName +')');
|
||||||
cordova.exec(resolve, reject, pluginName, methodName, args);
|
cordova.exec(resolve, reject, pluginName, methodName, args);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -12,6 +12,7 @@ document.addEventListener('deviceready', function() {
|
|||||||
alert('No cam');
|
alert('No cam');
|
||||||
console.log('Camera not installed');
|
console.log('Camera not installed');
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
Native.Camera.takePicture().then(function(resp) {
|
Native.Camera.takePicture().then(function(resp) {
|
||||||
console.log('Got picture');
|
console.log('Got picture');
|
||||||
}, function(err) {
|
}, function(err) {
|
||||||
@ -23,10 +24,13 @@ document.addEventListener('deviceready', function() {
|
|||||||
} else {
|
} else {
|
||||||
console.log('AppLinks not installed');
|
console.log('AppLinks not installed');
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
if(Native.StatusBar.installed()) {
|
if(Native.StatusBar.installed()) {
|
||||||
console.log('StatusBar installed');
|
console.log('StatusBar installed');
|
||||||
Native.StatusBar.styleBlackTranslucent();
|
Native.StatusBar.hide().catch(function(err) {
|
||||||
|
console.error('unable to set statusbar', err);
|
||||||
|
});
|
||||||
} else {
|
} else {
|
||||||
alert('No statusbar');
|
alert('No statusbar');
|
||||||
console.log('StatusBar not installed');
|
console.log('StatusBar not installed');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user