check if using cordova at init.js

This commit is contained in:
Gustavo Maximiliano Cortez 2014-11-25 15:09:36 -03:00
parent d1979f443a
commit ee8f78d961
2 changed files with 15 additions and 3 deletions

View File

@ -28,7 +28,7 @@
margin-top: 40px;
margin-left: 0;
margin-bottom: -40px;
padding: 20px 0 110px 0;
padding: 20px 0 90px 0;
}
.tab-bar {

View File

@ -1,6 +1,18 @@
'use strict';
angular.element(document).ready(function() {
// Init the app
angular.bootstrap(document, ['copayApp']);
var startAngular = function () {
angular.bootstrap(document, ['copayApp']);
};
if (window.cordova !== undefined) {
document.addEventListener('deviceready', function() {
setTimeout(function(){ navigator.splashscreen.hide(); }, 2000);
startAngular();
});
} else {
startAngular();
}
});