當前位置: 首頁>>代碼示例>>Java>>正文


Java Label.setRenderBodyOnly方法代碼示例

本文整理匯總了Java中org.apache.wicket.markup.html.basic.Label.setRenderBodyOnly方法的典型用法代碼示例。如果您正苦於以下問題:Java Label.setRenderBodyOnly方法的具體用法?Java Label.setRenderBodyOnly怎麽用?Java Label.setRenderBodyOnly使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.apache.wicket.markup.html.basic.Label的用法示例。


在下文中一共展示了Label.setRenderBodyOnly方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: initLayout

import org.apache.wicket.markup.html.basic.Label; //導入方法依賴的package包/類
private void initLayout(IModel<String> titleModel, String icon, String boxCssClasses) {
	if (boxCssClasses == null) {
    	boxCssClasses = GuiStyleConstants.CLASS_BOX_DEFAULT;
    }
	
    WebMarkupContainer dashboardParent = new WebMarkupContainer(ID_DASHBOARD_PARENT);
    dashboardParent.add(new AttributeAppender("class", " " + boxCssClasses));
    add(dashboardParent);

    WebMarkupContainer dashboardTitle = new WebMarkupContainer(ID_DASHBOARD_TITLE);
    dashboardParent.add(dashboardTitle);
    Label title = new Label(ID_TITLE);
    title.setRenderBodyOnly(true);
    title.setDefaultModel(titleModel);
    dashboardTitle.add(title);

    WebMarkupContainer dashboardContent = new WebMarkupContainer(ID_DASHBOARD_CONTENT);
    dashboardContent.add(getMainComponent(ID_CONTENT));
    dashboardParent.add(dashboardContent);
    
    WebMarkupContainer iconI = new WebMarkupContainer(ID_ICON);
    iconI.add(AttributeModifier.replace("class", icon));
    dashboardTitle.add(iconI);
}
 
開發者ID:Pardus-Engerek,項目名稱:engerek,代碼行數:25,代碼來源:DashboardPanel.java

示例2: onInitialize

import org.apache.wicket.markup.html.basic.Label; //導入方法依賴的package包/類
@Override
protected void onInitialize() {
    super.onInitialize();

    WebMarkupContainer td = new WebMarkupContainer(ID_TD);
    td.add(AttributeModifier.replace("colspan", new AbstractReadOnlyModel<String>() {

        @Override
        public String getObject() {
            return String.valueOf(getTable().getColumns().size());
        }
    }));
    add(td);

    Label count = new Label(ID_COUNT, createModel());
    count.setRenderBodyOnly(true);
    td.add(count);

    PageSizePopover popover = new PageSizePopover(ID_PAGE_SIZE) {

        @Override
        protected void pageSizeChanged(AjaxRequestTarget target) {
            CountToolbar.this.pageSizeChanged(target);
        }
    };
    popover.add(new VisibleEnableBehaviour() {

        @Override
        public boolean isVisible() {
            return CountToolbar.this.isPageSizePopupVisible();
        }
    });
    td.add(popover);
}
 
開發者ID:Pardus-Engerek,項目名稱:engerek,代碼行數:35,代碼來源:CountToolbar.java

示例3: initLayout

import org.apache.wicket.markup.html.basic.Label; //導入方法依賴的package包/類
private void initLayout(boolean noPadding) {
    WebMarkupContainer dashboardParent = new WebMarkupContainer(ID_DASHBOARD_PARENT);
    add(dashboardParent);

    WebMarkupContainer dashboardTitle = new WebMarkupContainer(ID_DASHBOARD_TITLE);
    dashboardParent.add(dashboardTitle);
    Label title = new Label(ID_TITLE);
    title.setRenderBodyOnly(true);
    dashboardTitle.add(title);

    WebMarkupContainer dashboardContent = new WebMarkupContainer(ID_DASHBOARD_CONTENT);
    dashboardParent.add(dashboardContent);

    if (noPadding) {
        dashboardContent.add(AttributeAppender.append("class", "no-padding"));
    }

    dashboardContent.add(new Label(ID_CONTENT));

    WebMarkupContainer preloaderContainer = new WebMarkupContainer(ID_PRELOADER_CONTAINER);
    preloaderContainer.add(new VisibleEnableBehaviour() {

        @Override
        public boolean isVisible() {
            return isLoadingVisible();
        }
    });
    dashboardContent.add(preloaderContainer);

    preloaderContainer.add(getLoadingComponent(ID_PRELOADER));
}
 
開發者ID:Pardus-Engerek,項目名稱:engerek,代碼行數:32,代碼來源:AsyncDashboardPanel.java

示例4: addLabel

import org.apache.wicket.markup.html.basic.Label; //導入方法依賴的package包/類
private void addLabel(String id, String propertyName) {
    Label label = new Label(id, new PropertyModel<String>(repoDiagModel, propertyName));
    label.setRenderBodyOnly(true);
    add(label);
}
 
開發者ID:Pardus-Engerek,項目名稱:engerek,代碼行數:6,代碼來源:PageAbout.java

示例5: newTitle

import org.apache.wicket.markup.html.basic.Label; //導入方法依賴的package包/類
/**
 * Factory method for tab titles. Returned component can be anything that can attach to span
 * tags such as a fragment, panel, or a label
 *
 * @param titleId    id of tiatle component
 * @param titleModel model containing tab title
 * @param index      index of tab
 * @return title component
 */
protected Component newTitle(final String titleId, final IModel<?> titleModel, final int index) {
    Label label = new Label(titleId, titleModel);
    label.setRenderBodyOnly(true);
    return label;
}
 
開發者ID:Pardus-Engerek,項目名稱:engerek,代碼行數:15,代碼來源:TabbedPanel.java


注:本文中的org.apache.wicket.markup.html.basic.Label.setRenderBodyOnly方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。