| Summary: | [Compatibility] 'Source' and 'Refactor' menus disappear after installing Photran | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] Platform | Reporter: | Remy Suen <remy.suen> | ||||||||
| Component: | UI | Assignee: | Remy Suen <remy.suen> | ||||||||
| Status: | VERIFIED FIXED | QA Contact: | Paul Webster <pwebster> | ||||||||
| Severity: | critical | ||||||||||
| Priority: | P3 | CC: | pwebster | ||||||||
| Version: | 4.1 | ||||||||||
| Target Milestone: | 4.2 M5 | ||||||||||
| Hardware: | All | ||||||||||
| OS: | All | ||||||||||
| Whiteboard: | |||||||||||
| Bug Depends on: | |||||||||||
| Bug Blocks: | 344260 | ||||||||||
| Attachments: |
|
||||||||||
|
Description
Remy Suen
This is with I20110614-1545. Can you see them when the Java Editor is active? PW (In reply to comment #2) > Can you see them when the Java Editor is active? There's not a problem there. The 'Source' menu doesn't have separators though (you saw this on my screen yesterday). This snippet will induce the problem in an inner.
<extension point="org.eclipse.ui.menus">
<menuContribution
locationURI="menu:org.eclipse.ui.main.menu?after=edit">
<menu
label="&Source"
id="org.eclipse.jdt.ui.source.menu">
<visibleWhen checkEnabled="false">
<!-- ... -->
</visibleWhen>
<separator name="commentGroup" />
</menu>
</menuContribution>
</extension>
Created attachment 203030 [details]
ContributionRecord patch v1
When we find the same menu, we just reference it directly and don't actually create any OR clauses between them. This is just an illustrative patch as we should also be considering the cloned one's expression (if any) since this patch only merges the pre-existing menu's expression with the menu contribution's.
In any case, the problem in question goes away with this patch.
Created attachment 209560 [details]
ContributionRecord patch v2
Updates the patch against master as well as adding code to exclude expressions if one of the two elements don't have an expression defined.
Created attachment 209752 [details]
ContributionRecord patch v3
The patch couldn't be applied cleanly for whatever reasons. This one should work.
(In reply to comment #7) > Created attachment 209752 [details] > ContributionRecord patch v3 Patch pushed to master. http://git.eclipse.org/c/platform/eclipse.platform.ui.git/commit/?id=4bdf5a7dd4ea646015bf114a8fa18f0a5974dd7e Verified with I20120123-2200 on Windows 7 that the 'Source' and 'Refactor' menus no longer magically disappear! |