if (RequestCycle.get().getRequestTarget() instanceof AjaxRequestTarget) {
AjaxRequestTarget target = (AjaxRequestTarget) RequestCycle.get().getRequestTarget();
//and register listener
DojoTargetRefresherManager mgr = DojoTargetRefresherManager.get();
mgr.addComponent(getComponent());
target.addListener(mgr);
onComponentReRendered(target);
}
}