issue_id
int64 2.04k
425k
| title
stringlengths 9
251
| body
stringlengths 4
32.8k
⌀ | status
stringclasses 6
values | after_fix_sha
stringlengths 7
7
| project_name
stringclasses 6
values | repo_url
stringclasses 6
values | repo_name
stringclasses 6
values | language
stringclasses 1
value | issue_url
null | before_fix_sha
null | pull_url
null | commit_datetime
timestamp[us, tz=UTC] | report_datetime
timestamp[us, tz=UTC] | updated_file
stringlengths 23
187
| chunk_content
stringlengths 1
22k
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
import org.eclipse.jdt.internal.ui.dialogs.StatusUtil;
import org.eclipse.jdt.internal.ui.util.SWTUtil;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IStringButtonAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.SelectionButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridLayout;
public class VariableCreationDialog extends StatusDialog {
private IDialogSettings fDialogSettings;
private StringDialogField fNameField;
private StatusInfo fNameStatus;
private StringButtonDialogField fPathField;
private StatusInfo fPathStatus;
private SelectionButtonDialogField fDirButton;
private CPVariableElement fElement;
private List fExistingNames;
public VariableCreationDialog(Shell parent, CPVariableElement element, List existingNames) {
super(parent);
if (element == null) {
setTitle(NewWizardMessages.getString("VariableCreationDialog.titlenew"));
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
} else {
setTitle(NewWizardMessages.getString("VariableCreationDialog.titleedit"));
}
fDialogSettings= JavaPlugin.getDefault().getDialogSettings();
fElement= element;
fNameStatus= new StatusInfo();
fPathStatus= new StatusInfo();
NewVariableAdapter adapter= new NewVariableAdapter();
fNameField= new StringDialogField();
fNameField.setDialogFieldListener(adapter);
fNameField.setLabelText(NewWizardMessages.getString("VariableCreationDialog.name.label"));
fPathField= new StringButtonDialogField(adapter);
fPathField.setDialogFieldListener(adapter);
fPathField.setLabelText(NewWizardMessages.getString("VariableCreationDialog.path.label"));
fPathField.setButtonLabel(NewWizardMessages.getString("VariableCreationDialog.path.file.button"));
fDirButton= new SelectionButtonDialogField(SWT.PUSH);
fDirButton.setDialogFieldListener(adapter);
fDirButton.setLabelText(NewWizardMessages.getString("VariableCreationDialog.path.dir.button"));
fExistingNames= existingNames;
if (element != null) {
fNameField.setText(element.getName());
fPathField.setText(element.getPath().toString());
fExistingNames.remove(element.getName());
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
} else {
fNameField.setText("");
fPathField.setText("");
}
}
/*
* @see Windows#configureShell
*/
protected void configureShell(Shell newShell) {
super.configureShell(newShell);
WorkbenchHelp.setHelp(newShell, new Object[] { IJavaHelpContextIds.VARIABLE_CREATION_DIALOG });
}
public CPVariableElement getClasspathElement() {
return new CPVariableElement(fNameField.getText(), new Path(fPathField.getText()), false);
}
/*
* @see Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
*/
protected Control createDialogArea(Composite parent) {
Composite composite= (Composite)super.createDialogArea(parent);
Composite inner= new Composite(composite, SWT.NONE);
MGridLayout layout= new MGridLayout();
layout.minimumWidth= SWTUtil.convertWidthInCharsToPixels(80, composite);
layout.marginWidth= 0;
layout.numColumns= 3;
inner.setLayout(layout);
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
fNameField.doFillIntoGrid(inner, 2);
DialogField.createEmptySpace(inner, 1);
fPathField.doFillIntoGrid(inner, 3);
DialogField.createEmptySpace(inner, 2);
fDirButton.doFillIntoGrid(inner, 1);
DialogField focusField= (fElement == null) ? fNameField : fPathField;
focusField.postSetFocusOnDialogField(parent.getDisplay());
return composite;
}
private class NewVariableAdapter implements IDialogFieldListener, IStringButtonAdapter {
public void dialogFieldChanged(DialogField field) {
doFieldUpdated(field);
}
public void changeControlPressed(DialogField field) {
doChangeControlPressed(field);
}
}
private void doChangeControlPressed(DialogField field) {
if (field == fPathField) {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
IPath path= chooseExtJarFile();
if (path != null) {
fPathField.setText(path.toString());
}
}
}
private void doFieldUpdated(DialogField field) {
if (field == fNameField) {
fNameStatus= nameUpdated();
} else if (field == fPathField) {
fPathStatus= pathUpdated();
} else if (field == fDirButton) {
IPath path= chooseExtDirectory();
if (path != null) {
fPathField.setText(path.toString());
}
}
updateStatus(StatusUtil.getMoreSevere(fPathStatus, fNameStatus));
}
private StatusInfo nameUpdated() {
StatusInfo status= new StatusInfo();
String name= fNameField.getText();
if (name.length() == 0) {
status.setError(NewWizardMessages.getString("VariableCreationDialog.error.entername"));
return status;
}
IStatus val= JavaConventions.validateIdentifier(name);
if (val.matches(IStatus.ERROR)) {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
status.setError(NewWizardMessages.getFormattedString("VariableCreationDialog.error.invalidname", val.getMessage()));
} else if (nameConflict(name)) {
status.setError(NewWizardMessages.getString("VariableCreationDialog.error.nameexists"));
}
return status;
}
private boolean nameConflict(String name) {
if (fElement != null && fElement.getName().equals(name)) {
return false;
}
for (int i= 0; i < fExistingNames.size(); i++) {
CPVariableElement elem= (CPVariableElement)fExistingNames.get(i);
if (name.equals(elem.getName())){
return true;
}
}
return false;
}
private StatusInfo pathUpdated() {
StatusInfo status= new StatusInfo();
String path= fPathField.getText();
if (path.length() > 0) {
if (!Path.ROOT.isValidPath(path)) {
status.setError(NewWizardMessages.getString("VariableCreationDialogerror.invalidpath"));
} else if (!new File(path).exists()) {
status.setWarning(NewWizardMessages.getString("VariableCreationDialog.warning.pathnotexists"));
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
}
}
return status;
}
private String getInitPath() {
String initPath= fPathField.getText();
if (initPath.length() == 0) {
initPath= fDialogSettings.get(IUIConstants.DIALOGSTORE_LASTEXTJAR);
if (initPath == null) {
initPath= "";
}
} else {
IPath entryPath= new Path(initPath);
if (ArchiveFileFilter.isArchivePath(entryPath)) {
entryPath.removeLastSegments(1);
}
initPath= entryPath.toOSString();
}
return initPath;
}
/*
* Open a dialog to choose a jar from the file system
*/
private IPath chooseExtJarFile() {
String initPath= getInitPath();
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableCreationDialog.java
|
FileDialog dialog= new FileDialog(getShell());
dialog.setText(NewWizardMessages.getString("VariableCreationDialog.extjardialog.text"));
dialog.setFilterExtensions(new String[] {"*.jar;*.zip"});
dialog.setFilterPath(initPath);
String res= dialog.open();
if (res != null) {
fDialogSettings.put(IUIConstants.DIALOGSTORE_LASTEXTJAR, dialog.getFilterPath());
return new Path(res).makeAbsolute();
}
return null;
}
private IPath chooseExtDirectory() {
String initPath= getInitPath();
DirectoryDialog dialog= new DirectoryDialog(getShell());
dialog.setText(NewWizardMessages.getString("VariableCreationDialog.extdirdialog.text"));
dialog.setMessage(NewWizardMessages.getString("VariableCreationDialog.extdirdialog.message"));
dialog.setFilterPath(initPath);
String res= dialog.open();
if (res != null) {
fDialogSettings.put(IUIConstants.DIALOGSTORE_LASTEXTJAR, dialog.getFilterPath());
return new Path(res);
}
return null;
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.buildpaths;
import java.util.List;
import org.eclipse.swt.SWT;
import org.eclipse.swt.custom.CLabel;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IStatus;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
import org.eclipse.core.runtime.Path;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
import org.eclipse.jdt.internal.ui.dialogs.StatusUtil;
import org.eclipse.jdt.internal.ui.util.SWTUtil;
import org.eclipse.jdt.internal.ui.wizards.IStatusChangeListener;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IStringButtonAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridData;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridLayout;
public class VariableSelectionBlock {
private List fExistingPaths;
private StringButtonDialogField fVariableField;
private StringButtonDialogField fExtensionField;
private CLabel fFullPath;
private IStatus fVariableStatus;
private IStatus fExistsStatus;
private IStatus fExtensionStatus;
private String fVariable;
private IStatusChangeListener fContext;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
private boolean fIsEmptyAllowed;
private String fLastVariableSelection;
/**
* Constructor for VariableSelectionBlock
*/
public VariableSelectionBlock(IStatusChangeListener context, List existingPaths, IPath varPath, String lastVarSelection, boolean emptyAllowed) {
fContext= context;
fExistingPaths= existingPaths;
fIsEmptyAllowed= emptyAllowed;
fLastVariableSelection= lastVarSelection;
fVariableStatus= new StatusInfo();
fExistsStatus= new StatusInfo();
VariableSelectionAdapter adapter= new VariableSelectionAdapter();
fVariableField= new StringButtonDialogField(adapter);
fVariableField.setDialogFieldListener(adapter);
fVariableField.setLabelText(NewWizardMessages.getString("VariableSelectionBlock.variable.label"));
fVariableField.setButtonLabel(NewWizardMessages.getString("VariableSelectionBlock.variable.button"));
fExtensionField= new StringButtonDialogField(adapter);
fExtensionField.setDialogFieldListener(adapter);
fExtensionField.setLabelText(NewWizardMessages.getString("VariableSelectionBlock.extension.label"));
fExtensionField.setButtonLabel(NewWizardMessages.getString("VariableSelectionBlock.extension.button"));
if (varPath != null) {
fVariableField.setText(varPath.segment(0));
fExtensionField.setText(varPath.removeFirstSegments(1).toString());
} else {
fVariableField.setText("");
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
fExtensionField.setText("");
}
updateFullTextField();
}
public IPath getVariablePath() {
if (fVariable != null) {
return new Path(fVariable).append(fExtensionField.getText());
}
return null;
}
public IPath getResolvedPath() {
if (fVariable != null) {
IPath entryPath= JavaCore.getClasspathVariable(fVariable);
if (entryPath != null) {
return entryPath.append(fExtensionField.getText());
}
}
return null;
}
public void doFillIntoGrid(Composite inner, int nColumns) {
fVariableField.doFillIntoGrid(inner, nColumns);
fExtensionField.doFillIntoGrid(inner, nColumns);
Label label= new Label(inner, SWT.LEFT);
label.setLayoutData(new MGridData());
label.setText(NewWizardMessages.getString("VariableSelectionBlock.fullpath.label"));
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
fFullPath= new CLabel(inner, SWT.NONE);
fFullPath.setLayoutData(new MGridData(MGridData.HORIZONTAL_ALIGN_FILL));
DialogField.createEmptySpace(inner, nColumns - 2);
updateFullTextField();
}
public void setFocus(Display display) {
fVariableField.postSetFocusOnDialogField(display);
}
public Control createControl(Composite parent) {
Composite inner= new Composite(parent, SWT.NONE);
MGridLayout layout= new MGridLayout();
layout.minimumWidth= SWTUtil.convertWidthInCharsToPixels(80, inner);
layout.marginHeight= 0;
layout.marginWidth= 0;
layout.numColumns= 3;
inner.setLayout(layout);
doFillIntoGrid(inner, 3);
setFocus(parent.getDisplay());
return inner;
}
private class VariableSelectionAdapter implements IDialogFieldListener, IStringButtonAdapter {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
public void dialogFieldChanged(DialogField field) {
doFieldUpdated(field);
}
public void changeControlPressed(DialogField field) {
doChangeControlPressed(field);
}
}
private void doChangeControlPressed(DialogField field) {
if (field == fVariableField) {
String variable= chooseVariable();
if (variable != null) {
fVariableField.setText(variable);
}
} else if (field == fExtensionField) {
IPath filePath= chooseExtJar();
if (filePath != null) {
fExtensionField.setText(filePath.toString());
}
}
}
private void doFieldUpdated(DialogField field) {
if (field == fVariableField) {
fVariableStatus= variableUpdated();
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
} else if (field == fExtensionField) {
fExtensionStatus= extensionUpdated();
}
fExistsStatus= getExistsStatus();
updateFullTextField();
fContext.statusChanged(StatusUtil.getMostSevere(new IStatus[] { fVariableStatus, fExtensionStatus, fExistsStatus }));
}
private IStatus variableUpdated() {
fVariable= null;
StatusInfo status= new StatusInfo();
String name= fVariableField.getText();
if (name.length() == 0) {
if (!fIsEmptyAllowed) {
status.setError(NewWizardMessages.getString("VariableSelectionBlock.error.entername"));
} else {
fVariable= "";
}
} else if (JavaCore.getClasspathVariable(name) == null) {
status.setError(NewWizardMessages.getString("VariableSelectionBlock.error.namenotexists"));
} else {
fVariable= name;
}
fExtensionField.enableButton(fVariable != null);
return status;
}
private IStatus extensionUpdated() {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
StatusInfo status= new StatusInfo();
String extension= fExtensionField.getText();
if (extension.length() > 0 && !Path.ROOT.isValidPath(extension)) {
status.setError(NewWizardMessages.getString("VariableSelectionBlock.error.invalidextension"));
}
return status;
}
private IStatus getExistsStatus() {
StatusInfo status= new StatusInfo();
IPath path= getResolvedPath();
if (path != null) {
if (findPath(path)) {
status.setError(NewWizardMessages.getString("VariableSelectionBlock.error.pathexists"));
} else if (!path.toFile().isFile()) {
status.setWarning(NewWizardMessages.getString("VariableSelectionBlock.warning.pathnotexists"));
}
} else {
status.setWarning(NewWizardMessages.getString("VariableSelectionBlock.warning.pathnotexists"));
}
return status;
}
private boolean findPath(IPath path) {
for (int i= fExistingPaths.size() -1; i >=0; i--) {
IPath curr= (IPath) fExistingPaths.get(i);
if (curr.equals(path)) {
return true;
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
return false;
}
private void updateFullTextField() {
if (fFullPath != null && !fFullPath.isDisposed()) {
IPath resolvedPath= getResolvedPath();
if (resolvedPath != null) {
fFullPath.setText(resolvedPath.toOSString());
} else {
fFullPath.setText("");
}
}
}
private Shell getShell() {
if (fFullPath != null) {
return fFullPath.getShell();
}
return JavaPlugin.getActiveWorkbenchShell();
}
private IPath chooseExtJar() {
String lastUsedPath= "";
IPath entryPath= getResolvedPath();
if (entryPath != null) {
if (ArchiveFileFilter.isArchivePath(entryPath)) {
lastUsedPath= entryPath.removeLastSegments(1).toOSString();
} else {
lastUsedPath= entryPath.toOSString();
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/VariableSelectionBlock.java
|
FileDialog dialog= new FileDialog(getShell(), SWT.SINGLE);
dialog.setFilterExtensions(new String[] {"*.jar;*.zip"});
dialog.setFilterPath(lastUsedPath);
dialog.setText(NewWizardMessages.getString("VariableSelectionBlock.ExtJarDialog.title"));
String res= dialog.open();
if (res == null) {
return null;
}
IPath resPath= new Path(res).makeAbsolute();
IPath varPath= JavaCore.getClasspathVariable(fVariable);
if (!varPath.isPrefixOf(resPath)) {
return new Path(resPath.lastSegment());
} else {
return resPath.removeFirstSegments(varPath.segmentCount()).setDevice(null);
}
}
private String chooseVariable() {
String selecteVariable= (fVariable != null) ? fVariable : fLastVariableSelection;
ChooseVariableDialog dialog= new ChooseVariableDialog(getShell(), selecteVariable);
if (dialog.open() == dialog.OK) {
return dialog.getSelectedVariable();
}
return null;
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.dialogfields;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Table;
import org.eclipse.jface.util.Assert;
import org.eclipse.jface.viewers.CheckStateChangedEvent;
import org.eclipse.jface.viewers.CheckboxTableViewer;
import org.eclipse.jface.viewers.ICheckStateListener;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.TableViewer;
/**
* A list with checkboxes and a button bat. Typical buttons are 'Check All' and 'Uncheck All'.
* List model is independend of widget creation.
* DialogFields controls are: Label, List and Composite containing buttons.
*/
public class CheckedListDialogField extends ListDialogField {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
private int fCheckAllButtonIndex;
private int fUncheckAllButtonIndex;
private List fCheckElements;
public CheckedListDialogField(IListAdapter adapter, String[] customButtonLabels, ILabelProvider lprovider) {
super(adapter, customButtonLabels, lprovider);
fCheckElements= new ArrayList();
fCheckAllButtonIndex= -1;
fUncheckAllButtonIndex= -1;
}
/**
* Sets the index of the 'check' button in the button label array passed in the constructor.
* The behaviour of the button marked as the check button will then be handled internally.
* (enable state, button invocation behaviour)
*/
public void setCheckAllButtonIndex(int checkButtonIndex) {
Assert.isTrue(checkButtonIndex < fButtonLabels.length);
fCheckAllButtonIndex= checkButtonIndex;
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
/**
* Sets the index of the 'uncheck' button in the button label array passed in the constructor.
* The behaviour of the button marked as the uncheck button will then be handled internally.
* (enable state, button invocation behaviour)
*/
public void setUncheckAllButtonIndex(int uncheckButtonIndex) {
Assert.isTrue(uncheckButtonIndex < fButtonLabels.length);
fUncheckAllButtonIndex= uncheckButtonIndex;
}
/*
* @see ListDialogField#createTableViewer
*/
protected TableViewer createTableViewer(Composite parent) {
Table table= new Table(parent, SWT.CHECK + getListStyle());
CheckboxTableViewer tableViewer= new CheckboxTableViewer(table);
tableViewer.addCheckStateListener(new ICheckStateListener() {
public void checkStateChanged(CheckStateChangedEvent e) {
doCheckStateChanged(e);
}
});
return tableViewer;
}
/*
* @see ListDialogField#getListControl
*/
public Control getListControl(Composite parent) {
Control control= super.getListControl(parent);
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
((CheckboxTableViewer)fTable).setCheckedElements(fCheckElements.toArray());
return control;
}
/*
* @see DialogField#dialogFieldChanged
* Hooks in to get element changes to update check model.
*/
public void dialogFieldChanged() {
for (int i= fCheckElements.size() -1; i >= 0; i--) {
if (!fElements.contains(fCheckElements.get(i))) {
fCheckElements.remove(i);
}
}
super.dialogFieldChanged();
}
private void checkStateChanged() {
super.dialogFieldChanged();
}
/**
* Gets the checked elements.
*/
public List getCheckedElements() {
return new ArrayList(fCheckElements);
}
/**
* Returns true if the element is checked.
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
*/
public boolean isChecked(Object obj) {
return fCheckElements.contains(obj);
}
/**
* Sets the checked elements.
*/
public void setCheckedElements(List list) {
fCheckElements= new ArrayList(list);
if (fTable != null) {
((CheckboxTableViewer)fTable).setCheckedElements(list.toArray());
}
checkStateChanged();
}
/**
* Sets the checked state of an element.
*/
public void setChecked(Object object, boolean state) {
setCheckedWithoutUpdate(object, state);
checkStateChanged();
}
/**
* Sets the checked state of an element. no dialog changed listener informed
*/
public void setCheckedWithoutUpdate(Object object, boolean state) {
if (!fCheckElements.contains(object)) {
fCheckElements.add(object);
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
if (fTable != null) {
((CheckboxTableViewer)fTable).setChecked(object, state);
}
}
/**
* Sets the check state of all elements
*/
public void checkAll(boolean state) {
if (state) {
fCheckElements= getElements();
} else {
fCheckElements.clear();
}
if (fTable != null) {
((CheckboxTableViewer)fTable).setAllChecked(state);
}
checkStateChanged();
}
private void doCheckStateChanged(CheckStateChangedEvent e) {
if (e.getChecked()) {
fCheckElements.add(e.getElement());
} else {
fCheckElements.remove(e.getElement());
}
checkStateChanged();
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/CheckedListDialogField.java
|
/*
* @see ListDialogField#getManagedButtonState
*/
protected boolean getManagedButtonState(ISelection sel, int index) {
if (index == fCheckAllButtonIndex) {
return !fElements.isEmpty();
} else if (index == fUncheckAllButtonIndex) {
return !fElements.isEmpty();
}
return super.getManagedButtonState(sel, index);
}
/*
* @see ListDialogField#extraButtonPressed
*/
protected boolean managedButtonPressed(int index) {
if (index == fCheckAllButtonIndex) {
checkAll(true);
} else if (index == fUncheckAllButtonIndex) {
checkAll(false);
} else {
return super.managedButtonPressed(index);
}
return true;
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.dialogfields;
import org.eclipse.swt.SWT;
import org.eclipse.swt.graphics.GC;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Label;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.util.Assert;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridData;
/**
* Base class of all dialog fields.
* Dialog fields manage controls together with the model, independed
* from the creation time of the widgets.
* - support for automated layouting.
* - enable / disable, set focus a concept of the base class.
*
* DialogField have a label.
*/
public class DialogField {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
private Label fLabel;
protected String fLabelText;
private IDialogFieldListener fDialogFieldListener;
private boolean fEnabled;
public DialogField() {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
fEnabled= true;
fLabel= null;
fLabelText= "";
}
/**
* Sets the label of the dialog field.
*/
public void setLabelText(String labeltext) {
fLabelText= labeltext;
}
/**
* Defines the listener for this dialog field.
*/
public final void setDialogFieldListener(IDialogFieldListener listener) {
fDialogFieldListener= listener;
}
/**
* Programatical invocation of a dialog field change.
*/
public void dialogFieldChanged() {
if (fDialogFieldListener != null) {
fDialogFieldListener.dialogFieldChanged(this);
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
/**
* Tries to set the focus to the dialog field.
* Returns <code>true</code> if the dialog field can take focus.
* To be reimplemented by dialog field implementors.
*/
public boolean setFocus() {
return false;
}
/**
* Posts <code>setFocus</code> to the display event queue.
*/
public void postSetFocusOnDialogField(Display display) {
if (display != null) {
display.asyncExec(
new Runnable() {
public void run() {
setFocus();
}
}
);
}
}
/**
* Creates all controls of the dialog field and fills it to a composite.
* The composite is assumed to have <code>MGridLayout</code> as
* layout.
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
* The dialog field will adjust its controls' spans to the number of columns given.
* To be reimplemented by dialog field implementors.
*/
public Control[] doFillIntoGrid(Composite parent, int nColumns) {
assertEnoughColumns(nColumns);
Label label= getLabelControl(parent);
label.setLayoutData(gridDataForLabel(nColumns));
return new Control[] { label };
}
/**
* Returns the number of columns of the dialog field.
* To be reimplemented by dialog field implementors.
*/
public int getNumberOfControls() {
return 1;
}
protected static MGridData gridDataForLabel(int span) {
MGridData gd= new MGridData();
gd.horizontalSpan= span;
return gd;
}
/**
* Creates or returns the created label widget.
* @param parent The parent composite or <code>null</code> if the widget has
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
* already been created.
*/
public Label getLabelControl(Composite parent) {
if (fLabel == null) {
assertCompositeNotNull(parent);
fLabel= new Label(parent, SWT.LEFT);
fLabel.setFont(parent.getFont());
fLabel.setEnabled(fEnabled);
if (fLabelText != null && !"".equals(fLabelText)) {
fLabel.setText(fLabelText);
} else {
fLabel.setText(".");
fLabel.setVisible(false);
}
}
return fLabel;
}
/**
* Creates a spacer control.
* @param parent The parent composite
*/
public static Control createEmptySpace(Composite parent) {
return createEmptySpace(parent, 1);
}
/**
* Creates a spacer control with the given span.
* The composite is assumed to have <code>MGridLayout</code> as
* layout.
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
* @param parent The parent composite
*/
public static Control createEmptySpace(Composite parent, int span) {
Label label= new Label(parent, SWT.LEFT);
MGridData gd= new MGridData();
gd.horizontalAlignment= gd.BEGINNING;
gd.grabExcessHorizontalSpace= false;
gd.horizontalSpan= span;
gd.horizontalIndent= 0;
gd.widthHint= 0;
gd.heightHint= 0;
label.setLayoutData(gd);
return label;
}
/**
* Tests is the control is not <code>null</code> and not disposed.
*/
protected final boolean isOkToUse(Control control) {
return (control != null) && !(control.isDisposed());
}
/**
* Sets the enable state of the dialog field.
*/
public final void setEnabled(boolean enabled) {
if (enabled != fEnabled) {
fEnabled= enabled;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.java
|
updateEnableState();
}
}
/**
* Called when the enable state changed.
* To be extended by dialog field implementors.
*/
protected void updateEnableState() {
if (fLabel != null) {
fLabel.setEnabled(fEnabled);
}
}
/**
* Gets the enable state of the dialog field.
*/
public final boolean isEnabled() {
return fEnabled;
}
protected final void assertCompositeNotNull(Composite comp) {
Assert.isNotNull(comp, "uncreated control requested with composite null");
}
protected final void assertEnoughColumns(int nColumns) {
Assert.isTrue(nColumns >= getNumberOfControls(), "given number of columns is too small");
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/LayoutUtil.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.dialogfields;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridData;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridLayout;
public class LayoutUtil {
/**
* Calculates the number of columns needed by field editors
*/
public static int getNumberOfColumns(DialogField[] editors) {
int nCulumns= 0;
for (int i= 0; i < editors.length; i++) {
nCulumns= Math.max(editors[i].getNumberOfControls(), nCulumns);
}
return nCulumns;
}
/**
* Creates a composite and fills in the given editors.
* @param labelOnTop Defines if the label of all fields should be on top of the fields
*/
public static void doDefaultLayout(Composite parent, DialogField[] editors, boolean labelOnTop) {
doDefaultLayout(parent, editors, labelOnTop, 0, 0, 0, 0);
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/LayoutUtil.java
|
/**
* Creates a composite and fills in the given editors.
* @param labelOnTop Defines if the label of all fields should be on top of the fields
* @param minWidth The minimal width of the composite
* @param minHeight The minimal height of the composite
*/
public static void doDefaultLayout(Composite parent, DialogField[] editors, boolean labelOnTop, int minWidth, int minHeight) {
doDefaultLayout(parent, editors, labelOnTop, minWidth, minHeight, 0, 0);
}
/**
* Creates a composite and fills in the given editors.
* @param labelOnTop Defines if the label of all fields should be on top of the fields
* @param minWidth The minimal width of the composite
* @param minHeight The minimal height of the composite
* @param marginWidth The margin width to be used by the composite
* @param marginHeight The margin height to be used by the composite
*/
public static void doDefaultLayout(Composite parent, DialogField[] editors, boolean labelOnTop, int minWidth, int minHeight, int marginWidth, int marginHeight) {
int nCulumns= getNumberOfColumns(editors);
Control[][] controls= new Control[editors.length][];
for (int i= 0; i < editors.length; i++) {
controls[i]= editors[i].doFillIntoGrid(parent, nCulumns);
}
if (labelOnTop) {
nCulumns--;
modifyLabelSpans(controls, nCulumns);
}
MGridLayout layout= new MGridLayout();
if (marginWidth != SWT.DEFAULT) {
layout.marginWidth= marginWidth;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/LayoutUtil.java
|
}
if (marginHeight != SWT.DEFAULT) {
layout.marginHeight= marginHeight;
}
layout.minimumWidth= minWidth;
layout.minimumHeight= minHeight;
layout.numColumns= nCulumns;
parent.setLayout(layout);
}
private static void modifyLabelSpans(Control[][] controls, int nCulumns) {
for (int i= 0; i < controls.length; i++) {
setHorizontalSpan(controls[i][0], nCulumns);
}
}
/**
* Sets the span of a control. Assumes that MGriddata is used.
*/
public static void setHorizontalSpan(Control control, int span) {
Object ld= control.getLayoutData();
if (ld instanceof MGridData) {
((MGridData)ld).horizontalSpan= span;
} else if (span != 1) {
MGridData gd= new MGridData();
gd.horizontalSpan= span;
control.setLayoutData(gd);
}
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.dialogfields;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Table;
import org.eclipse.swt.widgets.TableColumn;
import org.eclipse.jface.util.Assert;
import org.eclipse.jface.viewers.ColumnWeightData;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ILabelProviderListener;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.ISelectionChangedListener;
import org.eclipse.jface.viewers.IStructuredContentProvider;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.ITableLabelProvider;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.viewers.TableLayout;
import org.eclipse.jface.viewers.TableViewer;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.jface.viewers.ViewerSorter;
import org.eclipse.jdt.internal.ui.util.SWTUtil;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridData;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridLayout;
/**
* A list with a button bar.
* Typical buttons are 'Add', 'Remove', 'Up' and 'Down'.
* List model is independend of widget creation.
* DialogFields controls are: Label, List and Composite containing buttons.
*/
public class ListDialogField extends DialogField {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
protected TableViewer fTable;
protected ILabelProvider fLabelProvider;
protected ListViewerAdapter fListViewerAdapter;
protected List fElements;
protected String[] fButtonLabels;
private Button[] fButtonControls;
private boolean[] fButtonsEnabled;
private int fRemoveButtonIndex;
private int fUpButtonIndex;
private int fDownButtonIndex;
private Label fLastSeparator;
private Table fTableControl;
private Composite fButtonsControl;
private ISelection fSelectionWhenEnabled;
private TableColumn fTableColumn;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
private IListAdapter fListAdapter;
private Object fParentElement;
/**
* Creates the <code>ListDialogField</code>.
* @param adapter A listener for button invocation, selection changes.
* @param buttonLabels The labels of all buttons: <code>null</code> is a valid array entry and
* marks a separator.
* @param lprovider The label provider to render the table entries
*/
public ListDialogField(IListAdapter adapter, String[] buttonLabels, ILabelProvider lprovider) {
super();
fListAdapter= adapter;
fLabelProvider= lprovider;
fListViewerAdapter= new ListViewerAdapter();
fParentElement= this;
fElements= new ArrayList(10);
fButtonLabels= buttonLabels;
if (fButtonLabels != null) {
int nButtons= fButtonLabels.length;
fButtonsEnabled= new boolean[nButtons];
for (int i= 0; i < nButtons; i++) {
fButtonsEnabled[i]= true;
}
}
fTable= null;
fTableControl= null;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
fButtonsControl= null;
fRemoveButtonIndex= -1;
fUpButtonIndex= -1;
fDownButtonIndex= -1;
}
/**
* Sets the index of the 'remove' button in the button label array passed in the constructor.
* The behaviour of the button marked as the 'remove' button will then be handled internally.
* (enable state, button invocation behaviour)
*/
public void setRemoveButtonIndex(int removeButtonIndex) {
Assert.isTrue(removeButtonIndex < fButtonLabels.length);
fRemoveButtonIndex= removeButtonIndex;
}
/**
* Sets the index of the 'up' button in the button label array passed in the constructor.
* The behaviour of the button marked as the 'up' button will then be handled internally.
* (enable state, button invocation behaviour)
*/
public void setUpButtonIndex(int upButtonIndex) {
Assert.isTrue(upButtonIndex < fButtonLabels.length);
fUpButtonIndex= upButtonIndex;
}
/**
* Sets the index of the 'down' button in the button label array passed in the constructor.
* The behaviour of the button marked as the 'down' button will then be handled internally.
* (enable state, button invocation behaviour)
*/
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
public void setDownButtonIndex(int downButtonIndex) {
Assert.isTrue(downButtonIndex < fButtonLabels.length);
fDownButtonIndex= downButtonIndex;
}
private void buttonPressed(int index) {
if (!managedButtonPressed(index)) {
fListAdapter.customButtonPressed(this, index);
}
}
/**
* Checks if the button pressed is handled internally
* @return Returns true if button has been handled.
*/
protected boolean managedButtonPressed(int index) {
if (index == fRemoveButtonIndex) {
remove();
} else if (index == fUpButtonIndex) {
up();
} else if (index == fDownButtonIndex) {
down();
} else {
return false;
}
return true;
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
/*
* @see DialogField#doFillIntoGrid
*/
public Control[] doFillIntoGrid(Composite parent, int nColumns) {
assertEnoughColumns(nColumns);
Label label= getLabelControl(parent);
MGridData gd= gridDataForLabel(1);
gd.verticalAlignment= gd.BEGINNING;
label.setLayoutData(gd);
Control list= getListControl(parent);
gd= new MGridData();
gd.horizontalAlignment= gd.FILL;
gd.grabExcessHorizontalSpace= true;
gd.verticalAlignment= gd.FILL;
gd.grabExcessVerticalSpace= true;
gd.grabColumn= 0;
gd.horizontalSpan= nColumns - 2;
list.setLayoutData(gd);
Composite buttons= getButtonBox(parent);
gd= new MGridData();
gd.horizontalAlignment= gd.FILL;
gd.grabExcessHorizontalSpace= false;
gd.verticalAlignment= gd.FILL;
gd.grabExcessVerticalSpace= false;
gd.horizontalSpan= 1;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
buttons.setLayoutData(gd);
return new Control[] { label, list, buttons };
}
/*
* @see DialogField#getNumberOfControls
*/
public int getNumberOfControls() {
return 3;
}
/**
* Sets the minimal width of the buttons. Must be called after widget creation.
*/
public void setButtonsMinWidth(int minWidth) {
if (fLastSeparator != null) {
((MGridData)fLastSeparator.getLayoutData()).widthHint= minWidth;
}
}
/**
* Returns the list control. When called the first time, the control will be created.
* @param The parent composite when called the first time, or <code>null</code>
* after.
*/
public Control getListControl(Composite parent) {
if (fTableControl == null) {
assertCompositeNotNull(parent);
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
fTable= createTableViewer(parent);
fTable.setContentProvider(fListViewerAdapter);
fTable.setLabelProvider(fLabelProvider);
fTable.addSelectionChangedListener(fListViewerAdapter);
fTableControl= (Table)fTable.getControl();
TableLayout tableLayout= new TableLayout();
tableLayout.addColumnData(new ColumnWeightData(100));
fTableColumn= new TableColumn(fTableControl, SWT.NONE);
fTableColumn.setResizable(false);
fTableControl.setLayout(tableLayout);
fTable.setInput(fParentElement);
fTableControl.setEnabled(isEnabled());
if (fSelectionWhenEnabled != null) {
postSetSelection(fSelectionWhenEnabled);
}
fTableColumn.getDisplay().asyncExec(new Runnable() {
public void run() {
if (fTableColumn != null && !fTableColumn.isDisposed()) {
fTableColumn.pack();
}
}
});
}
return fTableControl;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
}
/**
* Returns the internally used table viewer.
*/
public TableViewer getTableViewer() {
return fTable;
}
/*
* Subclasses may override to specify a different style.
*/
protected int getListStyle(){
return SWT.BORDER + SWT.MULTI + SWT.H_SCROLL + SWT.V_SCROLL;
}
protected TableViewer createTableViewer(Composite parent) {
Table table= new Table(parent, getListStyle());
return new TableViewer(table);
}
protected Button createButton(Composite parent, String label, SelectionListener listener) {
Button button= new Button(parent, SWT.PUSH);
button.setText(label);
button.addSelectionListener(listener);
MGridData gd= new MGridData();
gd.horizontalAlignment= gd.FILL;
gd.grabExcessHorizontalSpace= true;
gd.verticalAlignment= gd.BEGINNING;
gd.heightHint = SWTUtil.getButtonHeigthHint(button);
gd.widthHint = SWTUtil.getButtonWidthHint(button);
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
button.setLayoutData(gd);
return button;
}
private Label createSeparator(Composite parent) {
Label separator= new Label(parent, SWT.NONE);
separator.setVisible(false);
MGridData gd= new MGridData();
gd.horizontalAlignment= gd.FILL;
gd.verticalAlignment= gd.BEGINNING;
gd.heightHint= 4;
separator.setLayoutData(gd);
return separator;
}
/**
* Returns the composite containing the buttons. When called the first time, the control
* will be created.
* @param The parent composite when called the first time, or <code>null</code>
* after.
*/
public Composite getButtonBox(Composite parent) {
if (fButtonsControl == null) {
assertCompositeNotNull(parent);
SelectionListener listener= new SelectionListener() {
public void widgetDefaultSelected(SelectionEvent e) {
doButtonSelected(e);
}
public void widgetSelected(SelectionEvent e) {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
doButtonSelected(e);
}
};
Composite contents= new Composite(parent, SWT.NULL);
MGridLayout layout= new MGridLayout();
layout.marginWidth= 0;
layout.marginHeight= 0;
contents.setLayout(layout);
if (fButtonLabels != null) {
fButtonControls= new Button[fButtonLabels.length];
for (int i= 0; i < fButtonLabels.length; i++) {
String currLabel= fButtonLabels[i];
if (currLabel != null) {
fButtonControls[i]= createButton(contents, currLabel, listener);
fButtonControls[i].setEnabled(isEnabled() && fButtonsEnabled[i]);
} else {
fButtonControls[i]= null;
createSeparator(contents);
}
}
}
fLastSeparator= createSeparator(contents);
updateButtonState();
fButtonsControl= contents;
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
return fButtonsControl;
}
private void doButtonSelected(SelectionEvent e) {
if (fButtonControls != null) {
for (int i= 0; i < fButtonControls.length; i++) {
if (e.widget == fButtonControls[i]) {
buttonPressed(i);
return;
}
}
}
}
/*
* @see DialogField#dialogFieldChanged
*/
public void dialogFieldChanged() {
super.dialogFieldChanged();
if (fTableColumn != null && !fTableColumn.isDisposed()) {
fTableColumn.pack();
}
updateButtonState();
}
private Button getButton(int index) {
if (fButtonControls != null && index >= 0 && index < fButtonControls.length) {
return fButtonControls[index];
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
return null;
}
/*
* Updates the enable state of the all buttons
*/
protected void updateButtonState() {
if (fButtonControls != null) {
ISelection sel= fTable.getSelection();
for (int i= 0; i < fButtonControls.length; i++) {
Button button= fButtonControls[i];
if (isOkToUse(button)) {
boolean extraState= getManagedButtonState(sel, i);
button.setEnabled(isEnabled() && extraState && fButtonsEnabled[i]);
}
}
}
}
protected boolean getManagedButtonState(ISelection sel, int index) {
if (index == fRemoveButtonIndex) {
return !sel.isEmpty();
} else if (index == fUpButtonIndex) {
return !sel.isEmpty() && canMoveUp();
} else if (index == fDownButtonIndex) {
return !sel.isEmpty() && canMoveDown();
}
return true;
}
/*
* @see DialogField#updateEnableState
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
*/
protected void updateEnableState() {
super.updateEnableState();
boolean enabled= isEnabled();
if (isOkToUse(fTableControl)) {
if (!enabled) {
fSelectionWhenEnabled= fTable.getSelection();
selectElements(null);
} else {
selectElements(fSelectionWhenEnabled);
fSelectionWhenEnabled= null;
}
fTableControl.setEnabled(enabled);
}
updateButtonState();
}
/**
* Sets a button enabled or disabled.
*/
public void enableButton(int index, boolean enable) {
if (fButtonsEnabled != null && index < fButtonsEnabled.length) {
fButtonsEnabled[index]= enable;
updateButtonState();
}
}
/**
* Sets the elements shown in the list.
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
*/
public void setElements(List elements) {
fElements= new ArrayList(elements);
if (fTable != null) {
fTable.refresh();
}
dialogFieldChanged();
}
/**
* Gets the elements shown in the list.
* The list returned is a copy, so it can be modified by the user.
*/
public List getElements() {
return new ArrayList(fElements);
}
/**
* Gets the elements shown at the given index.
*/
public Object getElement(int index) {
return fElements.get(index);
}
/**
* Replace an element.
*/
public void replaceElement(Object oldElement, Object newElement) throws IllegalArgumentException {
int idx= fElements.indexOf(oldElement);
if (idx != -1) {
if (oldElement.equals(newElement) || fElements.contains(newElement)) {
return;
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
fElements.set(idx, newElement);
if (fTable != null) {
List selected= getSelectedElements();
if (selected.remove(oldElement)) {
selected.add(newElement);
}
fTable.refresh();
fTable.setSelection(new StructuredSelection(selected));
}
dialogFieldChanged();
} else {
throw new IllegalArgumentException();
}
}
/**
* Adds an element at the end of the list.
*/
public void addElement(Object element) {
if (fElements.contains(element)) {
return;
}
fElements.add(element);
if (fTable != null) {
fTable.add(element);
}
dialogFieldChanged();
}
/**
* Adds elements at the end of the list.
*/
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
public void addElements(List elements) {
int nElements= elements.size();
if (nElements > 0) {
ArrayList elementsToAdd= new ArrayList(nElements);
for (int i= 0; i < nElements; i++) {
Object elem= elements.get(i);
if (!fElements.contains(elem)) {
elementsToAdd.add(elem);
}
}
fElements.addAll(elementsToAdd);
if (fTable != null) {
fTable.add(elementsToAdd.toArray());
}
dialogFieldChanged();
}
}
/**
* Adds an element at a position.
*/
public void insertElementAt(Object element, int index) {
if (fElements.contains(element)) {
return;
}
fElements.add(index, element);
if (fTable != null) {
fTable.add(element);
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
}
dialogFieldChanged();
}
/**
* Adds an element at a position.
*/
public void removeAllElements() {
if (fElements.size() > 0) {
fElements.clear();
if (fTable != null) {
fTable.refresh();
}
dialogFieldChanged();
}
}
/**
* Removes an element from the list.
*/
public void removeElement(Object element) throws IllegalArgumentException {
if (fElements.remove(element)) {
if (fTable != null) {
fTable.remove(element);
}
dialogFieldChanged();
} else {
throw new IllegalArgumentException();
}
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
/**
* Removes elements from the list.
*/
public void removeElements(List elements) {
if (elements.size() > 0) {
fElements.removeAll(elements);
if (fTable != null) {
fTable.remove(elements.toArray());
}
dialogFieldChanged();
}
}
/**
* Gets the number of elements
*/
public int getSize() {
return fElements.size();
}
public void selectElements(ISelection selection) {
fSelectionWhenEnabled= selection;
if (fTable != null) {
fTable.setSelection(selection);
}
}
public void postSetSelection(final ISelection selection) {
if (isOkToUse(fTableControl)) {
Display d= fTableControl.getDisplay();
d.asyncExec(new Runnable() {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
public void run() {
if (isOkToUse(fTableControl)) {
selectElements(selection);
}
}
});
}
}
/**
* Refreshes the table.
*/
public void refresh() {
fTable.refresh();
}
private List moveUp(List elements, List move) {
int nElements= elements.size();
List res= new ArrayList(nElements);
Object floating= null;
for (int i= 0; i < nElements; i++) {
Object curr= elements.get(i);
if (move.contains(curr)) {
res.add(curr);
} else {
if (floating != null) {
res.add(floating);
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
floating= curr;
}
}
if (floating != null) {
res.add(floating);
}
return res;
}
private void moveUp(List toMoveUp) {
if (toMoveUp.size() > 0) {
setElements(moveUp(fElements, toMoveUp));
fTable.reveal(toMoveUp.get(0));
}
}
private void moveDown(List toMoveDown) {
if (toMoveDown.size() > 0) {
setElements(reverse(moveUp(reverse(fElements), toMoveDown)));
fTable.reveal(toMoveDown.get(toMoveDown.size() - 1));
}
}
private List reverse(List p) {
List reverse= new ArrayList(p.size());
for (int i= p.size()-1; i >= 0; i--) {
reverse.add(p.get(i));
}
return reverse;
}
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
private void remove() {
removeElements(getSelectedElements());
}
private void up() {
moveUp(getSelectedElements());
}
private void down() {
moveDown(getSelectedElements());
}
private boolean canMoveUp() {
if (isOkToUse(fTableControl)) {
int[] indc= fTableControl.getSelectionIndices();
for (int i= 0; i < indc.length; i++) {
if (indc[i] != i) {
return true;
}
}
}
return false;
}
private boolean canMoveDown() {
if (isOkToUse(fTableControl)) {
int[] indc= fTableControl.getSelectionIndices();
int k= fElements.size() - 1;
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
for (int i= indc.length - 1; i >= 0 ; i--, k--) {
if (indc[i] != k) {
return true;
}
}
}
return false;
}
/**
* Returns the selected elements.
*/
public List getSelectedElements() {
List result= new ArrayList();
if (fTable != null) {
ISelection selection= fTable.getSelection();
if (selection instanceof IStructuredSelection) {
Iterator iter= ((IStructuredSelection)selection).iterator();
while (iter.hasNext()) {
result.add(iter.next());
}
}
}
return result;
}
private class ListViewerAdapter implements IStructuredContentProvider, ISelectionChangedListener {
|
6,207 |
Bug 6207 Java project properties dialog grows taller than screen
|
build 20011116 The Java Build Path/Order page in the project properties dialog always grows the table to show all items. In a workspace with many source folders the properties dialog grows so tall that you can no longer see the ok/cancel buttons. I noticed this while using WSDD (Eclipse 1.0 based) to create P3ML bundles. P3ML consists of about 20 bundles with each bundle living in a separate source folder. Note that the resize only happens when the dialog is reopened. If you create source folders in the properties dialog and then switch to the order page you will see scroll bars. Also, it seems that this only happens when there is a large number of source folders. When I reference a lot of projects the height of the order page is limited and the table shows scroll bars.
|
resolved fixed
|
1b69a90
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:07:47Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/dialogfields/ListDialogField.java
|
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
}
public boolean isDeleted(Object element) {
return false;
}
public void dispose() {
}
public Object[] getElements(Object obj) {
return fElements.toArray();
}
public void selectionChanged(SelectionChangedEvent event) {
doListSelected(event);
}
}
private void doListSelected(SelectionChangedEvent event) {
updateButtonState();
if (fListAdapter != null) {
fListAdapter.selectionChanged(this);
}
}
}
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.buildpaths;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IProjectDescription;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.IWorkspaceRoot;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.SubProgressMonitor;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.TabFolder;
import org.eclipse.swt.widgets.TabItem;
import org.eclipse.swt.widgets.Widget;
import org.eclipse.jface.operation.IRunnableWithProgress;
import org.eclipse.jface.resource.ImageRegistry;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ITreeContentProvider;
import org.eclipse.jface.viewers.ViewerFilter;
import org.eclipse.ui.ISharedImages;
import org.eclipse.ui.IWorkbench;
import org.eclipse.ui.help.WorkbenchHelp;
import org.eclipse.ui.model.WorkbenchContentProvider;
import org.eclipse.ui.model.WorkbenchLabelProvider;
import org.eclipse.jdt.core.IClasspathEntry;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.JavaConventions;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.launching.JavaRuntime;
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.JavaPluginImages;
import org.eclipse.jdt.internal.ui.dialogs.ElementTreeSelectionDialog;
import org.eclipse.jdt.internal.ui.dialogs.ISelectionValidator;
import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
import org.eclipse.jdt.internal.ui.dialogs.StatusUtil;
import org.eclipse.jdt.internal.ui.preferences.JavaBasePreferencePage;
import org.eclipse.jdt.internal.ui.util.CoreUtility;
import org.eclipse.jdt.internal.ui.util.SWTUtil;
import org.eclipse.jdt.internal.ui.util.TabFolderLayout;
import org.eclipse.jdt.internal.ui.viewsupport.ImageDisposer;
import org.eclipse.jdt.internal.ui.wizards.IStatusChangeListener;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
import org.eclipse.jdt.internal.ui.wizards.TypedElementSelectionValidator;
import org.eclipse.jdt.internal.ui.wizards.TypedViewerFilter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.CheckedListDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IStringButtonAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.LayoutUtil;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridData;
import org.eclipse.jdt.internal.ui.wizards.swt.MGridLayout;
public class BuildPathsBlock {
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
private IWorkspaceRoot fWorkspaceRoot;
private CheckedListDialogField fClassPathList;
private StringDialogField fBuildPathDialogField;
private StatusInfo fClassPathStatus;
private StatusInfo fBuildPathStatus;
private IJavaProject fCurrJProject;
private IPath fOutputLocationPath;
private IStatusChangeListener fContext;
private Control fSWTWidget;
private boolean fIsNewProject;
private SourceContainerWorkbookPage fSourceContainerPage;
private ProjectsWorkbookPage fProjectsPage;
private LibrariesWorkbookPage fLibrariesPage;
private BuildPathBasePage fCurrPage;
public BuildPathsBlock(IWorkspaceRoot root, IStatusChangeListener context, boolean isNewProject) {
fWorkspaceRoot= root;
fContext= context;
fIsNewProject= isNewProject;
fSourceContainerPage= null;
fLibrariesPage= null;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
fProjectsPage= null;
fCurrPage= null;
BuildPathAdapter adapter= new BuildPathAdapter();
String[] buttonLabels= new String[] {
NewWizardMessages.getString("BuildPathsBlock.classpath.up.button"),
NewWizardMessages.getString("BuildPathsBlock.classpath.down.button"),
null,
NewWizardMessages.getString("BuildPathsBlock.classpath.checkall.button"),
NewWizardMessages.getString("BuildPathsBlock.classpath.uncheckall.button")
};
fClassPathList= new CheckedListDialogField(null, buttonLabels, new CPListLabelProvider());
fClassPathList.setDialogFieldListener(adapter);
fClassPathList.setLabelText(NewWizardMessages.getString("BuildPathsBlock.classpath.label"));
fClassPathList.setUpButtonIndex(0);
fClassPathList.setDownButtonIndex(1);
fClassPathList.setCheckAllButtonIndex(3);
fClassPathList.setUncheckAllButtonIndex(4);
if (isNewProject) {
fBuildPathDialogField= new StringDialogField();
} else {
StringButtonDialogField dialogField= new StringButtonDialogField(adapter);
dialogField.setButtonLabel(NewWizardMessages.getString("BuildPathsBlock.buildpath.button"));
fBuildPathDialogField= dialogField;
}
fBuildPathDialogField.setDialogFieldListener(adapter);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
fBuildPathDialogField.setLabelText(NewWizardMessages.getString("BuildPathsBlock.buildpath.label"));
fBuildPathStatus= new StatusInfo();
fClassPathStatus= new StatusInfo();
fCurrJProject= null;
}
public Control createControl(Composite parent) {
fSWTWidget= parent;
Composite composite= new Composite(parent, SWT.NONE);
MGridLayout layout= new MGridLayout();
layout.marginWidth= 0;
layout.minimumWidth= SWTUtil.convertWidthInCharsToPixels(80, parent);
layout.minimumHeight= SWTUtil.convertHeightInCharsToPixels(20, parent);
layout.numColumns= 1;
composite.setLayout(layout);
TabFolder folder= new TabFolder(composite, SWT.NONE);
folder.setLayout(new TabFolderLayout());
folder.setLayoutData(new MGridData(MGridData.FILL_BOTH));
folder.addSelectionListener(new SelectionAdapter() {
public void widgetSelected(SelectionEvent e) {
tabChanged(e.item);
}
});
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
ImageRegistry imageRegistry= JavaPlugin.getDefault().getImageRegistry();
TabItem item;
fSourceContainerPage= new SourceContainerWorkbookPage(fWorkspaceRoot, fClassPathList, fBuildPathDialogField, fIsNewProject);
item= new TabItem(folder, SWT.NONE);
item.setText(NewWizardMessages.getString("BuildPathsBlock.tab.source"));
item.setImage(imageRegistry.get(JavaPluginImages.IMG_OBJS_PACKFRAG_ROOT));
item.setData(fSourceContainerPage);
item.setControl(fSourceContainerPage.getControl(folder));
IWorkbench workbench= JavaPlugin.getDefault().getWorkbench();
Image projectImage= workbench.getSharedImages().getImage(ISharedImages.IMG_OBJ_PROJECT);
fProjectsPage= new ProjectsWorkbookPage(fClassPathList);
item= new TabItem(folder, SWT.NONE);
item.setText(NewWizardMessages.getString("BuildPathsBlock.tab.projects"));
item.setImage(projectImage);
item.setData(fProjectsPage);
item.setControl(fProjectsPage.getControl(folder));
fLibrariesPage= new LibrariesWorkbookPage(fWorkspaceRoot, fClassPathList);
item= new TabItem(folder, SWT.NONE);
item.setText(NewWizardMessages.getString("BuildPathsBlock.tab.libraries"));
item.setImage(imageRegistry.get(JavaPluginImages.IMG_OBJS_LIBRARY));
item.setData(fLibrariesPage);
item.setControl(fLibrariesPage.getControl(folder));
Image cpoImage= JavaPluginImages.DESC_TOOL_CLASSPATH_ORDER.createImage();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
composite.addDisposeListener(new ImageDisposer(cpoImage));
ClasspathOrderingWorkbookPage ordpage= new ClasspathOrderingWorkbookPage(fClassPathList);
item= new TabItem(folder, SWT.NONE);
item.setText(NewWizardMessages.getString("BuildPathsBlock.tab.order"));
item.setImage(cpoImage);
item.setData(ordpage);
item.setControl(ordpage.getControl(folder));
if (fCurrJProject != null) {
fSourceContainerPage.init(fCurrJProject);
fLibrariesPage.init(fCurrJProject);
fProjectsPage.init(fCurrJProject);
}
Composite editorcomp= new Composite(composite, SWT.NONE);
DialogField[] editors= new DialogField[] { fBuildPathDialogField };
LayoutUtil.doDefaultLayout(editorcomp, editors, true, 0, 0, 0, 0);
int maxFieldWidth= SWTUtil.convertWidthInCharsToPixels(40, parent);
LayoutUtil.setWidthHint(fBuildPathDialogField.getTextControl(null), maxFieldWidth);
editorcomp.setLayoutData(new MGridData(MGridData.FILL_HORIZONTAL));
if (fIsNewProject) {
folder.setSelection(0);
fCurrPage= fSourceContainerPage;
} else {
folder.setSelection(3);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
fCurrPage= ordpage;
}
WorkbenchHelp.setHelp(composite, new Object[] { IJavaHelpContextIds.BUILD_PATH_BLOCK });
return composite;
}
private Shell getShell() {
if (fSWTWidget != null) {
return fSWTWidget.getShell();
}
return JavaPlugin.getActiveWorkbenchShell();
}
/**
* Initializes the classpath for the given project. Multiple calls to init are allowed,
* but all existing settings will be cleared and replace by the given or default paths.
* @param project The java project to configure. Does not have to exist.
* @param outputLocation The output location to be set in the page. If <code>null</code>
* is passed, jdt default settings are used, or - if the project is an existing Java project - the
* output location of the existing project
* @param classpathEntries The classpath entries to be set in the page. If <code>null</code>
* is passed, jdt default settings are used, or - if the project is an existing Java project - the
* classpath entries of the existing project
*/
public void init(IJavaProject jproject, IPath outputLocation, IClasspathEntry[] classpathEntries) {
fCurrJProject= jproject;
boolean projExists= false;
try {
IProject project= fCurrJProject.getProject();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
projExists= (project.exists() && project.hasNature(JavaCore.NATURE_ID));
if (projExists) {
if (outputLocation == null) {
outputLocation= fCurrJProject.getOutputLocation();
}
if (classpathEntries == null) {
classpathEntries= fCurrJProject.getRawClasspath();
}
}
} catch (CoreException e) {
JavaPlugin.log(e.getStatus());
}
if (outputLocation == null) {
outputLocation= getDefaultBuildPath(jproject);
}
List newClassPath;
if (classpathEntries == null) {
newClassPath= getDefaultClassPath(jproject);
} else {
newClassPath= new ArrayList();
for (int i= 0; i < classpathEntries.length; i++) {
IClasspathEntry curr= classpathEntries[i];
int entryKind= curr.getEntryKind();
IPath path= curr.getPath();
boolean isExported= curr.isExported();
IResource res= null;
boolean isMissing= false;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
if (entryKind != IClasspathEntry.CPE_VARIABLE) {
res= fWorkspaceRoot.findMember(path);
if (res == null) {
isMissing= (entryKind != IClasspathEntry.CPE_LIBRARY || !path.toFile().isFile());
}
} else {
IPath resolvedPath= JavaCore.getResolvedVariablePath(path);
isMissing= (resolvedPath == null) || !resolvedPath.toFile().isFile();
}
CPListElement elem= new CPListElement(entryKind, path, res, curr.getSourceAttachmentPath(), curr.getSourceAttachmentRootPath(), isExported);
if (projExists) {
elem.setIsMissing(isMissing);
}
newClassPath.add(elem);
}
}
List exportedEntries = new ArrayList();
for (int i= 0; i < newClassPath.size(); i++) {
CPListElement curr= (CPListElement) newClassPath.get(i);
if (curr.isExported() || curr.getEntryKind() == IClasspathEntry.CPE_SOURCE) {
exportedEntries.add(curr);
}
}
fBuildPathDialogField.setText(outputLocation.makeRelative().toString());
fClassPathList.setElements(newClassPath);
fClassPathList.setCheckedElements(exportedEntries);
if (fSourceContainerPage != null) {
fSourceContainerPage.init(fCurrJProject);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
fProjectsPage.init(fCurrJProject);
fLibrariesPage.init(fCurrJProject);
}
doStatusLineUpdate();
}
/**
* Returns the Java project. Can return <code>null<code> if the page has not
* been initialized.
*/
public IJavaProject getJavaProject() {
return fCurrJProject;
}
/**
* Returns the current output location. Note that the path returned must not be valid.
*/
public IPath getOutputLocation() {
return new Path(fBuildPathDialogField.getText()).makeAbsolute();
}
/**
* Returns the current class path (raw). Note that the entries returned must not be valid.
*/
public IClasspathEntry[] getRawClassPath() {
List elements= fClassPathList.getElements();
int nElements= elements.size();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
IClasspathEntry[] entries= new IClasspathEntry[elements.size()];
for (int i= 0; i < nElements; i++) {
CPListElement currElement= (CPListElement) elements.get(i);
entries[i]= currElement.getClasspathEntry();
}
return entries;
}
private List getDefaultClassPath(IJavaProject jproj) {
List list= new ArrayList();
IResource srcFolder;
if (JavaBasePreferencePage.useSrcAndBinFolders()) {
srcFolder= jproj.getProject().getFolder("src");
} else {
srcFolder= jproj.getProject();
}
list.add(new CPListElement(IClasspathEntry.CPE_SOURCE, srcFolder.getFullPath(), srcFolder));
IPath libPath= new Path(JavaRuntime.JRELIB_VARIABLE);
IPath attachPath= new Path(JavaRuntime.JRESRC_VARIABLE);
IPath attachRoot= new Path(JavaRuntime.JRESRCROOT_VARIABLE);
CPListElement elem= new CPListElement(IClasspathEntry.CPE_VARIABLE, libPath, null, attachPath, attachRoot, false);
list.add(elem);
return list;
}
private IPath getDefaultBuildPath(IJavaProject jproj) {
if (JavaBasePreferencePage.useSrcAndBinFolders()) {
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
return jproj.getProject().getFullPath().append("bin");
} else {
return jproj.getProject().getFullPath();
}
}
private class BuildPathAdapter implements IStringButtonAdapter, IDialogFieldListener {
public void changeControlPressed(DialogField field) {
buildPathChangeControlPressed(field);
}
public void dialogFieldChanged(DialogField field) {
buildPathDialogFieldChanged(field);
}
}
private void buildPathChangeControlPressed(DialogField field) {
if (field == fBuildPathDialogField) {
IContainer container= chooseContainer();
if (container != null) {
fBuildPathDialogField.setText(container.getFullPath().toString());
}
}
}
private void buildPathDialogFieldChanged(DialogField field) {
if (field == fClassPathList) {
updateClassPathStatus();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
updateBuildPathStatus();
} else if (field == fBuildPathDialogField) {
updateBuildPathStatus();
}
doStatusLineUpdate();
}
private void doStatusLineUpdate() {
IStatus res= findMostSevereStatus();
fContext.statusChanged(res);
}
private IStatus findMostSevereStatus() {
return StatusUtil.getMoreSevere(fClassPathStatus, fBuildPathStatus);
}
/**
* Validates the build path.
*/
private void updateClassPathStatus() {
fClassPathStatus.setOK();
List elements= fClassPathList.getElements();
boolean entryMissing= false;
IClasspathEntry[] entries= new IClasspathEntry[elements.size()];
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
for (int i= elements.size()-1 ; i >= 0 ; i--) {
CPListElement currElement= (CPListElement)elements.get(i);
boolean isChecked= fClassPathList.isChecked(currElement);
if (currElement.getEntryKind() == IClasspathEntry.CPE_SOURCE) {
if (!isChecked) {
fClassPathList.setCheckedWithoutUpdate(currElement, true);
}
} else {
currElement.setExported(isChecked);
}
entries[i]= currElement.getClasspathEntry();
entryMissing= entryMissing || currElement.isMissing();
}
if (entryMissing) {
fClassPathStatus.setWarning(NewWizardMessages.getString("BuildPathsBlock.warning.EntryMissing"));
}
if (fCurrJProject.hasClasspathCycle(entries)) {
fClassPathStatus.setWarning(NewWizardMessages.getString("BuildPathsBlock.warning.CycleInClassPath"));
}
}
/**
* Validates output location & build path.
*/
private void updateBuildPathStatus() {
fOutputLocationPath= null;
String text= fBuildPathDialogField.getText();
if ("".equals(text)) {
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
fBuildPathStatus.setError(NewWizardMessages.getString("BuildPathsBlock.error.EnterBuildPath"));
return;
}
IPath path= getOutputLocation();
IResource res= fWorkspaceRoot.findMember(path);
if (res != null) {
if (res.getType() == IResource.FILE) {
fBuildPathStatus.setError(NewWizardMessages.getString("BuildPathsBlock.error.InvalidBuildPath"));
return;
}
} else {
IPath projPath= path.uptoSegment(1);
if (!projPath.equals(fCurrJProject.getProject().getFullPath())) {
IProject proj= (IProject)fWorkspaceRoot.findMember(projPath);
if (proj == null || !proj.isOpen()) {
fBuildPathStatus.setError(NewWizardMessages.getString("BuildPathsBlock.error.BuildPathProjNotExists"));
return;
}
}
}
fOutputLocationPath= path;
List elements= fClassPathList.getElements();
IClasspathEntry[] entries= new IClasspathEntry[elements.size()];
for (int i= elements.size()-1 ; i >= 0 ; i--) {
CPListElement currElement= (CPListElement)elements.get(i);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
entries[i]= currElement.getClasspathEntry();
}
IStatus status= JavaConventions.validateClasspath(fCurrJProject, entries, path);
if (!status.isOK()) {
fBuildPathStatus.setError(status.getMessage());
return;
}
fBuildPathStatus.setOK();
}
/**
* Creates a runnable that sets the configured build paths.
*/
public IRunnableWithProgress getRunnable() {
final List classPathEntries= fClassPathList.getElements();
final IPath path= getOutputLocation();
return new IRunnableWithProgress() {
public void run(IProgressMonitor monitor) throws InvocationTargetException {
if (monitor == null) {
monitor= new NullProgressMonitor();
}
monitor.beginTask(NewWizardMessages.getString("BuildPathsBlock.operationdesc"), 12);
try {
createJavaProject(classPathEntries, path, monitor);
} catch (CoreException e) {
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
throw new InvocationTargetException(e);
} finally {
monitor.done();
}
}
};
}
/**
* Creates the Java project and sets the configured build path and output location.
* If the project already exists only build paths are updated.
*/
private void createJavaProject(List classPathEntries, IPath buildPath, IProgressMonitor monitor) throws CoreException {
IProject project= fCurrJProject.getProject();
if (!project.exists()) {
project.create(null);
}
if (!project.isOpen()) {
project.open(null);
}
if (!project.hasNature(JavaCore.NATURE_ID)) {
addNatureToProject(project, JavaCore.NATURE_ID, null);
}
monitor.worked(1);
String[] prevRequiredProjects= fCurrJProject.getRequiredProjectNames();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
if (!fWorkspaceRoot.exists(buildPath)) {
IFolder folder= fWorkspaceRoot.getFolder(buildPath);
CoreUtility.createFolder(folder, true, true, null);
}
monitor.worked(1);
fCurrJProject.setOutputLocation(buildPath, new SubProgressMonitor(monitor, 3));
int nEntries= classPathEntries.size();
IClasspathEntry[] classpath= new IClasspathEntry[nEntries];
for (int i= 0; i < nEntries; i++) {
CPListElement entry= ((CPListElement)classPathEntries.get(i));
IResource res= entry.getResource();
if ((res instanceof IFolder) && !res.exists()) {
CoreUtility.createFolder((IFolder)res, true, true, null);
}
classpath[i]= entry.getClasspathEntry();
}
monitor.worked(1);
fCurrJProject.setRawClasspath(classpath, new SubProgressMonitor(monitor, 5));
}
/**
* Adds a nature to a project
*/
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
private static void addNatureToProject(IProject proj, String natureId, IProgressMonitor monitor) throws CoreException {
IProjectDescription description = proj.getDescription();
String[] prevNatures= description.getNatureIds();
String[] newNatures= new String[prevNatures.length + 1];
System.arraycopy(prevNatures, 0, newNatures, 0, prevNatures.length);
newNatures[prevNatures.length]= natureId;
description.setNatureIds(newNatures);
proj.setDescription(description, monitor);
}
private IContainer chooseContainer() {
Class[] acceptedClasses= new Class[] { IProject.class, IFolder.class };
ISelectionValidator validator= new TypedElementSelectionValidator(acceptedClasses, false);
IProject[] allProjects= fWorkspaceRoot.getProjects();
ArrayList rejectedElements= new ArrayList(allProjects.length);
IProject currProject= fCurrJProject.getProject();
for (int i= 0; i < allProjects.length; i++) {
if (!allProjects[i].equals(currProject)) {
rejectedElements.add(allProjects[i]);
}
}
ViewerFilter filter= new TypedViewerFilter(acceptedClasses, rejectedElements.toArray());
ILabelProvider lp= new WorkbenchLabelProvider();
ITreeContentProvider cp= new WorkbenchContentProvider();
IResource initSelection= null;
if (fOutputLocationPath != null) {
initSelection= fWorkspaceRoot.findMember(fOutputLocationPath);
}
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(getShell(), lp, cp);
dialog.setTitle(NewWizardMessages.getString("BuildPathsBlock.ChooseOutputFolderDialog.title"));
dialog.setValidator(validator);
dialog.setMessage(NewWizardMessages.getString("BuildPathsBlock.ChooseOutputFolderDialog.description"));
dialog.addFilter(filter);
dialog.setInput(fWorkspaceRoot);
dialog.setInitialSelection(initSelection);
if (dialog.open() == dialog.OK) {
return (IContainer)dialog.getFirstResult();
}
return null;
}
private void tabChanged(Widget widget) {
if (widget instanceof TabItem) {
BuildPathBasePage newPage= (BuildPathBasePage) ((TabItem) widget).getData();
if (fCurrPage != null) {
List selection= fCurrPage.getSelection();
if (!selection.isEmpty()) {
newPage.setSelection(selection);
}
}
fCurrPage= newPage;
}
}
}
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/ChooseVariableDialog.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.buildpaths;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.jface.viewers.DoubleClickEvent;
import org.eclipse.jface.viewers.IDoubleClickListener;
import org.eclipse.jdt.internal.ui.dialogs.StatusDialog;
import org.eclipse.jdt.internal.ui.wizards.IStatusChangeListener;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
public class ChooseVariableDialog extends StatusDialog implements IStatusChangeListener, IDoubleClickListener {
private VariableBlock fVariableBlock;
public ChooseVariableDialog(Shell parent, String lastVariableSelection) {
super(parent);
setTitle(NewWizardMessages.getString("ChooseVariableDialog.variabledialog.title"));
fVariableBlock= new VariableBlock(this, true, lastVariableSelection);
}
protected Control createDialogArea(Composite parent) {
Composite composite= (Composite)super.createDialogArea(parent);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/ChooseVariableDialog.java
|
fVariableBlock.createContents(composite);
fVariableBlock.addDoubleClickListener(this);
return composite;
}
protected void okPressed() {
fVariableBlock.performOk();
super.okPressed();
}
public String getSelectedVariable() {
return fVariableBlock.getSelectedVariable();
}
/*
* @see IStatusChangeListener#statusChanged(IStatus)
*/
public void statusChanged(IStatus status) {
updateStatus(status);
}
/*
* @see IDoubleClickListener#doubleClick(DoubleClickEvent)
*/
public void doubleClick(DoubleClickEvent event) {
if (getStatus().isOK()) {
okPressed();
}
}
}
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.buildpaths;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.IWorkspaceRoot;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Path;
import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Shell;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
import org.eclipse.jface.dialogs.IDialogSettings;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ITreeContentProvider;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.viewers.ViewerFilter;
import org.eclipse.ui.help.WorkbenchHelp;
import org.eclipse.ui.model.WorkbenchContentProvider;
import org.eclipse.ui.model.WorkbenchLabelProvider;
import org.eclipse.jdt.core.IClasspathEntry;
import org.eclipse.jdt.core.IJavaModel;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.IUIConstants;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.dialogs.ElementTreeSelectionDialog;
import org.eclipse.jdt.internal.ui.dialogs.ISelectionValidator;
import org.eclipse.jdt.internal.ui.dialogs.StatusDialog;
import org.eclipse.jdt.internal.ui.util.SWTUtil;
import org.eclipse.jdt.internal.ui.wizards.IStatusChangeListener;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
import org.eclipse.jdt.internal.ui.wizards.TypedElementSelectionValidator;
import org.eclipse.jdt.internal.ui.wizards.TypedViewerFilter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IListAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.LayoutUtil;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.ListDialogField;
public class LibrariesWorkbookPage extends BuildPathBasePage {
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
private ListDialogField fClassPathList;
private IJavaProject fCurrJProject;
private ListDialogField fLibrariesList;
private IWorkspaceRoot fWorkspaceRoot;
private IDialogSettings fDialogSettings;
private Control fSWTControl;
public LibrariesWorkbookPage(IWorkspaceRoot root, ListDialogField classPathList) {
fClassPathList= classPathList;
fWorkspaceRoot= root;
fSWTControl= null;
fDialogSettings= JavaPlugin.getDefault().getDialogSettings();
String[] buttonLabels= new String[] {
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.addnew.button"),
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.addexisting.button"),
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.addjar.button"),
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.addextjar.button"),
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.addvariable.button"),
null,
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.setsource.button"),
null,
NewWizardMessages.getString("LibrariesWorkbookPage.libraries.remove.button")
};
LibrariesAdapter adapter= new LibrariesAdapter();
fLibrariesList= new ListDialogField(adapter, buttonLabels, new CPListLabelProvider());
fLibrariesList.setDialogFieldListener(adapter);
fLibrariesList.setLabelText(NewWizardMessages.getString("LibrariesWorkbookPage.libraries.label"));
fLibrariesList.setRemoveButtonIndex(8);
fLibrariesList.enableButton(6, false);
}
public void init(IJavaProject jproject) {
fCurrJProject= jproject;
updateLibrariesList();
}
private void updateLibrariesList() {
List cpelements= fClassPathList.getElements();
List libelements= new ArrayList(cpelements.size());
int nElements= cpelements.size();
for (int i= 0; i < nElements; i++) {
CPListElement cpe= (CPListElement)cpelements.get(i);
int kind= cpe.getEntryKind();
if (kind == IClasspathEntry.CPE_LIBRARY || kind == IClasspathEntry.CPE_VARIABLE) {
libelements.add(cpe);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
}
}
fLibrariesList.setElements(libelements);
}
public Control getControl(Composite parent) {
Composite composite= new Composite(parent, SWT.NONE);
LayoutUtil.doDefaultLayout(composite, new DialogField[] { fLibrariesList }, true, 0, 0, SWT.DEFAULT, SWT.DEFAULT);
int buttonBarWidth= SWTUtil.convertWidthInCharsToPixels(24, composite);
fLibrariesList.setButtonsMinWidth(buttonBarWidth);
fLibrariesList.getTableViewer().setSorter(new CPListElementSorter());
fSWTControl= composite;
return composite;
}
private Shell getShell() {
if (fSWTControl != null) {
return fSWTControl.getShell();
}
return JavaPlugin.getActiveWorkbenchShell();
}
private class LibrariesAdapter implements IDialogFieldListener, IListAdapter {
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
public void customButtonPressed(DialogField field, int index) {
libaryPageCustomButtonPressed(field, index);
}
public void selectionChanged(DialogField field) {
libaryPageSelectionChanged(field);
}
public void dialogFieldChanged(DialogField field) {
libaryPageDialogFieldChanged(field);
}
}
private void libaryPageCustomButtonPressed(DialogField field, int index) {
CPListElement[] libentries= null;
switch (index) {
case 0:
libentries= createNewClassContainer();
break;
case 1:
libentries= chooseClassContainers();
break;
case 2:
libentries= chooseJarFiles();
break;
case 3:
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
libentries= chooseExtJarFiles();
break;
case 4:
libentries= chooseVariableEntries();
break;
case 6:
List selElements= fLibrariesList.getSelectedElements();
CPListElement selElement= (CPListElement) selElements.get(0);
SourceAttachmentDialog dialog= new SourceAttachmentDialog(getShell(), selElement.getClasspathEntry());
if (dialog.open() == dialog.OK) {
selElement.setSourceAttachment(dialog.getSourceAttachmentPath(), dialog.getSourceAttachmentRootPath());
fLibrariesList.refresh();
fClassPathList.refresh();
}
break;
}
if (libentries != null) {
int nElementsChosen= libentries.length;
List cplist= fLibrariesList.getElements();
List elementsToAdd= new ArrayList(nElementsChosen);
for (int i= 0; i < nElementsChosen; i++) {
CPListElement curr= libentries[i];
if (!cplist.contains(curr) && !elementsToAdd.contains(curr)) {
elementsToAdd.add(curr);
addAttachmentsFromExistingLibs(curr);
}
}
fLibrariesList.addElements(elementsToAdd);
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
fLibrariesList.postSetSelection(new StructuredSelection(libentries));
}
}
private void libaryPageSelectionChanged(DialogField field) {
List selElements= fLibrariesList.getSelectedElements();
fLibrariesList.enableButton(6, canDoSourceAttachment(selElements));
}
private void libaryPageDialogFieldChanged(DialogField field) {
if (fCurrJProject != null) {
updateClasspathList();
}
}
private boolean canDoSourceAttachment(List selElements) {
if (selElements != null && selElements.size() == 1) {
CPListElement elem= (CPListElement) selElements.get(0);
return (!(elem.getResource() instanceof IFolder));
}
return false;
}
private void updateClasspathList() {
List projelements= fLibrariesList.getElements();
boolean remove= false;
List cpelements= fClassPathList.getElements();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
for (int i= cpelements.size() - 1; i >= 0; i--) {
CPListElement cpe= (CPListElement)cpelements.get(i);
int kind= cpe.getEntryKind();
if (kind == IClasspathEntry.CPE_LIBRARY || kind == IClasspathEntry.CPE_VARIABLE) {
if (!projelements.remove(cpe)) {
cpelements.remove(i);
remove= true;
}
}
}
for (int i= 0; i < projelements.size(); i++) {
cpelements.add(projelements.get(i));
}
if (remove || (projelements.size() > 0)) {
fClassPathList.setElements(cpelements);
}
}
private CPListElement[] createNewClassContainer() {
String title= NewWizardMessages.getString("LibrariesWorkbookPage.NewClassFolderDialog.title");
IProject currProject= fCurrJProject.getProject();
NewContainerDialog dialog= new NewContainerDialog(getShell(), title, currProject, getUsedContainers());
IPath projpath= currProject.getFullPath();
dialog.setMessage(NewWizardMessages.getFormattedString("LibrariesWorkbookPage.NewClassFolderDialog.description", projpath.toString()));
int ret= dialog.open();
if (ret == dialog.OK) {
IFolder folder= dialog.getFolder();
return new CPListElement[] { newCPLibraryElement(folder) };
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
}
return null;
}
private CPListElement[] chooseClassContainers() {
Class[] acceptedClasses= new Class[] { IFolder.class };
ISelectionValidator validator= new TypedElementSelectionValidator(acceptedClasses, true);
acceptedClasses= new Class[] { IProject.class, IFolder.class };
ViewerFilter filter= new TypedViewerFilter(acceptedClasses, getUsedContainers());
ILabelProvider lp= new WorkbenchLabelProvider();
ITreeContentProvider cp= new WorkbenchContentProvider();
ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(getShell(), lp, cp);
dialog.setValidator(validator);
dialog.setTitle(NewWizardMessages.getString("LibrariesWorkbookPage.ExistingClassFolderDialog.title"));
dialog.setMessage(NewWizardMessages.getString("LibrariesWorkbookPage.ExistingClassFolderDialog.description"));
dialog.addFilter(filter);
dialog.setInput(fWorkspaceRoot);
dialog.setInitialSelection(fCurrJProject.getProject());
if (dialog.open() == dialog.OK) {
Object[] elements= dialog.getResult();
CPListElement[] res= new CPListElement[elements.length];
for (int i= 0; i < res.length; i++) {
IResource elem= (IResource) elements[i];
res[i]= newCPLibraryElement(elem);
}
return res;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
}
return null;
}
private CPListElement[] chooseJarFiles() {
Class[] acceptedClasses= new Class[] { IFile.class };
ISelectionValidator validator= new TypedElementSelectionValidator(acceptedClasses, true);
ViewerFilter filter= new ArchiveFileFilter(getUsedJARFiles());
ILabelProvider lp= new WorkbenchLabelProvider();
ITreeContentProvider cp= new WorkbenchContentProvider();
ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(getShell(), lp, cp);
dialog.setValidator(validator);
dialog.setTitle(NewWizardMessages.getString("LibrariesWorkbookPage.JARArchiveDialog.title"));
dialog.setMessage(NewWizardMessages.getString("LibrariesWorkbookPage.JARArchiveDialog.description"));
dialog.addFilter(filter);
dialog.setInput(fWorkspaceRoot);
dialog.setInitialSelection(fCurrJProject.getProject());
if (dialog.open() == dialog.OK) {
Object[] elements= dialog.getResult();
CPListElement[] res= new CPListElement[elements.length];
for (int i= 0; i < res.length; i++) {
IResource elem= (IResource)elements[i];
res[i]= newCPLibraryElement(elem);
}
return res;
}
return null;
}
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
private IContainer[] getUsedContainers() {
ArrayList res= new ArrayList();
if (fCurrJProject.exists()) {
try {
IPath outputLocation= fCurrJProject.getOutputLocation();
if (outputLocation != null) {
IResource resource= fWorkspaceRoot.findMember(outputLocation);
if (resource instanceof IContainer) {
res.add(resource);
}
}
} catch (JavaModelException e) {
JavaPlugin.log(e.getStatus());
}
}
List cplist= fLibrariesList.getElements();
for (int i= 0; i < cplist.size(); i++) {
CPListElement elem= (CPListElement)cplist.get(i);
IResource resource= elem.getResource();
if (resource instanceof IContainer) {
res.add(resource);
}
}
return (IContainer[]) res.toArray(new IContainer[res.size()]);
}
private IFile[] getUsedJARFiles() {
List res= new ArrayList();
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
List cplist= fLibrariesList.getElements();
for (int i= 0; i < cplist.size(); i++) {
CPListElement elem= (CPListElement)cplist.get(i);
IResource resource= elem.getResource();
if (resource instanceof IFile) {
res.add(resource);
}
}
return (IFile[]) res.toArray(new IFile[res.size()]);
}
private CPListElement newCPLibraryElement(IResource res) {
return new CPListElement(IClasspathEntry.CPE_LIBRARY, res.getFullPath(), res);
};
private CPListElement[] chooseExtJarFiles() {
String lastUsedPath= fDialogSettings.get(IUIConstants.DIALOGSTORE_LASTEXTJAR);
if (lastUsedPath == null) {
lastUsedPath= "";
}
FileDialog dialog= new FileDialog(getShell(), SWT.MULTI);
dialog.setText(NewWizardMessages.getString("LibrariesWorkbookPage.ExtJARArchiveDialog.title"));
dialog.setFilterExtensions(new String[] {"*.jar;*.zip"});
dialog.setFilterPath(lastUsedPath);
String res= dialog.open();
if (res == null) {
return null;
}
String[] fileNames= dialog.getFileNames();
int nChosen= fileNames.length;
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
IPath filterPath= new Path(dialog.getFilterPath());
CPListElement[] elems= new CPListElement[nChosen];
for (int i= 0; i < nChosen; i++) {
IPath path= filterPath.append(fileNames[i]).makeAbsolute();
elems[i]= new CPListElement(IClasspathEntry.CPE_LIBRARY, path, null);
}
fDialogSettings.put(IUIConstants.DIALOGSTORE_LASTEXTJAR, filterPath.toOSString());
return elems;
}
private CPListElement[] chooseVariableEntries() {
ArrayList existingPaths= new ArrayList();
for (int i= 0; i < fLibrariesList.getSize(); i++) {
CPListElement elem= (CPListElement) fLibrariesList.getElement(i);
if (elem.getEntryKind() == IClasspathEntry.CPE_VARIABLE) {
existingPaths.add(elem.getPath());
}
}
VariableSelectionDialog dialog= new VariableSelectionDialog(getShell(), existingPaths);
if (dialog.open() == dialog.OK) {
IPath path= dialog.getVariable();
CPListElement elem= new CPListElement(IClasspathEntry.CPE_VARIABLE, path, null);
IPath resolvedPath= JavaCore.getResolvedVariablePath(path);
elem.setIsMissing((resolvedPath == null) || !resolvedPath.toFile().isFile());
return new CPListElement[] { elem };
}
return null;
}
|
6,196 |
Bug 6196 Last item selected by default in variable selection dialog
|
Build 20011120 - go to add a classpath variable - Browse for var name - it selects the last item by default Normally the default selection is the first item. This seems picky, but it's actually fairly annoying when using keyboard navigation for the default selection to be in the wrong place. (particularly when the one I always go for is ECLIPSE_HOME, which is always the first item <g>).
|
verified fixed
|
e26dfad
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2001-11-23T15:53:36Z | 2001-11-21T22:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/LibrariesWorkbookPage.java
|
private void addAttachmentsFromExistingLibs(CPListElement elem) {
try {
IJavaModel jmodel= fCurrJProject.getJavaModel();
IJavaProject[] jprojects= jmodel.getJavaProjects();
for (int i= 0; i < jprojects.length; i++) {
IJavaProject curr= jprojects[i];
if (!curr.equals(fCurrJProject)) {
IClasspathEntry[] entries= curr.getRawClasspath();
for (int k= 0; k < entries.length; k++) {
IClasspathEntry entry= entries[k];
if (entry.getEntryKind() == elem.getEntryKind()
&& entry.getPath().equals(elem.getPath())) {
IPath attachPath= entry.getSourceAttachmentPath();
if (attachPath != null && !attachPath.isEmpty()) {
elem.setSourceAttachment(attachPath, entry.getSourceAttachmentRootPath());
return;
}
}
}
}
}
} catch (JavaModelException e) {
JavaPlugin.log(e.getStatus());
}
}
private class VariableSelectionDialog extends StatusDialog implements IStatusChangeListener {
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.