Focus-TextArea-On-AddNewWindow
Signed-off-by: venu1278 <venugopal.boodidadinne@in.bosch.com>
This commit is contained in:
@@ -234,12 +234,13 @@ public class SoftwareModuleAddUpdateWindow implements Serializable {
|
|||||||
mainLayout.addComponent(hLayout);
|
mainLayout.addComponent(hLayout);
|
||||||
mainLayout.setComponentAlignment(hLayout, Alignment.MIDDLE_LEFT);
|
mainLayout.setComponentAlignment(hLayout, Alignment.MIDDLE_LEFT);
|
||||||
mainLayout.addComponents(nameTextField, versionTextField, vendorTextField, descTextArea, buttonsLayout);
|
mainLayout.addComponents(nameTextField, versionTextField, vendorTextField, descTextArea, buttonsLayout);
|
||||||
|
|
||||||
/* add main layout to the window */
|
/* add main layout to the window */
|
||||||
window = SPUIComponentProvider.getWindow(i18n.get("upload.caption.add.new.swmodule"), null,
|
window = SPUIComponentProvider.getWindow(i18n.get("upload.caption.add.new.swmodule"), null,
|
||||||
SPUIDefinitions.CREATE_UPDATE_WINDOW);
|
SPUIDefinitions.CREATE_UPDATE_WINDOW);
|
||||||
window.setContent(mainLayout);
|
window.setContent(mainLayout);
|
||||||
window.setModal(true);
|
window.setModal(true);
|
||||||
|
nameTextField.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addDescriptionTextChangeListener() {
|
private void addDescriptionTextChangeListener() {
|
||||||
|
|||||||
@@ -257,6 +257,7 @@ public class CreateUpdateSoftwareTypeLayout extends CustomComponent implements C
|
|||||||
mainLayout = new HorizontalLayout();
|
mainLayout = new HorizontalLayout();
|
||||||
mainLayout.addComponent(fieldButtonLayout);
|
mainLayout.addComponent(fieldButtonLayout);
|
||||||
setCompositionRoot(mainLayout);
|
setCompositionRoot(mainLayout);
|
||||||
|
typeName.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addListeners() {
|
private void addListeners() {
|
||||||
|
|||||||
@@ -284,7 +284,7 @@ public class CreateUpdateDistSetTypeLayout extends CustomComponent implements Co
|
|||||||
|
|
||||||
mainLayout.addComponent(fieldLayout);
|
mainLayout.addComponent(fieldLayout);
|
||||||
mainLayout.addComponent(twinTableLayout);
|
mainLayout.addComponent(twinTableLayout);
|
||||||
|
|
||||||
colorLayout = new HorizontalLayout();
|
colorLayout = new HorizontalLayout();
|
||||||
sliderLayout = new VerticalLayout();
|
sliderLayout = new VerticalLayout();
|
||||||
final HorizontalLayout chooseColorLayout = new HorizontalLayout();
|
final HorizontalLayout chooseColorLayout = new HorizontalLayout();
|
||||||
@@ -299,6 +299,7 @@ public class CreateUpdateDistSetTypeLayout extends CustomComponent implements Co
|
|||||||
mainWindowLayout.addComponent(colorLayout);
|
mainWindowLayout.addComponent(colorLayout);
|
||||||
mainWindowLayout.addComponent(buttonLayout);
|
mainWindowLayout.addComponent(buttonLayout);
|
||||||
setCompositionRoot(mainWindowLayout);
|
setCompositionRoot(mainWindowLayout);
|
||||||
|
typeName.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
private HorizontalLayout createTwinColumnLayout() {
|
private HorizontalLayout createTwinColumnLayout() {
|
||||||
|
|||||||
@@ -145,11 +145,12 @@ public class DistributionAddUpdateWindowLayout extends VerticalLayout {
|
|||||||
setSizeUndefined();
|
setSizeUndefined();
|
||||||
addComponents(madatoryLabel, distsetTypeNameComboBox, distNameTextField, distVersionTextField, descTextArea,
|
addComponents(madatoryLabel, distsetTypeNameComboBox, distNameTextField, distVersionTextField, descTextArea,
|
||||||
reqMigStepCheckbox);
|
reqMigStepCheckbox);
|
||||||
|
|
||||||
addComponent(buttonsLayout);
|
addComponent(buttonsLayout);
|
||||||
setComponentAlignment(madatoryLabel, Alignment.MIDDLE_LEFT);
|
setComponentAlignment(madatoryLabel, Alignment.MIDDLE_LEFT);
|
||||||
|
distNameTextField.focus();
|
||||||
}
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create required UI components.
|
* Create required UI components.
|
||||||
|
|||||||
@@ -171,7 +171,7 @@ public abstract class CreateUpdateTagLayout extends CustomComponent implements C
|
|||||||
tagName = SPUIComponentProvider.getTextField("", ValoTheme.TEXTFIELD_TINY + " " + SPUIDefinitions.TAG_NAME,
|
tagName = SPUIComponentProvider.getTextField("", ValoTheme.TEXTFIELD_TINY + " " + SPUIDefinitions.TAG_NAME,
|
||||||
true, "", i18n.get("textfield.name"), true, SPUILabelDefinitions.TEXT_FIELD_MAX_LENGTH);
|
true, "", i18n.get("textfield.name"), true, SPUILabelDefinitions.TEXT_FIELD_MAX_LENGTH);
|
||||||
tagName.setId(SPUIDefinitions.NEW_TARGET_TAG_NAME);
|
tagName.setId(SPUIDefinitions.NEW_TARGET_TAG_NAME);
|
||||||
|
|
||||||
tagDesc = SPUIComponentProvider.getTextArea("", ValoTheme.TEXTFIELD_TINY + " " + SPUIDefinitions.TAG_DESC,
|
tagDesc = SPUIComponentProvider.getTextArea("", ValoTheme.TEXTFIELD_TINY + " " + SPUIDefinitions.TAG_DESC,
|
||||||
false, "", i18n.get("textfield.description"), SPUILabelDefinitions.TEXT_AREA_MAX_LENGTH);
|
false, "", i18n.get("textfield.description"), SPUILabelDefinitions.TEXT_AREA_MAX_LENGTH);
|
||||||
|
|
||||||
@@ -237,7 +237,8 @@ public abstract class CreateUpdateTagLayout extends CustomComponent implements C
|
|||||||
fieldLayout.addComponent(madatoryLabel);
|
fieldLayout.addComponent(madatoryLabel);
|
||||||
fieldLayout.addComponent(tagName);
|
fieldLayout.addComponent(tagName);
|
||||||
fieldLayout.addComponent(tagDesc);
|
fieldLayout.addComponent(tagDesc);
|
||||||
|
|
||||||
|
|
||||||
final HorizontalLayout colorLabelLayout = new HorizontalLayout();
|
final HorizontalLayout colorLabelLayout = new HorizontalLayout();
|
||||||
colorLabelLayout.addComponents(colorLabel, tagColorPreviewBtn);
|
colorLabelLayout.addComponents(colorLabel, tagColorPreviewBtn);
|
||||||
fieldLayout.addComponent(colorLabelLayout);
|
fieldLayout.addComponent(colorLabelLayout);
|
||||||
@@ -257,8 +258,8 @@ public abstract class CreateUpdateTagLayout extends CustomComponent implements C
|
|||||||
|
|
||||||
mainLayout = new HorizontalLayout();
|
mainLayout = new HorizontalLayout();
|
||||||
mainLayout.addComponent(fieldButtonLayout);
|
mainLayout.addComponent(fieldButtonLayout);
|
||||||
|
|
||||||
setCompositionRoot(mainLayout);
|
setCompositionRoot(mainLayout);
|
||||||
|
tagName.focus();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -152,7 +152,7 @@ public class TargetAddUpdateWindowLayout extends CustomComponent {
|
|||||||
madatoryLabel.setVisible(Boolean.FALSE);
|
madatoryLabel.setVisible(Boolean.FALSE);
|
||||||
}
|
}
|
||||||
mainLayout.addComponents(madatoryLabel, controllerIDTextField, nameTextField, descTextArea, buttonsLayout);
|
mainLayout.addComponents(madatoryLabel, controllerIDTextField, nameTextField, descTextArea, buttonsLayout);
|
||||||
|
nameTextField.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addListeners() {
|
private void addListeners() {
|
||||||
|
|||||||
@@ -209,6 +209,7 @@ public class AddUpdateRolloutWindowLayout extends CustomComponent {
|
|||||||
actionTypeOptionGroupLayout, linkToHelp, getSaveDiscardButtonLayout());
|
actionTypeOptionGroupLayout, linkToHelp, getSaveDiscardButtonLayout());
|
||||||
mainLayout.setComponentAlignment(linkToHelp, Alignment.BOTTOM_RIGHT);
|
mainLayout.setComponentAlignment(linkToHelp, Alignment.BOTTOM_RIGHT);
|
||||||
setCompositionRoot(mainLayout);
|
setCompositionRoot(mainLayout);
|
||||||
|
rolloutName.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
private HorizontalLayout getGroupDetailsLayout() {
|
private HorizontalLayout getGroupDetailsLayout() {
|
||||||
|
|||||||
Reference in New Issue
Block a user