source: Dev/trunk/src/client/dojo/tests/resources/ApplicationState.js

Last change on this file was 483, checked in by hendrikvanantwerpen, 11 years ago

Added Dojo 1.9.3 release.

File size: 974 bytes
RevLine 
[483]1/*
2ApplicationState is an object that represents the application state.
3It will be given to dojo.undo.browser to represent the current application state.
4*/
5ApplicationState = function(stateData, outputDivId, backForwardOutputDivId, bookmarkValue){
6        this.stateData = stateData;
7        this.outputDivId = outputDivId;
8        this.backForwardOutputDivId = backForwardOutputDivId;
9        this.changeUrl = bookmarkValue;
10};
11
12ApplicationState.prototype.back = function(){
13        this.showBackForwardMessage("BACK for State Data: " + this.stateData);
14        this.showStateData();
15};
16
17ApplicationState.prototype.forward = function(){
18        this.showBackForwardMessage("FORWARD for State Data: " + this.stateData);
19        this.showStateData();
20};
21
22ApplicationState.prototype.showStateData = function(){
23        dojo.byId(this.outputDivId).innerHTML += this.stateData + '<br />';
24};
25
26ApplicationState.prototype.showBackForwardMessage = function(message){
27        dojo.byId(this.backForwardOutputDivId).innerHTML += message + '<br />';
28};
Note: See TracBrowser for help on using the repository browser.