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


Java HorizontalSplitPanel.setFirstComponent方法代码示例

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


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

示例1: createContent

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@Override
protected Component createContent() {

    VerticalLayout layout = new VerticalLayout();

    layout.addComponent(spellSound);

    title = new Label();
    classe = new LabelField<>("Classe : ");
    classLevel = new LabelField<>("Niveau de classe : ");
    layout.addComponents(title);

    tabs = new TabSheet();

    panel = new HorizontalSplitPanel();
    panel.setSizeFull();
    panel.setCaption(Messages.getInstance().getMessage("spellStep.spell.label"));
    panel.setFirstComponent(tabs);
    layout.addComponent(panel);

    return layout;
}
 
开发者ID:viydaag,项目名称:dungeonstory-java,代码行数:23,代码来源:SpellChoiceForm.java

示例2: showView

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
/**
 * Diese Methode setzt die obere und die zwei unteren Views in der Prozessansicht.
 * 
 * @author: Mirko Göpfrich
 */

@Override
public void showView(View topView, View bottomLeftView, View bottomRigthView) {
	verticalSplitPanel.setFirstComponent((Component) topView);
	
	//Teilt das Panel horizontal un zwei gleiche Bereiche auf und ertstellt eine vertiakel Trennlinie (nicht verstellbar.)
	horizontalSplitPanel = new HorizontalSplitPanel();
	horizontalSplitPanel.setSizeFull();
	horizontalSplitPanel.setSplitPosition(50, UNITS_PERCENTAGE);
	horizontalSplitPanel.setLocked(true);
	horizontalSplitPanel.setStyleName("small");

	horizontalSplitPanel.setFirstComponent((Component) bottomLeftView);
	horizontalSplitPanel.setSecondComponent((Component) bottomRigthView);
	
	//fügt dem unteren vertikalen Panel ein horizontales SplitPanel hinzu.
	verticalSplitPanel.setSecondComponent(horizontalSplitPanel);
	logger.debug("Horizontales SplitPanel für Prozessschritte und Infos erstellt und an das untere vertikale Panel übergeben");

}
 
开发者ID:DHBW-Karlsruhe,项目名称:businesshorizon2,代码行数:26,代码来源:ProcessViewImpl.java

示例3: init

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@PostConstruct
protected void init() {
    setSizeFull();

    tabbedPanel = new TabbedPanel();

    HorizontalSplitPanel leftSplit = new HorizontalSplitPanel();
    leftSplit.setSizeFull();
    leftSplit.setSplitPosition(UIConstants.DEFAULT_LEFT_SPLIT, Unit.PIXELS);

    deployNavigator = new DeployNavigator(context, tabbedPanel);

    leftSplit.setFirstComponent(deployNavigator);
    VerticalLayout container = new VerticalLayout();
    container.setSizeFull();
    container.addComponent(tabbedPanel);
    leftSplit.setSecondComponent(container);

    addComponent(leftSplit);

}
 
开发者ID:JumpMind,项目名称:metl,代码行数:22,代码来源:DeployView.java

示例4: init

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@PostConstruct
protected void init() {
    setSizeFull();

    tabbedPanel = new TabbedPanel();

    HorizontalSplitPanel leftSplit = new HorizontalSplitPanel();
    leftSplit.setSizeFull();
    leftSplit.setSplitPosition(UIConstants.DEFAULT_LEFT_SPLIT, Unit.PIXELS);

    projectNavigator = new DesignNavigator(context, tabbedPanel);

    leftSplit.setFirstComponent(projectNavigator);
    VerticalLayout container = new VerticalLayout();
    container.setSizeFull();
    container.addComponent(tabbedPanel);
    leftSplit.setSecondComponent(container);

    addComponent(leftSplit);
}
 
开发者ID:JumpMind,项目名称:metl,代码行数:21,代码来源:DesignView.java

示例5: createMainComponent

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
private void createMainComponent() {
	VerticalLayout main = new VerticalLayout();
	main.setMargin(false);
	main.setSizeFull();
	main.addComponent(createToolbar());

	mainSplitPanel = new HorizontalSplitPanel();
	mainSplitPanel.setMargin(false);
	mainSplitPanel.setMaxSplitPosition(80f, HorizontalSplitPanel.UNITS_PERCENTAGE);
	mainSplitPanel.setMinSplitPosition(20f, HorizontalSplitPanel.UNITS_PERCENTAGE);
	mainSplitPanel.setSizeFull();
	mainSplitPanel.setSplitPosition(30f, HorizontalSplitPanel.UNITS_PERCENTAGE);

	taskTable = createTable();
	mainSplitPanel.setFirstComponent(taskTable);

	displayEmptyTask();

	main.addComponent(mainSplitPanel);
	main.setExpandRatio(mainSplitPanel, 1.0f);
	mainComponent = main;
}
 
