Difference between revisions of "Board18Map7"
Jump to navigation
Jump to search
(Initial version of this page) |
(added checkForUpdate() functions) |
||
Line 1: | Line 1: | ||
board18Map7.js contains the function that | __NOTOC__ | ||
board18Map7.js contains the function that implements the | |||
keyboard shortcut events and the functions that implement | |||
the call to the checkForUpdate.php routine. | |||
==Function setUpKeys()== | ==Function setUpKeys()== | ||
Line 22: | Line 24: | ||
|E||Rotate Tile Counterclockwise | |E||Rotate Tile Counterclockwise | ||
|} | |} | ||
==Function checkForUpdateCallback(resp) == | |||
The checkForUpdateCallback function is the callback function | |||
for the checkForUpdate function. It acts on the status | |||
returned by the checkForUpdate.php AJAX call. | |||
==Function checkForUpdate() == | |||
The checkForUpdate function does an AJAX post call | |||
for checkForUpdate.php passing the gameid. | |||
==Function delayCheckForUpdate() == | |||
The delayCheckForUpdate function waits 2 minutes before | |||
calling the checkForUpdate function. | |||
==Function resetCheckForUpdate()== | |||
The resetCheckForUpdate function stops any current | |||
setTimeout for the checkForUpdate function and then | |||
calls the delayCheckForUpdate function. |
Revision as of 12:02, 15 October 2014
board18Map7.js contains the function that implements the keyboard shortcut events and the functions that implement the call to the checkForUpdate.php routine.
Function setUpKeys()
The setUpKeys function performs all of the bind operations for the keyboard shortcut events.
KEY | Action |
---|---|
Enter | Accept Move |
C | Cancel Move |
M | Goto Stock Chart |
F | Flip Token |
R | Rotate Tile Clockwise |
E | Rotate Tile Counterclockwise |
Function checkForUpdateCallback(resp)
The checkForUpdateCallback function is the callback function for the checkForUpdate function. It acts on the status returned by the checkForUpdate.php AJAX call.
Function checkForUpdate()
The checkForUpdate function does an AJAX post call for checkForUpdate.php passing the gameid.
Function delayCheckForUpdate()
The delayCheckForUpdate function waits 2 minutes before calling the checkForUpdate function.
Function resetCheckForUpdate()
The resetCheckForUpdate function stops any current setTimeout for the checkForUpdate function and then calls the delayCheckForUpdate function.