Remove inline styling with iconPath in diva.js

The grid, document and link icons are now set solely in the stylesheet,
removing the need for `settings.iconPath`.
Change context of executeCallback to diva instance

Now defined as a private function in diva.js instead of utils.js, and
can accept an unlimited number of arguments.

Some of the occurrences of $.executeCallback have not been changed to
executeCallback in this commit because of other intermediate changes,
but they'll show up soon.
Modify AJAX request behaviour of diva.js

The document viewer now makes only one AJAX request to the divaserve
script. All the relevant data are sent and/or calculated during this
initial load, and some new functions and settings have been created
to deal with this change.

This commit includes several other related (or not related) changes:

* Some whitespace error fixes
* Check if a tile is horizontally within the viewport (in addition to
  being vertically within the viewport) before displaying it
* More public functions
* The timer in loadPage has been modified to load the page container
  before attempting to load the tiles, resulting in the shadow and
  loading indicator always appearing (which is the expected behaviour)
* Added some functions to validate zoomLevel and pagesPerRow

Tests and changes in other files forthcoming.
Modify fullscreen icon placement and size
Switch grid and document icon toggle order

They were accidentally reversed in the CSS
Update divaserve.php for single-request policy

The python module still needs to be updated
Add destroy function to canvas plugin

Needed for unit testing.
Added back missing comma

Important
Rebuild
Set settings.currentPageIndex in gotoPage

Wasn't actually being set anywhere in the function. These functions may
need to be reorganised at some point.
Remove console.log
Fix maxZoomLevel bug

If the maxZoomLevel is set to something other than the actual document
max zoom level, then the images will not display properly. Now, the
actual document max zoom level is used, so everything should work.
Update slider label in handleZoom

The zoom-related functions should probably be reorganised as well.
Merge branch 'single-request' into develop
Preserve inGrid and inFullscreen values

They should be configurable by the user and should control the initial
view/mode.
Add change event handlers to sliders

So that value-change events set programmatically can be caught.
Add "Loading" message when zooming in canvas

Issue #98
Change link popup box size/placement
Bypass cross-domain issues with canvas

Adds a PHP script that acts as a proxy for the images.

For demonstration purposes only.
Add tests and reorganise diva.js

This is a sizable but incomplete commit that incorporates the following
changes:

* Moved the zoom slider in canvas view to below the apply below (and
  enlarged the apply button slightly)
* Switched order of attemptPageShow and attemptPageHide in adjustRows
  and adjustPages. This prevents the loading of stray pages that
  shouldn't be loaded when scrolling quickly through the document.
* Improved method of centering pages in document view (now purely using
  a CSS class - the width no longer needs to be specified)
* Added an allTilesLoaded setting so that it's not necessary to loop
  through all the tiles for a page when they've already been loaded (in
  loadPage)
* New system for handling basic navigation (zooming, switching between
  views, switching between modes, etc). More consistent and less buggy
  and easier to work with overall.
* Double-clicking a page while in document view now preserves the
  position of the clicked region in the viewport. That is, if you click
  on a particular feature on a page, you can expect to see that feature
  in the same position under your cursor after zooming in. When zooming
  out, the viewer will try to keep the region in the same position but
  this is not always possible due to the smaller size of the images at
  the lower zoom level. Note that one must double-click on a page, as
  opposed to the viewer as a whole.
* Temporarily commented out some public functions
* Revamped unit testing system. One module per file. Diva instances are
  created then destroyed afterwards.

Things that have to be done:

* More unit tests for:
    * Navigation
    * Hash parameters (especially combinations of them)
    * Callbacks
* More public functions

Sorry about the magnitude of this commit, but it was hard to break it
up in a consistent way and I have to go.