开发者ID:frincon,项目名称:openeos,代码行数:23,代码来源:TasksWindow.java

示例6: init

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@Override
protected void init(VaadinRequest request) {

	setPollInterval(1000);
	hl = new HorizontalSplitPanel();
	hl.setSizeFull();
	setContent(hl);

	buttonsOnTheLeft = new VerticalLayout();
	buttonsOnTheLeft.setSizeUndefined();

	hl.setFirstComponent(buttonsOnTheLeft);
	hl.setSplitPosition(25, Unit.PERCENTAGE);

	ServiceTracker<FragmentFactory, FragmentFactory> tracker = new ServiceTracker<FragmentFactory, FragmentFactory>(
			VaadinActivator.context, FragmentFactory.class, this);
	tracker.open();
	
	addDetachListener(new DetachListener() {
		
		@Override
		public void detach(DetachEvent event) {
			tracker.close();
		}
	});
}
 
开发者ID:vaadin,项目名称:osgi-bridge-and-fragmentedui-demo,代码行数:27,代码来源:VaadinOSGiUI.java

示例7: initContent2

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
private void initContent2() {
	VerticalLayout content = new VerticalLayout();
	content.setWidth("100%");
	setContent(content);
	Label envLbl = createEnvLabel();
	HorizontalLayout topMenu = new HorizontalLayout();
	middle = new HorizontalSplitPanel();
	bottom = new HorizontalLayout();
	VerticalLayout leftMenu = new VerticalLayout();
	main = new VerticalLayout();
	leftMenu.addComponents(mainBtn,filtersBtn);
	int buttonSize = 100;
	mainBtn.setWidth(buttonSize,Unit.PIXELS);
	filtersBtn.setWidth(buttonSize,Unit.PIXELS);
	mainBtn.setEnabled(false);
	filtersBtn.setEnabled(false);
	filtersBtn.addStyleName(ValoTheme.BUTTON_PRIMARY);
	leftMenu.setVisible(false);
	
	topMenu.addComponents(envLbl,processBtn,loadHistoricalQuotesBtn);
	leftMenu.setWidth(buttonSize,Unit.PIXELS);
	
	middle.setFirstComponent(leftMenu);
	middle.setSecondComponent(main);
	middle.setSplitPosition(buttonSize, Sizeable.Unit.PIXELS);
	content.addComponents(topMenu,middle,bottom);
	
}
 
开发者ID:charcode,项目名称:StockScreener,代码行数:29,代码来源:StockScreenerControlUI.java

示例8: initWindow

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
private void initWindow(Object selectedItem) {
    Panel exportPanel = new Panel("Export and Dependencies");
    exportPanel.addStyleName(ValoTheme.PANEL_SCROLL_INDICATOR);
    exportPanel.setSizeFull();
    VerticalLayout exportLayout = new VerticalLayout();
    exportLayout.setMargin(true);
    addSelectedAndDependentObjects(exportLayout, selectedItem);
    exportPanel.setContent(exportLayout);

    Panel affectedPanel = new Panel("Possible Affected Flows");
    affectedPanel.setSizeFull();
    exportPanel.addStyleName(ValoTheme.PANEL_SCROLL_INDICATOR);
    affectedLayout = new VerticalLayout();
    affectedLayout.setMargin(true);
    updateAffectedObjects();
    affectedPanel.setContent(affectedLayout);

    // Split panel for Export and Affected
    HorizontalSplitPanel splitPanel = new HorizontalSplitPanel();
    splitPanel.setWidth(100, Unit.PERCENTAGE);
    splitPanel.setFirstComponent(exportPanel);
    splitPanel.setSecondComponent(affectedPanel);

    addComponent(splitPanel, 1);
    
    Button selectAllLink = new Button("Select All");
    selectAllLink.addStyleName(ValoTheme.BUTTON_LINK);
    selectAllLink.addClickListener((event) -> selectAll());

    Button selectNoneLink = new Button("Select None");
    selectNoneLink.addStyleName(ValoTheme.BUTTON_LINK);
    selectNoneLink.addClickListener((event) -> selectNone());
    
    addComponent(buildButtonFooter(new Button[] {selectAllLink, selectNoneLink}, new Button("Export", new ExportClickListener()), buildCloseButton()));

    setWidth(700, Unit.PIXELS);
    setHeight(500, Unit.PIXELS);
}
 
