This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 75285

Summary: [SafeDelete] Wrong title in find usages result window.
Product: editor Reporter: Jiri Prox <jiriprox>
Component: RefactoringAssignee: Jan Becicka <jbecicka>
Severity: blocker    
Priority: P4    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:
Attachments: screenshot

Description Jiri Prox 2006-04-20 15:05:33 UTC
NetBeans IDE Dev (Build 200604131800)
1.6.0-beta2; Java HotSpot(TM) Client VM 1.6.0-beta2-b77
Linux version 2.6.5-1.358 running on i386
en_US (nb); UTF-8

Result window of find usages generated by Safe delete (when trying to delete
elements which is used) has wrong title. 

Steps to reproduce:
1) create class:
public class Main {
    int index  = 0;
    public void user1() {
        index = 1;
    public void user2() {
        index = 2;
2) safe-delete 'index'
3) selest Show usages in the waring dialog announcing that element is used

-> the result window has title: Usages of user1, but it should be: Usages of index.
Comment 1 Jiri Prox 2006-04-20 15:07:57 UTC
Created attachment 29957 [details]
Comment 2 ats37 2008-03-14 13:15:22 UTC
This is still an issue in the 6.1 Beta.

I was doing a Safe Delete of a JUnit test case, from right-clicking on the Class node in the
Project Explorer.  It displayed a warning, and when I clicked the Show Usages button the
resulting Output tab has the title "Usages of suite" rather than the classname.  The line
it had found containing the reference was
        TestSuite suite = new TestSuite(MyTest.class);
but where this is displayed in the lower part of the window it correctly highlights in bold
the classname, not "suite".  Only the tab title and top node ("Usages of suite [1 occurrence]")
get it wrong.

Right-clicking and doing a Find Usages on the class node displays the results with the title
"Usages of class MyTest" as expected.
Comment 3 ats37 2008-03-14 13:25:02 UTC
Further to the above, I tried to Safe Delete the class being tested, with the
"search in comments" option ticked.  The class itself contained a javadoc
comment mentioning the classname, and there were various references in the
associated JUnit test.  This time, the Find Usages results tab had the title
"Usages of" and top results node "Usages of [183 occurrences]".
Comment 4 Quality Engineering 2009-12-21 05:17:14 UTC
This bug was reported against NetBeans IDE 6.0 or an older release, or against a non-maintained module. NetBeans team does not have enough resources to get to this issue, therefore we are closing the issue as a WONTFIX. If you are interested in providing a patch for this bug, please see our NetFIX guidelines for how to proceed. 

We apologize for any inconvenience.

Thank you.
The NetBeans Team
Comment 5 Jiri Prox 2009-12-22 01:06:32 UTC
still reproducible in 6.8
Comment 6 Jan Becicka 2010-11-23 13:52:25 UTC
Author:    Jan Becicka <>
Date:      2010-11-23 14:48
Message:   Issue #75285 - [SafeDelete]  Wrong title in find usages result window.
Comment 7 Quality Engineering 2010-11-24 06:13:41 UTC
Integrated into 'main-golden', will be available in build *201011240001* on (upload may still be in progress)
User: Jan Becicka <>
Log: Issue #75285 - [SafeDelete]  Wrong title in find usages result window.