use of org.apache.wicket.AbortException in project servoy-client by Servoy.
the class WebClient method onBeginRequest.
public void onBeginRequest(WebClientSession webClientSession) {
Solution solution = getSolution();
if (solution != null) {
synchronized (onBeginRequestLock) {
long solutionLastModifiedTime = webClientSession.getSolutionLastModifiedTime(solution);
if (solutionLastModifiedTime != -1 && solutionLastModifiedTime != solution.getLastModifiedTime()) {
if (isClosing() || isShutDown()) {
if (((WebRequest) RequestCycle.get().getRequest()).isAjax())
throw new AbortException();
else
throw new RestartResponseException(Application.get().getHomePage());
}
refreshI18NMessages(true);
((IScriptSupport) getScriptEngine()).reload();
((WebFormManager) getFormManager()).reload();
MainPage page = (MainPage) ((WebFormManager) getFormManager()).getMainContainer(null);
throw new RestartResponseException(page);
}
executeEvents();
}
}
}
use of org.apache.wicket.AbortException in project servoy-client by Servoy.
the class ServoyAjaxPagingNavigator method newPagingNavigationIncrementLink.
/**
* @see wicket.ajax.markup.html.navigation.paging.AjaxPagingNavigator#newPagingNavigationIncrementLink(java.lang.String, wicket.markup.html.navigation.paging.IPageable, int)
*/
@Override
protected Link newPagingNavigationIncrementLink(String id, IPageable pageable, int increment) {
Link rez = new AjaxPagingNavigationIncrementLink(id, pageable, increment) {
private static final long serialVersionUID = 1L;
/**
* @see wicket.ajax.markup.html.navigation.paging.AjaxPagingNavigationIncrementLink#onClick(wicket.ajax.AjaxRequestTarget)
*/
@Override
public void onClick(AjaxRequestTarget target) {
super.onClick(target);
Page page = findPage();
if (page != null) {
WebEventExecutor.generateResponse(target, page);
} else
throw new AbortException();
}
};
TabIndexHelper.setUpTabIndexAttributeModifier(rez, tabIndex);
return rez;
}
Aggregations