Community
Participate
Working Groups
this._timer.addEventListener( "interval", function( e ) {
var newHash = this.__getState();
// RAP [if] Ignore all non application states
if( newHash != this._state ) {
//if (newHash != this._state) {
if( newHash != this._state && this._titles[ newHash ] != null ) {
this.__onHistoryLoad(newHash);
}
}, this );
assertEquals( "text1", browserHistory._titles[ "id1" ] );
},
testSendNavigatedWithUnknownEntry : [
function() {
var browserHistory = this._createBrowserHistoryByProtocol();
org.eclipse.rwt.protocol.Processor.processOperation( {
"target" : "bh",
"action" : "call",
"method" : "add",
"properties" : {
"entries" : [ [ "id1", "text1" ], [ "id2", "text2" ] ]
} );
"action" : "listen",
"navigation" : true
org.eclipse.rwt.test.fixture.TestUtil.store( browserHistory );
org.eclipse.rwt.test.fixture.TestUtil.delayTest( 200 );
function( browserHistory) {
browserHistory.__getState = function() { return "id3"; };
org.eclipse.rwt.test.fixture.TestUtil.forceInterval( browserHistory._timer );
var msg = org.eclipse.rwt.test.fixture.TestUtil.getMessage();
assertTrue( msg.indexOf( "org.eclipse.rwt.events.historyNavigated.entryId=id3" ) != -1 );
],
/////////
// Helper