Add some grunt scaffolding to run perf tests

Add grunt tasks to do the following:

* Inline a JS file at the end of an HTML file.
* Run an arbitrary shell command on a device (part of the sdb
  task).

Add grunt config to enable performance testing:

* Add a task to inline a JS file which saves performance.timing
  to localStorage.
* Add a task to push a localStorage dump script to the device.
* Add a task to run the localStorage dump script.
* Add a task to reinstall the app, stop/start it 10 times, then
  dump localStorage to the console.
Split index.html into two pieces

Load majority of the HTML once the initial page is show
Load majority of the HTML once the initial page is shownn
Replace background pngs with jpgs
Include full requirejs in distribution

This will enable loading code dynamically, which will mean
we can keep requirejs but load code in segments.
Load JS after DOM is complete

Load only the bare minimum JS to enable the pages.html fragment
to be loaded; once that HTML is loaded and in the DOM,
load the majority of the JS files; once they're all done,
init the app.

This provides a substantial benefit, in that the initial display
of the HTML page is about 3 times faster.
Fix quit to main menu from within games (not via the menu drop-down)

I moved the show page code out of the individual games into
app.js. However, bowling and rockets games provide a way to
quit early out of the game, which means they need to be able
to show the home page themselves.
Switch to jqmobi from jquery