开发者ID:JumpMind,项目名称:metl,代码行数:39,代码来源:ExportDialog.java

示例9: init

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@Override
protected void init(VaadinRequest request) {
	treeToolEditor = new TreeToolEditor(this);
	toolEditor = new ToolEditor(this);
	textEditor = new TextEditor(this);
	final Panel vLayout = new Panel();
	vSplitPanel = new VerticalSplitPanel();
	vSplitPanel.setSplitPosition(50, Unit.PERCENTAGE);
	vSplitPanel.setImmediate(true);
	vSplitPanel.setLocked(false);
	vSplitPanel.setWidth("100%");
	vLayout.setContent(vSplitPanel);
    setContent(vSplitPanel);
    VerticalLayout vvLayout = new VerticalLayout();
    vvLayout.setSizeFull();
    Label title = new Label("<h2><b>&nbsp;Tool Editor</b></h2>", ContentMode.HTML);

    vvLayout.addComponent(title);
    vvLayout.setComponentAlignment(title, Alignment.TOP_LEFT);
    HorizontalSplitPanel hSplitpPanel = new HorizontalSplitPanel();
    hSplitpPanel.setSizeFull();
    vvLayout.addComponent(hSplitpPanel);

    HorizontalLayout buttonPanel = getButtonPanel();
    vvLayout.addComponent(buttonPanel);
    vvLayout.setComponentAlignment(buttonPanel, Alignment.MIDDLE_CENTER);

    vvLayout.setExpandRatio(hSplitpPanel, 5);
    vvLayout.setComponentAlignment(hSplitpPanel, Alignment.TOP_LEFT);
    vvLayout.setMargin(false);
    vvLayout.setSpacing(false);
    hSplitpPanel.setFirstComponent(treeToolEditor);
    hSplitpPanel.setSecondComponent(toolEditor);
    vSplitPanel.setFirstComponent(vvLayout);
    vSplitPanel.setSecondComponent(textEditor);
    hSplitpPanel.setStyleName("topborder");
}
 
开发者ID:chipster,项目名称:chipster,代码行数:38,代码来源:ToolEditorUI.java

示例10: init

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@Override
protected void init(VaadinRequest request) {
	final VerticalLayout layout = new VerticalLayout();
	layout.setMargin(true);
	layout.setSizeFull();
	setContent(layout);
	
	HorizontalSplitPanel hPanel = new HorizontalSplitPanel();
	VerticalSplitPanel vPanel = new VerticalSplitPanel();
	Panel playerPanel = new Panel("Player");
	Panel roundsPanel = new Panel("Rounds");
	Panel matchesPanel = new Panel("Matches");
	Table playersTable = new Table("PlayersTable");
	playersTable.addContainerProperty("Id", Integer.class, null);
	playersTable.addContainerProperty("Name", String.class, null);
	playersTable.addContainerProperty("Score", Integer.class, null);
	playersTable.addContainerProperty("Handicap", Integer.class,null);
	Table roundsTable = new Table("RoundsTable");
	Table matchesTable = new Table("MatchesTable");
	playerPanel.setContent(playersTable);
	HorizontalLayout newPlayerLayout = new HorizontalLayout();
	TextField newPlayer = new TextField(null,"newPlayer");
	Button addPlayerButton = new Button("addPlayer");
	newPlayerLayout.addComponent(newPlayer);
	newPlayerLayout.addComponent(addPlayerButton);
	hPanel.addComponent(newPlayerLayout);
	roundsPanel.setContent(roundsTable);
	matchesPanel.setContent(matchesTable);

	VerticalLayout playerLayout = new VerticalLayout();
	playerLayout.addComponent(playerPanel);
	playerLayout.addComponent(newPlayerLayout);

	VerticalLayout roundsLayout = new VerticalLayout();
	roundsLayout.addComponent(roundsPanel);
	Button addRoundButton = new Button("addRound");
	roundsLayout.addComponent(roundsPanel);
	roundsLayout.addComponent(addRoundButton);
	
	layout.addComponent(hPanel);
	hPanel.setFirstComponent(playerLayout);
	hPanel.setSecondComponent(vPanel);
	vPanel.setFirstComponent(roundsLayout);
	vPanel.setSecondComponent(matchesPanel);
}
 
开发者ID:johannestigges,项目名称:tournament,代码行数:46,代码来源:TournamentUI.java

