Closed Bug 361698 Opened 18 years ago Closed 18 years ago

Navigation menuitems don't work in the sidebar's context menu

Categories

(Firefox :: General, defect, P3)

defect

Tracking

()

RESOLVED FIXED
Firefox 3 alpha2

People

(Reporter: asaf, Assigned: asaf)

References

Details

Attachments

(1 file, 2 obsolete files)

Navigation menuitems (Back/Forward/Reload/Stop) don't work in the sidebar's context menu
Status: NEW → ASSIGNED
Priority: -- → P3
Blocks: 281490
Attached patch patch (obsolete) — Splinter Review
I will fix the stop command enabled state in bug 361686. I didn't bother tracking about:blank navigations for disabling the Reload command.
Attachment #246443 - Flags: review?(gavin.sharp)
Comment on attachment 246443 [details] [diff] [review] patch This currently breaks because MOZ_PLACES is now on, so Ci/Cc/Cr are no longer defined in browser.js, which means they aren't defined in web-panels.xul's scope. We need to fix that somehow... >Index: browser/base/content/web-panels.js > function loadWebPanel(aURI) { >+ var panelBrowser = getPanelBrowser; oops? >Index: browser/base/content/web-panels.xul > <popupset id="mainPopupSet"> > <popup id="contentAreaContextMenu" > onpopupshowing="if (event.target != this) return true; gContextMenu = new nsContextMenu(this, document.getElementById('web-panels-browser')); return gContextMenu.shouldDisplay;" This can use getPanelBrowser() too.
Attachment #246443 - Flags: review?(gavin.sharp) → review-
Attached patch patch (obsolete) — Splinter Review
Attachment #246443 - Attachment is obsolete: true
Attachment #249535 - Flags: review?(gavin.sharp)
Whiteboard: [needs review gavin]
Comment on attachment 249535 [details] [diff] [review] patch The sidebar context menu is still broken because of Cc/Ci not being defined. For now, we should probably just add |var Cc = Components.classes; var Ci = Components.interfaces;| to the top of web-panels.js, but we should figure out a better long term solution. r=me with that change for now.
Attachment #249535 - Flags: review?(gavin.sharp) → review+
Comment on attachment 249535 [details] [diff] [review] patch >Index: browser/base/content/web-panels.js > function loadWebPanel(aURI) { >+ if (gLoadFired) { >+ panelBrowser.webNavigation.loadURI(aURI, nsIWebNavigation.LOAD_FLAGS_NONE, >+ null, null, null); Nit: indentation is wrong here (needs two more spaces).
I would rather overlay it with placesOverlay.js so we nsContextMenu can depend on places-functionality.
placesOverlay.xul
Attached patch patchSplinter Review
Attachment #249535 - Attachment is obsolete: true
Attachment #253465 - Flags: review?(gavin.sharp)
Attachment #253465 - Flags: review?(gavin.sharp) → review+
mozilla/browser/base/content/browser.js 1.758 mozilla/browser/base/content/nsContextMenu.js 1.7 mozilla/browser/base/content/web-panels.js 1.17 mozilla/browser/base/content/web-panels.xul 1.20
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Whiteboard: [needs review gavin]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: