use of com.gwtplatform.mvp.shared.proxy.PlaceRequest in project ovirt-engine by oVirt.
the class AbstractMainWithDetailsPresenter method onReveal.
@Override
protected void onReveal() {
super.onReveal();
setInSlot(TYPE_SetSearchPanel, searchPanelPresenterWidget);
setInSlot(TYPE_SetBreadCrumbs, breadCrumbsPresenterWidget);
if (hasActionPanelPresenterWidget()) {
getTable().setActionMenus(getActionPanelPresenterWidget().getActionButtons());
}
breadCrumbsPresenterWidget.hideSelectedName();
breadCrumbsPresenterWidget.rebuildBreadCrumbs();
getView().resizeToFullHeight();
PlaceRequest currentPlace = placeManager.getCurrentPlaceRequest();
Set<FragmentParams> params = FragmentParams.getParams(currentPlace);
params.forEach(param -> {
switch(param) {
case SEARCH:
String search = currentPlace.getParameter(FragmentParams.SEARCH.getName(), "");
if (!"".equals(search)) {
// We have a search parameter. The tokenizer has already run it through URL decode so we should be
// able to simply pass it to setSearchString in the model.
applySearchString(getModel().getDefaultSearchString() + search);
}
break;
default:
break;
}
});
}
use of com.gwtplatform.mvp.shared.proxy.PlaceRequest in project ovirt-engine by oVirt.
the class ApplicationPlaceManager method onMainModelSelectionChange.
@Override
public void onMainModelSelectionChange(MainModelSelectionChangeEvent event) {
String nameToken = event.getMainModel().getApplicationPlace();
PlaceRequest placeRequest;
if (nameToken != null && event.getMainModel().getIsAvailable()) {
placeRequest = PlaceRequestFactory.get(nameToken);
} else {
placeRequest = getDefaultPlace();
}
revealPlace(placeRequest);
}
Aggregations