Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 312121 - [breakpoints] Show fullpath not working in breakpoints view for other breakpoint type
Summary: [breakpoints] Show fullpath not working in breakpoints view for other breakpo...
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug (show other bugs)
Version: 7.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 8.0   Edit
Assignee: Patrick Chuong CLA
QA Contact: Ken Ryall CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-07 15:50 EDT by Patrick Chuong CLA
Modified: 2011-02-10 09:12 EST (History)
3 users (show)

See Also:
marc.khouzam: review+
john.cortell: review+


Attachments
patch (2.37 KB, patch)
2011-02-03 16:32 EST, Patrick Chuong CLA
pchuong: iplog-
Details | Diff
reworked patch (3.28 KB, patch)
2011-02-04 10:32 EST, Patrick Chuong CLA
pchuong: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Chuong CLA 2010-05-07 15:50:43 EDT
Build Identifier: I20100312-1448

The show fullpath in the breakpoints view should be able to handle breakpoint that are not ICBreakpoint type. This option is disabled if there is not ICBreakpoint added to the platform breakpoint manager.

It would be nice if there is no restriction whether a breakpoint is ICBreakpoitn type or any breakpoint exist at all in the breakpoint manager, or at lease have an interface where breakpoint can implement to support this action's enablement.

Reproducible: Always
Comment 1 Patrick Chuong CLA 2011-02-03 16:32:06 EST
Created attachment 188278 [details]
patch

This patch introduced a property in the breakpoint. Another way is to introduce an interface. But since the SHOW_FULL_PATHS_PREF_KEY perference is internal, I didn't want to go with the interface approach. Infact, the interface would just be a blank interface, as long as the breakpoint implements the new interface, then fullpath action will be enabled.

John, Marc, what do you think?
Comment 2 Marc Khouzam CLA 2011-02-03 22:24:02 EST
For more information, you can look at bug 248627 comment 15 (which did not get implemented) and bug 248627 comment 22 (which was implemented).

I think the solution makes sense.

Comments on the patch:
1- the change should be in ShowFullPathsAction.java instead of ViewFilterAction.
2- ATTR_SUPPORT_FULL_PATHS should have full name e.g. org.eclipse.cdt....
Comment 3 John Cortell CLA 2011-02-04 09:20:46 EST
The comment on the new attribute should note that the show full path *action* is always enabled for ICBreakpoints, whether or not the attribute is present. It should also note that the action merely toggles a CDebugModelPresentation attribute, and that presentation may or may not be used for custom breakpoints. In other words, enabling the action alone does not necessarily provide the expected "show full path" behavior for a custom breakpoint.
Comment 4 Patrick Chuong CLA 2011-02-04 10:32:07 EST
Created attachment 188330 [details]
reworked patch

Thanks for reviewing this patch guys, I have updated the patch with your suggestions. I'll commit the patch after M5 is posted.
Comment 5 Patrick Chuong CLA 2011-02-07 14:50:44 EST
Committed to HEAD.