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


Java RootLayoutPanel.add方法代码示例

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


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

示例1: onLoad

import com.google.gwt.user.client.ui.RootLayoutPanel; //导入方法依赖的package包/类
@Override
public void onLoad() {

	LayoutPanel layoutPanel = new LayoutPanel();
	controller = new ReportingController(eventBus, rpcService);
	layoutPanel.add(controller.createView());
	ReportingPresenter reportingPresenter = controller.getPresenter();
	reportingPresenter.bind();

	final RootPanel rootPanel = new RootPanel(layoutPanel, rpcService);

	rootPanel.getHeader().addTab("Batch Class Management", "BatchClassManagement.html", false);
	rootPanel.getHeader().addTab("Batch Instance Management", "BatchInstanceManagement.html", false);
	rootPanel.getHeader().addTab("Workflow Management", "CustomWorkflowManagement.html", false);
	rootPanel.getHeader().addTab("Folder Management", "FolderManager.html", false);
	rootPanel.getHeader().addNonClickableTab("Reports", "Reporting.html");
	rootPanel.getHeader().getTabBar().selectTab(4);
	rootPanel.addStyleName("set_position");
	rootPanel.getHeader().setEventBus(eventBus);

	rpcService.getUserName(new EphesoftAsyncCallback<String>() {

		@Override
		public void onSuccess(final String userName) {
			rootPanel.getHeader().setUserName(userName);
		}

		@Override
		public void customFailure(final Throwable arg0) {
			// Username cannot be set if the call failed.
		}
	});

	RootLayoutPanel rootLayoutPanel = RootLayoutPanel.get();
	rootLayoutPanel.clear();
	rootLayoutPanel.add(rootPanel);

}
 
开发者ID:kuzavas,项目名称:ephesoft,代码行数:39,代码来源:ReportingEntryPoint.java

示例2: showApp

import com.google.gwt.user.client.ui.RootLayoutPanel; //导入方法依赖的package包/类
private void showApp()
{
    Window.setMargin("0px");
    RootLayoutPanel rootLayoutPanel = RootLayoutPanel.get();
    rootLayoutPanel.clear();
    appScreen.setWidth("100%");
    rootLayoutPanel.add(appScreen);
}
 
开发者ID:muquit,项目名称:gwtoauthlogindemo,代码行数:9,代码来源:GWTOAuthLoginDemo.java

示例3: onModuleLoad

import com.google.gwt.user.client.ui.RootLayoutPanel; //导入方法依赖的package包/类
/**
 * This method constructs the application user interface by instantiating
 * controls and hooking up event handler.
 */
public void onModuleLoad() {
  // Inject global styles.
  GWT.<GlobalResources>create(GlobalResources.class).css().ensureInjected();

  // Create the UI defined in Mail.ui.xml.
  DockLayoutPanel outer = binder.createAndBindUi(this);

  // Get rid of scrollbars, and clear out the window's built-in margin,
  // because we want to take advantage of the entire client area.
  Window.enableScrolling(false);
  Window.setMargin("0px");

  // Special-case stuff to make topPanel overhang a bit.
  Element topElem = outer.getWidgetContainerElement(topPanel);
  topElem.getStyle().setZIndex(2);
  topElem.getStyle().setOverflow(Overflow.VISIBLE);

  // Listen for item selection, displaying the currently-selected item in
  // the detail area.
  mailList.setListener(new MailList.Listener() {
    public void onItemSelected(MailItem item) {
      mailDetail.setItem(item);
    }
  });

  // Add the outer panel to the RootLayoutPanel, so that it will be
  // displayed.
  RootLayoutPanel root = RootLayoutPanel.get();
  root.add(outer);
}
 
开发者ID:Peergos,项目名称:Peergos,代码行数:35,代码来源:Mail.java

示例4: onModuleLoad

import com.google.gwt.user.client.ui.RootLayoutPanel; //导入方法依赖的package包/类
@Override
public void onModuleLoad() {
   RootLayoutPanel rp = RootLayoutPanel.get();
   rp.add(new DemoUI());
}
 
开发者ID:ainslec,项目名称:gwt-promptly,代码行数:6,代码来源:PromptlyDemo.java


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