/** @param parent the parent composite */ private void createAutToolKit(Composite parent) { Composite leftComposite = createComposite(parent, NUM_COLUMNS_1, GridData.BEGINNING, false); Composite rightComposite = createComposite(parent, NUM_COLUMNS_2, GridData.FILL, true); createLabel(leftComposite, Messages.ProjectPropertyPageAutToolKitLabel); m_projectToolkitCombo = createToolkitCombo(rightComposite); m_projectToolkitCombo.setSelectedObject(getProject().getToolkit()); GridData textGridData = new GridData(); textGridData.grabExcessHorizontalSpace = true; textGridData.horizontalAlignment = GridData.FILL; m_projectToolkitCombo.setLayoutData(textGridData); Label l = createLabel(rightComposite, StringConstants.EMPTY); GridData txtGridData = new GridData(); txtGridData.grabExcessHorizontalSpace = true; txtGridData.horizontalAlignment = GridData.FILL; l.setLayoutData(txtGridData); }
/** Refreshes the m_autToolkitCombo. */ private void refreshAutToolkitCombo() { final Composite parent = m_projectToolkitCombo.getParent(); final DirectCombo<String> tmpCombo = createToolkitCombo(parent); m_projectToolkitCombo.setItems(tmpCombo.getValues(), Arrays.asList(tmpCombo.getItems())); tmpCombo.dispose(); m_projectToolkitCombo.setSelectedObject(getProject().getToolkit()); }
/** Adds necessary listeners. */ private void addListener() { m_projectNameTextField.addModifyListener(m_modifyListener); m_projectToolkitCombo.addSelectionListener(m_toolkitComboListener); }