List of usage examples for org.apache.wicket.util.string StringValue toBoolean
public final boolean toBoolean(final boolean defaultValue)
From source file:org.onexus.website.api.pages.browser.layouts.AbstractLayout.java
License:Apache License
protected boolean isEmbed() { StringValue embed = getPage().getPageParameters().get("embed"); return embed.toBoolean(false); }
From source file:org.onexus.website.api.pages.browser.layouts.leftmain.LeftMainLayout.java
License:Apache License
@Override protected void onBeforeRender() { StringValue embed = getPage().getPageParameters().get("embed"); boolean visible = !embed.toBoolean(false); get("leftwidgets").setVisible(visible); super.onBeforeRender(); }
From source file:org.onexus.website.api.pages.browser.layouts.topleft.TopleftLayout.java
License:Apache License
@Override protected void onBeforeRender() { StringValue embed = getPage().getPageParameters().get("embed"); boolean visible = !embed.toBoolean(false); get("leftwidgets").setVisible(visible); get("topwidgets").setVisible(visible); get("toprightwidgets").setVisible(visible); super.onBeforeRender(); }
From source file:org.onexus.website.api.pages.browser.layouts.topmain.TopmainLayout.java
License:Apache License
@Override protected void onBeforeRender() { StringValue embed = getPage().getPageParameters().get("embed"); boolean visible = !embed.toBoolean(false); get("topwidgets").setVisible(visible); get("toprightwidgets").setVisible(visible); get("main").setEnabled(visible); super.onBeforeRender(); }
From source file:org.onexus.website.api.Website.java
License:Apache License
@Override protected void onBeforeRender() { StringValue embed = getPage().getPageParameters().get("embed"); boolean visible = !embed.toBoolean(false); get("header").setVisible(visible); get("bottom").setVisible(visible); if (!Authorization.authorize(getConfig()) || !Authorization.authorize(getConfig().getPage(getStatus().getCurrentPage()))) { if (WebsiteSession.get().isSignedIn()) { setResponsePage(NotAuthorizedPage.class); } else {/* www. j a v a 2s. c om*/ WebsiteApplication.get().restartResponseAtSignInPage(); } } super.onBeforeRender(); }