示例11: init

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
@PostConstruct
protected void init() {
    setSizeFull();

    tabbedPanel = new TabbedPanel();

    HorizontalSplitPanel leftSplit = new HorizontalSplitPanel();
    leftSplit.setSizeFull();
    leftSplit.setSplitPosition(UIConstants.DEFAULT_LEFT_SPLIT, Unit.PIXELS);

    VerticalLayout container = new VerticalLayout();
    container.setSizeFull();
    container.addComponent(tabbedPanel);
    leftSplit.setSecondComponent(container);

    table = new TreeTable();
    table.addStyleName(ValoTheme.TREETABLE_NO_HORIZONTAL_LINES);
    table.addStyleName(ValoTheme.TREETABLE_NO_STRIPES);
    table.addStyleName(ValoTheme.TREETABLE_NO_VERTICAL_LINES);
    table.addStyleName(ValoTheme.TREETABLE_BORDERLESS);
    table.setColumnHeaderMode(ColumnHeaderMode.HIDDEN);
    table.setSizeFull();
    table.setCacheRate(100);
    table.setPageLength(100);
    table.setImmediate(true);
    table.setSelectable(true);
    table.addItemClickListener(this);
    table.addStyleName("noselect");
    table.addContainerProperty("id", String.class, null);
    table.setVisibleColumns(new Object[] { "id" });
    table.setColumnExpandRatio("id", 1);
    addItem("Users", Icons.USER);
    addItem("Groups", Icons.GROUP);
    addItem("REST", Icons.REST);
    addItem("General Settings", Icons.SETTINGS);
    addItem("Plugin Repositories", Icons.DATABASE);
    addItem("Plugins", Icons.COMPONENT);
    addItem("Mail Server", Icons.EMAIL);
    addItem("Notifications", Icons.NOTIFICATION);
    addItem("Active Users", FontAwesome.USERS);
    addItem("Audit Events", FontAwesome.BARS);
    addItem("Logging", Icons.LOGGING);        
    addItem("About", FontAwesome.QUESTION);
    
    VerticalLayout navigator = new VerticalLayout();
    navigator.addStyleName(ValoTheme.MENU_ROOT);
    navigator.setSizeFull();
    leftSplit.setFirstComponent(navigator);
            
    MenuBar leftMenuBar = new MenuBar();
    leftMenuBar.addStyleName(ValoTheme.MENUBAR_BORDERLESS);
    leftMenuBar.setWidth(100, Unit.PERCENTAGE);
    navigator.addComponent(leftMenuBar);

    navigator.addComponent(table);
    navigator.setExpandRatio(table, 1);
    
    addComponent(leftSplit);
    
}
 
开发者ID:JumpMind,项目名称:metl,代码行数:61,代码来源:AdminView.java

示例12: buildUI

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
protected void buildUI() {

        ButtonBar buttonBar = new ButtonBar();
        addComponent(buttonBar);

        if (!readOnly) {
          Button testButton = buttonBar.addButton("Test", FontAwesome.FILE_CODE_O);
          testButton.addClickListener(new TestClickListener());
        }

        filterField = buttonBar.addFilter();
        filterField.addTextChangeListener(this);
        
        HorizontalSplitPanel splitPanel = new HorizontalSplitPanel();
        splitPanel.setSizeFull();
        splitPanel.setSplitPosition(50, Unit.PERCENTAGE);

        VerticalLayout leftLayout = new VerticalLayout();
        editor = new AceEditor();
        editor.setMode(AceMode.xml);
        editor.setSizeFull();
        editor.setHighlightActiveLine(true);
        editor.setShowPrintMargin(false);
        editor.addTextChangeListener(new StylesheetChangeListener());
        editor.setValue(component.findSetting(XsltProcessor.XSLT_PROCESSOR_STYLESHEET).getValue());
        leftLayout.addComponent(new Label("XSLT Stylesheet"));
        leftLayout.addComponent(editor);
        leftLayout.setExpandRatio(editor, 1.0f);
        leftLayout.setSizeFull();
        splitPanel.setFirstComponent(leftLayout);
        
        VerticalLayout rightLayout = new VerticalLayout();
        rightLayout.setSizeFull();
        rightLayout.addComponent(new Label("Sample Input XML"));
        textArea = new TextArea();
        textArea.setEnabled(false);
        textArea.setSizeFull();
        textArea.setValue(getSampleXml());
        rightLayout.addComponent(textArea);
        rightLayout.setExpandRatio(textArea, 1.0f);
        splitPanel.setSecondComponent(rightLayout);

        addComponent(splitPanel);
        setExpandRatio(splitPanel, 1.0f);
        
        textArea.setReadOnly(readOnly);
        editor.setReadOnly(readOnly);

    }
 
开发者ID:JumpMind,项目名称:metl,代码行数:50,代码来源:EditXsltPanel.java

