Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 147348 - Profile/Profile Other menu not refreshed correctly
Profile/Profile Other menu not refreshed correctly
Status: VERIFIED FIXED
Product: profiler
Classification: Unclassified
Component: Base
6.x
PC All
: P2 (vote)
: 6.x
Assigned To: J Bachorik
issues@profiler
65fixes2-verified
: REGRESSION
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-09-16 10:21 UTC by J Bachorik
Modified: 2009-02-19 22:55 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description J Bachorik 2008-09-16 10:21:22 UTC
The "Profile/Profile Other" menu is not refreshed correctly when node selection has been changed.
Steps to reproduce:
1. Create a java project
2. Create a non-java project (C/C++, PHP - the one with no profiler integration)
3. Select the non-java project and open "Profile/Profile Other" menu - all items should be disabled
4. Select the java project and open "Profile/Profile Other" menu - the "Profile Project ..." menu item should be enabled
but it's not; the menu items are enabled/disabled accordingly to the project being selected when first opening
"Profile/Profile Other" menu
Comment 1 J Bachorik 2008-09-16 11:00:46 UTC
This seems to be regression against 6.0
The reason is that the menu actions have become only weakly held so we can not use them to keep a weak lookup listener
alive. We must register the listener with the strong reference.

fixed - http://hg.netbeans.org/profiler-main/rev/984ad33dfa15
Comment 2 Quality Engineering 2008-09-18 17:58:24 UTC
Integrated into 'main-golden', will be available in build *200809181401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/984ad33dfa15
User: Jaroslav Bachorik <yardus@netbeans.org>
Log: #147348 - Profile/Profile Other menu not refreshed correctly
Comment 3 mariadavydova 2008-11-25 11:35:57 UTC
Reproduced in Build 200811250201
Steps as in issue description.
Comment 4 J Bachorik 2008-11-26 11:16:59 UTC
fixed - http://hg.netbeans.org/profiler-main/rev/ea279fcf0d8f
The previous fix was not complete - it is necessary to hold a strong reference to a Lookup.Result if one wants to listen
for changes.
Comment 5 Quality Engineering 2008-11-27 05:31:37 UTC
Integrated into 'main-golden', will be available in build *200811270201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/ea279fcf0d8f
User: Jaroslav Bachorik <yardus@netbeans.org>
Log: #147348 - Profile/Profile Other menu not refreshed correctly
Lookup.Result needs to be held stronlgy in order not to be GCed - registering a listener is not enough
Comment 6 Rashid Urusov 2008-12-01 13:49:50 UTC
VERIFIED in Build 200812010201
Comment 7 pgebauer 2008-12-18 14:48:43 UTC
The fix has been ported into the release65_fixes repository.

http://hg.netbeans.org/release65_fixes/rev/cbc8d2033544
Comment 8 Rashid Urusov 2009-01-22 12:40:04 UTC
Changed Status whiteboard


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo