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


Java VLayout.draw方法代码示例

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


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

示例1: onModuleLoad

import com.smartgwt.client.widgets.layout.VLayout; //导入方法依赖的package包/类
@Override
    public void onModuleLoad() {
        INSTANCE = this;
        initLogging();
        
        ClientUtils.info(LOG, "onModuleLoad:\n module page: %s\n host page: %s"
                + "\n getModuleName: %s\n getPermutationStrongName: %s\n version: %s"
                + "\n Page.getAppDir: %s, \n Locale: %s",
                GWT.getModuleBaseURL(), GWT.getHostPageBaseURL(),
                GWT.getModuleName(), GWT.getPermutationStrongName(), GWT.getVersion(),
                Page.getAppDir(), LanguagesDataSource.activeLocale()
                );

        // remove the loading wrapper. See index.html
        DOM.getElementById("loadingWrapper").removeFromParent();

        I18nUtil.initMessages(ClientUtils.createSmartGwtMessages());
        i18n = GWT.create(ClientMessages.class);

        errorHandler = new ErrorHandler();
        errorHandler.initTransportErrorHandler();

        LoginWindow.login();

        presenterFactory = new PresenterFactory(i18n);

        editorWorkFlow = new EditorWorkFlow(getDisplay(), presenterFactory, i18n);
        presenterFactory.setPlaceController(editorWorkFlow.getPlaceController());

        final TreeGrid menu = createMenu();

        sweepTask = new SweepTask() {

            @Override
            public void processing() {
                SC.clearPrompt();
                TreeNode[] menuContent = createMenuContent();
                Tree tree = menu.getTree();
                TreeNode root = tree.getRoot();
                tree.addList(menuContent, root);
                tree.openAll();
                editorWorkFlow.init();
            }
        };

        final HLayout mainLayout = new HLayout();
//        mainLayout.setLayoutMargin(5);
        mainLayout.setWidth100();
        mainLayout.setHeight100();
        mainLayout.setMembers(getDisplay());

        Canvas mainHeader = createMainHeader(menu);

        VLayout desktop = new VLayout(0);
        desktop.setWidth100();
        desktop.setHeight100();
        desktop.setMembers(mainHeader, mainLayout);
        desktop.draw();

        SC.showPrompt(i18n.Editor_InitialLoading_Msg());
        LocalizationDataSource.getInstance().initOnStart(sweepTask.expect());
        ValueMapDataSource.getInstance().initOnStart(sweepTask.expect());
        loadPermissions();
    }
 
开发者ID:proarc,项目名称:proarc,代码行数:65,代码来源:Editor.java

示例2: onModuleLoad

import com.smartgwt.client.widgets.layout.VLayout; //导入方法依赖的package包/类
public void onModuleLoad() {
	VLayout mainLayout = new VLayout();
	mainLayout.setWidth100();
	mainLayout.setHeight100();
	mainLayout.setBackgroundColor("#A0A0A0");

	HLayout layout = new HLayout();
	layout.setWidth100();
	layout.setHeight100();
	layout.setMembersMargin(10);
	layout.setMargin(10);

	// ---------------------------------------------------------------------
	// Create the left-side (map and tabs):
	// ---------------------------------------------------------------------
	map = new MapWidget("mapMain", "app");
	final Toolbar toolbar = new Toolbar(map, WidgetLayout.toolbarLargeButtonSize);
	toolbar.setBackgroundColor("#647386");
	toolbar.setBackgroundImage("");
	toolbar.setBorder("0px");

	toolbar.addToolbarSeparator();
	toolbar.addMenuButton(getReportingMenuButton());

	Label title = new Label("Geomajas reporting demo");
	title.setStyleName("appTitle");
	title.setWidth(260);
	toolbar.addFill();
	toolbar.addMember(title);

	VLayout mapLayout = new VLayout();
	mapLayout.addMember(toolbar);
	mapLayout.addMember(map);
	mapLayout.setHeight("65%");

	VLayout leftLayout = new VLayout();
	leftLayout.setBorder("10px solid #777777");
	leftLayout.setStyleName("round_corner");
	leftLayout.addMember(mapLayout);

	layout.addMember(leftLayout);

	// ---------------------------------------------------------------------
	// Create the right-side (layer-tree, legend):
	// ---------------------------------------------------------------------
	final SectionStack sectionStack = new SectionStack();
	sectionStack.setBorder("10px solid #777777");
	sectionStack.setStyleName("round_corner");
	sectionStack.setVisibilityMode(VisibilityMode.MULTIPLE);
	sectionStack.setCanReorderSections(true);
	sectionStack.setCanResizeSections(false);
	sectionStack.setSize("250px", "100%");

	// LayerTree layout:
	SectionStackSection section2 = new SectionStackSection("Layer tree");
	section2.setExpanded(true);
	LayerTree layerTree = new LayerTree(map);
	section2.addItem(layerTree);
	sectionStack.addSection(section2);

	// Legend layout:
	SectionStackSection section3 = new SectionStackSection("Legend");
	section3.setExpanded(true);
	legend = new Legend(map.getMapModel());
	legend.setBackgroundColor("#FFFFFF");
	section3.addItem(legend);
	sectionStack.addSection(section3);

	// Putting the right side layouts together:
	layout.addMember(sectionStack);

	// ---------------------------------------------------------------------
	// Finally draw everything:
	// ---------------------------------------------------------------------
	mainLayout.addMember(layout);
	mainLayout.draw();

	// Then initialize:
	initialize();
}
 
开发者ID:geomajas,项目名称:geomajas-project-client-gwt,代码行数:81,代码来源:Application.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.draw方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。