AME-3939 - fix for NPE in unit test

git-svn-id: https://svn.forgerock.org/openam/trunk/openam@10019 0f4defcf-c51a-4c67-9f44-6fb5eba73c5d
OPENAM-4275, CR-4196: Introduce autoSubmitDelay (int) variable and submit() function for client scripts to delay auto-submission while waiting for asynchronous client-side calls to complete. When handling asynchronous calls, autoSubmitDelay should be set to a reasonably high number and submit() should be called by the client script once all asynchronous calls have completed.
Also, updated DeviceMatch client-side.js to make use of this new feature. The call to geolocation.getCurrentPosition now needs to have an error callback to ensure submit() is called promptly after any failure occurs - except for the case identified by https://bugzilla.mozilla.org/show_bug.cgi?id=675533

git-svn-id: https://svn.forgerock.org/openam/trunk/openam@10020 0f4defcf-c51a-4c67-9f44-6fb5eba73c5d
OPENAM-4293. DeviceId Save bug fix. Visually reviewed by Jaco.

git-svn-id: https://svn.forgerock.org/openam/trunk/openam@10021 0f4defcf-c51a-4c67-9f44-6fb5eba73c5d
OPENAM-4267-Incorrect Reference
CR-4195

git-svn-id: https://svn.forgerock.org/openam/trunk/openam@10022 0f4defcf-c51a-4c67-9f44-6fb5eba73c5d