示例13: FilesViewerComponent

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
public FilesViewerComponent(String directoryPath, boolean showDeleteButton, boolean showDownloadButton) {
	File directory = new File(directoryPath);
	
	if(!directory.exists()) {
		directory.mkdirs();
	}
	
	fileContainer = new FilesystemContainer(directory);
	
	filesTable = new Table();
	filesTable.setSizeFull();
	filesTable.setImmediate(true);
	filesTable.setSelectable(true);
	filesTable.setColumnReorderingAllowed(true);
	filesTable.setColumnCollapsingAllowed(true);
	filesTable.addListener((ValueChangeListener) this);
	updateTable();
	
	contentTable = new Table();
	contentTable.setSizeFull();
	contentTable.setSelectable(true);
	contentTable.setMultiSelect(true);
	
	VerticalLayout tableLayout = new VerticalLayout();
	tableLayout.setSizeFull();
	tableLayout.addComponent(contentTable);
	tableLayout.setExpandRatio(contentTable, 1f);
	
	deleteButton = new Button(Constants.uiDelete);
	deleteButton.setWidth("100%");
	deleteButton.setEnabled(false);
	deleteButton.addListener((ClickListener) this);
	
	downloadButton = new Button(Constants.uiDownloadFile);
	downloadButton.setWidth("100%");
	downloadButton.setEnabled(false);
	downloadButton.addListener((ClickListener) this);
	
	VerticalLayout buttonsLayout = new VerticalLayout();
	buttonsLayout.setWidth("100px");
	buttonsLayout.setSpacing(true);
	
	if(showDeleteButton) {
		buttonsLayout.addComponent(deleteButton);
	}
	
	if(showDownloadButton) {
		buttonsLayout.addComponent(downloadButton);
	}
	
	VerticalLayout firstLayout = new VerticalLayout();
	firstLayout.setSizeFull();
	firstLayout.setMargin(true);
	firstLayout.addComponent(filesTable);
	firstLayout.setExpandRatio(filesTable, 1f);
	
	HorizontalLayout secondLayout = new HorizontalLayout();
	secondLayout.setSizeFull();
	secondLayout.setMargin(true);
	secondLayout.setSpacing(true);
	secondLayout.addComponent(tableLayout);
	secondLayout.addComponent(buttonsLayout);
	secondLayout.setExpandRatio(tableLayout, 1f);
	
	HorizontalSplitPanel panel = new HorizontalSplitPanel();
	panel.setSplitPosition(40);
	panel.setFirstComponent(firstLayout);
	panel.setSecondComponent(secondLayout);
	
	setCompositionRoot(panel);
}
 
开发者ID:alejandro-du,项目名称:enterprise-app,代码行数:72,代码来源:FilesViewerComponent.java

示例14: createLayout

import com.vaadin.ui.HorizontalSplitPanel; //导入方法依赖的package包/类
private void createLayout() {
	setSizeFull();

	buildComponent = new BuildComponent(builder, user, settings);

	initMenuBar();

	layout.addComponent(menu);
	menu.setWidth("100%");

	split = new HorizontalSplitPanel();
	split.setSizeFull();
	layout.addComponent(split);
	layout.setExpandRatio(split, 1);

	sideBar = new VerticalLayout();
	sideBar.setMargin(true);
	split.setFirstComponent(sideBar);

	sideBar.addComponent(componentTree);
	sideBar.addComponent(buildComponent);
	//adds delpoy component to view
	if (settings.paasDeployTurnedOn){
		sideBar.addComponent(new DeployComponent(project, settings,user));
	}
	
	sideBar.addComponent(new JettyComponent(project, user));

	ChatBox cb = new ChatBox(project.getChat());
	cb.setUser(new ChatUser(user.getUserId(), user.getName(), "user1"));
	cb.setWidth("100%");
	cb.setShowSendButton(false);
	sideBar.addComponent(new Panel("Chat", cb));

	split.setSplitPosition(20.0f);

	setActiveFile((ProjectFile) project.getProjectItem("App.java"));

	//adds new menuitem (that does not do anything)
	/*if (settings.easiCloudsFeaturesTurnedOn){
		MenuItem root = this.menu.addItem("Deploy to...",null);
		MenuItem item = root.addItem("Jetty", null);
		item.setCheckable(true);
		item.setChecked(true);
		item = root.addItem("Gae", null);
		item.setCheckable(true);
		item.setChecked(false);
	}*/
	
}
 
开发者ID:ahn,项目名称:mideaas,代码行数:51,代码来源:MideaasEditor.java


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