当前位置: 首页>>代码示例>>Java>>正文


Java VLayout.addStyleName方法代码示例

本文整理汇总了Java中com.smartgwt.client.widgets.layout.VLayout.addStyleName方法的典型用法代码示例。如果您正苦于以下问题:Java VLayout.addStyleName方法的具体用法?Java VLayout.addStyleName怎么用?Java VLayout.addStyleName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.smartgwt.client.widgets.layout.VLayout的用法示例。


在下文中一共展示了VLayout.addStyleName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: initDigitalObjectEditor

import com.smartgwt.client.widgets.layout.VLayout; //导入方法依赖的package包/类
private Canvas initDigitalObjectEditor(DigitalObjectEditor childEditor, SimpleEventBus eventBus) {
    childEditor.setImportView(true);
    RelationDataSource relationDataSource = RelationDataSource.getInstance();
    relationDataSource.addRelationChangeHandler(new RelationChangeHandler() {

        @Override
        public void onRelationChange(RelationChangeEvent event) {
            // issue 262: isVisible seems to be always true and isAttached is always null.
            // Add test isDrawn that seems to change for dettached widgets.
            if (batchItemGrid.isVisible() && batchItemGrid.isDrawn()) {
                updateCache();
            }
        }
    });
    ActivityManager activityManager = new ActivityManager(
            new ChildActivities(childEditor), eventBus);

    VLayout editorsLayout = new VLayout();
    editorsLayout.addStyleName("defaultBorder");
    activityManager.setDisplay(new ChildEditorDisplay(editorsLayout));
    return editorsLayout;
}
 
开发者ID:proarc,项目名称:proarc,代码行数:23,代码来源:ImportBatchItemEditor.java

示例2: DigitalObjectChildrenEditor

import com.smartgwt.client.widgets.layout.VLayout; //导入方法依赖的package包/类
public DigitalObjectChildrenEditor(ClientMessages i18n, PlaceController places, OptionalEditor preview) {
        this.i18n = i18n;
        this.places = places;
        this.preview = preview;
        this.actionSource = new ActionSource(this);
        this.goDownAction = DigitalObjectNavigateAction.child(i18n, places);
        relationDataSource = RelationDataSource.getInstance();
        childrenListGrid = initChildrenListGrid();
        this.selectionCache = SelectionCache.selector(childrenListGrid);
        VLayout childrenLayout = new VLayout();
        childrenLayout.setMembers(childrenListGrid);
        childrenLayout.setWidth("40%");
        childrenLayout.setShowResizeBar(true);

        SimpleEventBus eventBus = new SimpleEventBus();
        childPlaces = new PlaceController(eventBus);
        childEditor = new DigitalObjectEditor(i18n, childPlaces, true);
        ActivityManager activityManager = new ActivityManager(
                new ChildActivities(childEditor), eventBus);

        VLayout editorsLayout = new VLayout();
        VLayout editorsOuterLayout = new VLayout();
//        editorsLayout.setBorder("1px solid grey");
        editorsLayout.addStyleName("defaultBorder");
        editorsOuterLayout.setLayoutLeftMargin(4);
        editorsOuterLayout.setMembers(editorsLayout);
        activityManager.setDisplay(new ChildEditorDisplay(editorsLayout));

        widget = new HLayout();
        widget.setMembers(childrenLayout, editorsOuterLayout);
        relationDataSource.addRelationChangeHandler(new RelationChangeHandler() {

            @Override
            public void onRelationChange(RelationChangeEvent event) {
                // issue 262: isVisible seems to be always true and isAttached is always null.
                // Add test isDrawn that seems to change for dettached widgets.
                if (digitalObject != null && childrenListGrid.isVisible() && childrenListGrid.isDrawn()) {
                    String changedPid = event.getPid();
                    if (changedPid != null) {
                        Record changedRecord = childrenListGrid.getDataAsRecordList()
                                .find(RelationDataSource.FIELD_PID, changedPid);
                        if (changedRecord == null) {
                            // moved object(s)
                            // ListGrid does not remove selection of removed/moved rows
                            // and it does not fire selection change
                            // issue 246: clear selection of moved row
                            childrenListGrid.deselectAllRecords();
                            DigitalObjectCopyMetadataAction.resetSelection();
                            showCopySelection(new Record[0]);
                            return ;
                        }
                    }
                    final ListGridRecord[] selection = childrenListGrid.getSelectedRecords();
                    relationDataSource.updateCaches(digitalObject.getPid(), new BooleanCallback() {

                        @Override
                        public void execute(Boolean value) {
                            // refresh the copy selection as updated records are missing the copy attribute
                            showCopySelection(DigitalObjectCopyMetadataAction.getSelection());
                            // refresh the list selection
                            selectChildren(selection);
                        }
                    });
                }
            }
        });
    }
 
开发者ID:proarc,项目名称:proarc,代码行数:68,代码来源:DigitalObjectChildrenEditor.java

示例3: onModuleLoad

import com.smartgwt.client.widgets.layout.VLayout; //导入方法依赖的package包/类
public void onModuleLoad() {
	initializeConstants();

	// Build all layout blocks.
	Layout header = createHeader();

	Layout footer = createFooter();

	HLayout layoutRibbon = new HLayout();
	layoutRibbon.setAlign(Alignment.CENTER);

	VLayout layoutWest = new VLayout();
	layoutWest.addStyleName("applicationLayoutWest");
	VLayout layoutCenter = new VLayout();
	layoutCenter.addStyleName("applicationLayoutCenter");

	VLayout mainLayout = new VLayout();
	layoutRibbon.setHeight(85);
	layoutRibbon.setOverflow(Overflow.HIDDEN);
	// layoutNorth.addMember(layoutNorthWest);
	// layoutNorth.addMember(layoutNorthCenter);
	// layoutNorth.addMember(layoutNorthEast);
	HLayout middle = new HLayout();
	middle.setHeight("*");
	layoutWest.setWidth(300);
	middle.addMember(layoutWest);
	middle.addMember(layoutCenter);
	mainLayout.addMember(header);
	mainLayout.addMember(layoutRibbon);
	mainLayout.addMember(middle);
	mainLayout.addMember(footer);
	mainLayout.addStyleName("applicationLayoutBody");
	mainLayout.setWidth100();
	mainLayout.setHeight100();

	// ---------------------------------------------------------------------
	// Create the left-side (map and tabs):
	// ---------------------------------------------------------------------
	map = new MapWidget("mapMain", "app");
	GsfLayout.searchWindowParentElement = map;

	// -- Create Ribbon
	final RibbonBarLayout ribbonBar = new RibbonBarLayout(map, "app", "ribbon-bar");
	ribbonBar.setAlign(Alignment.CENTER);
	ribbonBar.setOverflow(Overflow.HIDDEN);
	ribbonBar.setStyleName("msRibbon");
	ribbonBar.setMembersMargin(0);
	ribbonBar.setHeight(100);

	// LayerTree layout:
	CombinedLayertree layerTree = getCombinedLayertree();

	layoutRibbon.addMember(ribbonBar);
	layoutWest.addMember(layerTree);
	layoutCenter.addMember(map);

	mainLayout.draw();

	initialize();
}
 
开发者ID:geomajas,项目名称:geomajas-project-client-gwt,代码行数:61,代码来源:Application.java


注:本文中的com.smartgwt.client.widgets.layout.VLayout.addStyleName方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。