Bug 22219 - OK button grayed out in New Variable Classpath Entry window [build path]
Summary: OK button grayed out in New Variable Classpath Entry window [build path]
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P3 major (vote)
Target Milestone: 2.1 M2   Edit
Assignee: Martin Aeschlimann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 18226 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-08-06 15:01 EDT by OTI Support CLA
Modified: 2002-09-24 13:33 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description OTI Support CLA 2002-08-06 15:01:32 EDT
Eclipse 2.0 on Windows 2000

1. Right-click on a project and select Properties
2. Click on Libraries tab
3. Click Add Variable... button
4. Click New... button
5. Enter info: 
	Name: TESTVAR
	Path: c:\
6. Click OK button to close the New Variable Entry window
The OK button is inactive and the window does not provide any indication 
why this is so. If you press the Cancel button on the "New Variable Classpath 
Entry" dialog, the classpath variable is not created. 

Workaround:
Select a reserved variable (JRE_LIB or JRC_SRC) and then click OK. 

Another similar testcase:
1. Right-click on a project and select Properties
2. Click on Libraries tab
3. Click Add Variable... button to open the New Variable Classpath Entry window
4. Select TESTVAR variable and click Remove button
Again, you cannot click OK to apply the changes.
Comment 1 OTI Support CLA 2002-08-06 15:01:57 EDT
Logged as HD100275.
Comment 2 Dirk Baeumer CLA 2002-08-07 09:46:31 EDT
You can only add variables to the build path that point to a file. Variables 
pointing to a directory are used inside other variables. But there should be 
some explanation about this in the dialog.
Comment 3 OTI Support CLA 2002-08-08 12:44:56 EDT
The customer has requested this to be addressed in Eclipse 2.0.1. Will this 
explanation make it into 2.0.1? 

Increased severity to Major.
Comment 4 Dirk Baeumer CLA 2002-08-08 12:59:35 EDT
Martin, can you do an analysis regarding the risk of fixing this. 
Comment 5 OTI Support CLA 2002-08-09 12:45:27 EDT
The issue for the customer is that the flow of adding new variables is not 
smooth. They believe that you should be able to add a variable that points to a 
directory (i.e. could be a classes folder) especially since if you do the 
workaround below, you *can* save the variable that points to the directory.
Comment 6 Martin Aeschlimann CLA 2002-08-09 12:55:20 EDT
It was a unsupported behaviour before 2.0 that classpath variables could point 
to a folder. There are no 'External Folders'.

- A solution I see (without removing functionality) is to add a status line to 
describe 'Variable needs to be extended', or, in case of multiple 
selection: 'Selection contains variables that need to be extended'.
That's an easy change (requires NLS fixes).

- Other solution is to allow adding variables pointing to folders and show a 
warning later in the build path dialog that this is an illegal/unsupported entry
This is also an easy fix (requires NLS fixes).

Note that the help page 'Adding a classpath variable to the build path' linked 
to the dialog explains the behaviour.
Comment 7 OTI Support CLA 2002-08-09 14:11:30 EDT
Will either of these solutions be in 2.0.1? Our customer is pushing hard for an 
answer one way or the other -- OTI support needs to respond end of business day 
today (a few hours away) with what to expect (if anything).
Comment 8 Martin Aeschlimann CLA 2002-08-12 04:48:03 EDT
No changes for 2.0.1.
We agree that the UI is not good; improvements required for 2.1:
Ideas:
- Render the images in the table to show if an entry is a folder or JAR.
- Merge Ok and Extend button

Comment 9 Cagatay Kavukcuoglu CLA 2002-09-05 08:39:33 EDT
External folders would help a lot in sharing project and launch definitions with
team members. Source projects may not have a lot of use for them but most server
applications need to have predefined folders in their classpaths. Extending
classpath variables to support external folders gives the ability to refer to an
installation path from a central location.
Comment 10 Martin Aeschlimann CLA 2002-09-12 14:18:13 EDT
*** Bug 18226 has been marked as a duplicate of this bug. ***
Comment 11 Martin Aeschlimann CLA 2002-09-24 13:33:58 EDT
improved the UI for adding a classpath variable:
- icons in the selection dialog now show if a variable is a folder or jar.
- when a folder is selected, an info line explains why the 'ok' button is 
disabled (because the variable needs to be extended.)

The 'edit classspath variable dialog' is new as well: It's now similar to the 
source attachment for variable entries dialog (a text input field).

> 20020924