use of com.vaadin.ui.GridLayout in project Activiti by Activiti.
the class HistoricTaskDetailPanel method initSubTaskGrid.
protected void initSubTaskGrid() {
subTaskGrid = new GridLayout();
subTaskGrid.setColumns(2);
subTasksLayout.addComponent(subTaskGrid);
}
use of com.vaadin.ui.GridLayout in project Activiti by Activiti.
the class NewModelPopupWindow method addFields.
protected void addFields() {
formLayout = new GridLayout(2, 3);
formLayout.setSpacing(true);
formLayout.addComponent(new Label(i18nManager.getMessage(Messages.TASK_NAME)));
nameTextField = new TextField();
nameTextField.setWidth(25, Sizeable.UNITS_EM);
nameTextField.focus();
formLayout.addComponent(nameTextField);
formLayout.addComponent(new Label(i18nManager.getMessage(Messages.TASK_DESCRIPTION)));
descriptionTextArea = new TextArea();
descriptionTextArea.setRows(8);
descriptionTextArea.setWidth(25, Sizeable.UNITS_EM);
descriptionTextArea.addStyleName(ExplorerLayout.STYLE_TEXTAREA_NO_RESIZE);
formLayout.addComponent(descriptionTextArea);
Label editorLabel = new Label(i18nManager.getMessage(Messages.PROCESS_EDITOR_CHOICE));
formLayout.addComponent(editorLabel);
formLayout.setComponentAlignment(editorLabel, Alignment.MIDDLE_LEFT);
selectEditorComponent = new SelectEditorComponent();
formLayout.addComponent(selectEditorComponent);
addComponent(formLayout);
// Some empty space
Label emptySpace = new Label(" ", Label.CONTENT_XHTML);
addComponent(emptySpace);
}
use of com.vaadin.ui.GridLayout in project Activiti by Activiti.
the class TabbedSelectionWindow method initComponentLayout.
protected void initComponentLayout() {
selectedComponentLayout = new GridLayout(1, 2);
selectedComponentLayout.setSizeFull();
selectedComponentLayout.setMargin(true);
selectedComponentLayout.setSpacing(true);
selectedComponentLayout.addStyleName(ExplorerLayout.STYLE_RELATED_CONTENT_CREATE_DETAIL);
windowLayout.addComponent(selectedComponentLayout);
windowLayout.setExpandRatio(selectedComponentLayout, 1.0f);
selectedComponentLayout.setRowExpandRatio(0, 1.0f);
selectedComponentLayout.setColumnExpandRatio(0, 1.0f);
}
use of com.vaadin.ui.GridLayout in project Activiti by Activiti.
the class GroupDetailPanel method initGroupProperties.
protected void initGroupProperties() {
detailsGrid = new GridLayout(2, 3);
detailsGrid.setSpacing(true);
detailLayout.setMargin(true, true, true, false);
detailLayout.addComponent(detailsGrid);
// id
Label idLabel = new Label(i18nManager.getMessage(Messages.GROUP_ID) + ": ");
idLabel.addStyleName(ExplorerLayout.STYLE_LABEL_BOLD);
detailsGrid.addComponent(idLabel);
Label idValueLabel = new Label(group.getId());
detailsGrid.addComponent(idValueLabel);
// name
Label nameLabel = new Label(i18nManager.getMessage(Messages.GROUP_NAME) + ": ");
nameLabel.addStyleName(ExplorerLayout.STYLE_LABEL_BOLD);
detailsGrid.addComponent(nameLabel);
if (!editingDetails) {
Label nameValueLabel = new Label(group.getName());
detailsGrid.addComponent(nameValueLabel);
} else {
nameTextField = new TextField(null, group.getName());
detailsGrid.addComponent(nameTextField);
}
// Type
Label typeLabel = new Label(i18nManager.getMessage(Messages.GROUP_TYPE) + ": ");
typeLabel.addStyleName(ExplorerLayout.STYLE_LABEL_BOLD);
detailsGrid.addComponent(typeLabel);
if (!editingDetails) {
Label typeValueLabel = new Label(group.getType());
detailsGrid.addComponent(typeValueLabel);
} else {
typeCombobox = new ComboBox(null, Arrays.asList("assignment", "security-role"));
typeCombobox.setNullSelectionAllowed(false);
typeCombobox.setInvalidAllowed(false);
typeCombobox.select(group.getType());
detailsGrid.addComponent(typeCombobox);
}
}
use of com.vaadin.ui.GridLayout in project Activiti by Activiti.
the class UserDetailPanel method loadUserDetails.
protected void loadUserDetails() {
// Grid of details
GridLayout detailGrid = new GridLayout();
detailGrid.setColumns(2);
detailGrid.setSpacing(true);
detailGrid.setMargin(true, true, false, true);
userDetailsLayout.addComponent(detailGrid);
// Details
// details are non-editable
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_ID), new Label(user.getId()));
if (!editingDetails) {
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_FIRSTNAME), new Label(user.getFirstName()));
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_LASTNAME), new Label(user.getLastName()));
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_EMAIL), new Label(user.getEmail()));
} else {
firstNameField = new TextField(null, user.getFirstName() != null ? user.getFirstName() : "");
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_FIRSTNAME), firstNameField);
firstNameField.focus();
lastNameField = new TextField(null, user.getLastName() != null ? user.getLastName() : "");
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_LASTNAME), lastNameField);
emailField = new TextField(null, user.getEmail() != null ? user.getEmail() : "");
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_EMAIL), emailField);
passwordField = new PasswordField();
Label cautionLabel = new Label(i18nManager.getMessage(Messages.USER_RESET_PASSWORD));
cautionLabel.addStyleName(Reindeer.LABEL_SMALL);
HorizontalLayout passwordLayout = new HorizontalLayout();
passwordLayout.setSpacing(true);
passwordLayout.addComponent(passwordField);
passwordLayout.addComponent(cautionLabel);
passwordLayout.setComponentAlignment(cautionLabel, Alignment.MIDDLE_LEFT);
addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_PASSWORD), passwordLayout);
}
}
Aggregations