Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 24122

Summary: [jres] Search VM does nothing
Product: [Eclipse Project] JDT Reporter: Dani Megert <daniel_megert>
Component: DebugAssignee: Joe Szurszewski <eclipse>
Status: RESOLVED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: darin.eclipse
Version: 2.0   
Target Milestone: 2.1 M2   
Hardware: PC   
OS: Windows 2000   
Whiteboard:
Bug Depends on: 22643    
Bug Blocks:    

Description Dani Megert CLA 2002-09-26 06:19:52 EDT
Build 20020924

First: Cool feature!

Go to Installed VMs pref page
Press Search
Select "My Computer"
==> nothing happens

Note: It starts searching if I select C: or "My Documents"

Guess it only starts if a drive or path is underneath. Either above cases should
be supported as well or the user should get feedback e.g. by disabling "Search..."
Comment 1 Darin Wright CLA 2002-09-26 09:52:28 EDT
Fixed for the case of "My Documents" and "Desktop". Added an info dialog if not 
JREs were found. Does not work for "My Computer" and "My Network Places" as 
those selections return "null" from the DirectoryDialog.open(), which is 
supposed to indicate "cancel".

Fixed as much as possible.
Comment 2 Darin Wright CLA 2002-09-26 09:52:55 EDT
Please verify, Joe. Do you see anyway to solve the "My Computer/My Network 
Places" problem?
Comment 3 Dani Megert CLA 2002-09-26 10:15:56 EDT
Note: My Documents works for me. I hope this will continue to work ;-)
Comment 4 Dani Megert CLA 2002-10-02 06:00:19 EDT
Seems not be fixed in I20021001:

Desktop -> dialog says: "No JREs found in..."
My Computer -> nothing happens [state as can't be fixed in the PR]
My Network places -> nothing happens [state as can't be fixed in the PR]
My Documents -> OK

The message (for Desktop) is very confusing for the user: a Windows (and any
other tree view) user is used to the fact given
Desktop
 + My Computer
    + Win2k (C:)

and I select "Desktop" or "My Computer" and then search for something I also get
the results found in "Win2k (C:)". If it is not possible to do so then the
warning should tell exactly this. Saying that nothing is found is confusing. I
could assume that there aren't any VMs at all.

Couldn't you disable the button if DirectoryDialog.open() returns null for the
selected item?
Maybe there's another way/API to browse the file system?
Comment 5 Joe Szurszewski CLA 2002-10-02 10:19:24 EDT
Darin, did your fix make it into 20021001?
Comment 6 Darin Wright CLA 2002-10-02 10:22:01 EDT
The fix is in. The problem is with the DirectoryDialog. Requires investigation.
Comment 7 Darin Wright CLA 2002-10-02 10:26:11 EDT
The problem with the directory dialog is marked as "wont fix" by SWT - bug# 
22643.
Comment 8 Darin Wright CLA 2002-10-02 10:30:56 EDT
I disagree.... The message for "Desktop" and "My Documents" is not misleading. 
The message states that no JREs were found, and states where we searched (which 
is the location returned by the directory dialog). The bogosity is with the 
directory dialog, which we do not intend to re-write.

Won't fix.
Comment 9 Dani Megert CLA 2002-10-02 11:01:39 EDT
What about a hint that sub components might answer results? I still think the
text is not goood enough. Let me give an example:
What would you say if I change Java or text search to show a dialog "No matches
found in project A" in the following case:
1. Select project A which has folder texts with a.txt that contains "test"
2. Open Search dialog - switch to Text search page
3. Check scope "Selected Resources"
4. Search for text "test"

Even though the dialog would say where it did not find the matches (in project
A) I assume you would not accept this as acceptable behavior for the Search
component.
Comment 10 Darin Wright CLA 2002-10-03 11:09:08 EDT
Re-open to mark as later. I agree that it would be nice to do better. But I 
also think that the root of the problem is the DirectoryDialog.
Comment 11 Darin Wright CLA 2002-10-03 11:09:23 EDT
No action planned immediately.
Comment 12 Darin Wright CLA 2007-06-08 12:56:19 EDT
Closing
Comment 13 Darin Wright CLA 2007-06-08 12:57:41 EDT
We can't tell the difference between cancel and "My Computer".