Created
October 15, 2013 20:13
-
-
Save jbest84/6997905 to your computer and use it in GitHub Desktop.
Phonegap index file for argos-bootcamp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<!--[if IE 9 ]> <html lang="en" class="ie9"> <![endif]--> | |
<!--[if (gt IE 9)|!(IE)]><!--> | |
<html lang="en" class="gtie9 modern"> | |
<!--<![endif]--> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no" /> | |
<meta name="apple-mobile-web-app-capable" content="yes" /> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black" /> | |
<meta name="format-detection" content="telephone=no,email=no,address=no" /> | |
<title>Saleslogix</title> | |
<link rel="apple-touch-icon" href="content/images/touch-icon-iphone.png" /> | |
<link rel="apple-touch-icon" sizes="72x72" href="content/images/72x72.png" /> | |
<link rel="apple-touch-icon" sizes="76x76" href="content/images/touch-icon-ipad.png" /> | |
<link rel="apple-touch-icon" sizes="114x114" href="content/images/114x114.png" /> | |
<link rel="apple-touch-icon" sizes="120x120" href="content/images/touch-icon-iphone-retina.png" /> | |
<link rel="apple-touch-icon" sizes="144x144" href="content/images/144x144.png" /> | |
<link rel="apple-touch-icon" sizes="152x152" href="content/images/touch-icon-ipad-retina.png" /> | |
<link rel="apple-touch-startup-image" href="content/images/loading.png"> | |
<link type="text/css" rel="stylesheet" href="content/css/themes/swiftpage/sdk.min.swiftpage.css" /> | |
<link type="text/css" rel="stylesheet" href="content/css/app.min.css" /> | |
<!-- PhoneGap --> | |
<script type="text/javascript" src="phonegap.js"></script> | |
<!-- Dojo --> | |
<script type="text/javascript" src="content/dojo/dojo/dojo.js" data-dojo-config="parseOnLoad:false, async:true, blankGif:'content/images/blank.gif'"></script> | |
<script type="text/javascript"> | |
require({ | |
baseUrl: "./", | |
packages: [ | |
{ name: 'dojo', location: 'content/dojo/dojo' }, | |
{ name: 'dijit', location: 'content/dojo/dijit' }, | |
{ name: 'dojox', location: 'content/dojo/dojox' }, | |
{ name: 'configuration', location: 'configuration' }, | |
{ name: 'localization', location: 'localization' } | |
], | |
paths: { | |
'Mobile/SalesLogix/DefaultMetrics.txt': 'content/javascript/DefaultMetrics.txt' | |
} | |
}); | |
</script> | |
<script type="text/javascript" src="content/dojo/dojo-dependencies.js"></script> | |
<!-- Core --> | |
<script type="text/javascript"> | |
reConfig = { | |
autoInit: false, | |
legacyMode: false, | |
showInitialPage: false, | |
updateBackButtonText: false | |
}; | |
</script> | |
<script type="text/javascript" src="content/javascript/argos-dependencies.js"></script> | |
<script type="text/javascript" src="content/javascript/argos-sdk.js"></script> | |
<!-- Application --> | |
<script type="text/javascript" src="content/javascript/argos-saleslogix.js"></script> | |
<!-- Modules --> | |
<!-- Bootcamp --> | |
<link type="text/css" rel="stylesheet" href="content/css/themes/bootcamp/bootcamp.min.css" /> | |
<script type="text/javascript" src="content/javascript/argos-bootcamp.js"></script> | |
<!--{{modules}}--> | |
</head> | |
<body> | |
<script type="text/javascript"> | |
var phoneGap = { | |
// Application Constructor | |
initialize: function() { | |
this.bindEvents(); | |
}, | |
// Bind Event Listeners | |
// | |
// Bind any events that are required on startup. Common events are: | |
// 'load', 'deviceready', 'offline', and 'online'. | |
bindEvents: function() { | |
document.addEventListener('deviceready', this.onDeviceReady, false); | |
}, | |
// deviceready Event Handler | |
// | |
// The scope of 'this' is the event. In order to call the 'receivedEvent' | |
// function, we must explicity call 'app.receivedEvent(...);' | |
onDeviceReady: function() { | |
phoneGap.receivedEvent('deviceready'); | |
}, | |
// Update DOM on a Received Event | |
receivedEvent: function(id) { | |
var application = 'Mobile/SalesLogix/Application', | |
configuration = [ | |
'configuration/development', | |
'configuration/bootcamp/development' | |
]; | |
require(['moment', application].concat(configuration), function(moment, application, configuration) { | |
var localization = [ | |
'localization/en', | |
'localization/saleslogix/en' | |
]; | |
require(localization.concat('dojo/domReady!'), function() { | |
moment.lang('en'); | |
var instance = new application(configuration); | |
instance.activate(); | |
instance.init(); | |
instance.run(); | |
}); | |
}); | |
} | |
}; | |
phoneGap.initialize(); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment