return token;
}
private void registerPageKeys() {
if (isDebugMode()) {
KeyIdentifier debugKey = new KeyIdentifier();
debugKey.setCtrlKey(true);
debugKey.setKeyName("D");
Page.registerKey(debugKey, new KeyCallback() {
public void execute(String keyName) {
SC.showConsole();
}
});
}
// Control-Shift-S for aggregate rpc service stats
KeyIdentifier statisticsWindowKey = new KeyIdentifier();
statisticsWindowKey.setCtrlKey(true);
statisticsWindowKey.setShiftKey(true);
statisticsWindowKey.setAltKey(false);
statisticsWindowKey.setKeyName("S");
Page.registerKey(statisticsWindowKey, new KeyCallback() {
public void execute(String keyName) {
TestRemoteServiceStatisticsView.showInWindow();
}
});
// Control-Alt-S for response stats
KeyIdentifier responseStatsWindowKey = new KeyIdentifier();
responseStatsWindowKey.setCtrlKey(true);
statisticsWindowKey.setShiftKey(false);
responseStatsWindowKey.setAltKey(true);
responseStatsWindowKey.setKeyName("s");
Page.registerKey(responseStatsWindowKey, new KeyCallback() {
public void execute(String keyName) {
TestDataSourceResponseStatisticsView.showInWindow();
}
});
KeyIdentifier messageCenterWindowKey = new KeyIdentifier();
messageCenterWindowKey.setCtrlKey(true);
messageCenterWindowKey.setKeyName("M");
Page.registerKey(messageCenterWindowKey, new KeyCallback() {
public void execute(String keyName) {
menuBarView.getMessageCenter().showMessageCenterWindow();
}
});
KeyIdentifier testTopViewKey = new KeyIdentifier();
testTopViewKey.setCtrlKey(true);
testTopViewKey.setAltKey(true);
testTopViewKey.setKeyName("t");
Page.registerKey(testTopViewKey, new KeyCallback() {
public void execute(String keyName) {
goToView("Test");
}
});