Closed Bug 410433 Opened 17 years ago Closed 17 years ago

Applications page in Options doesn't work on OS/2 (shell-service class missing)

Categories

(Firefox :: Settings UI, defect)

x86
OS/2
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: mozilla, Assigned: mozilla)

Details

Attachments

(1 file, 1 obsolete file)

Mozilla/5.0 (OS/2; U; Warp 4.5; en-US; rv:1.9b3pre) Gecko/2007123119 Minefield/3.0b3pre

When I call up the Applications page of Firefox on OS/2 I don't get any entries but instead the following messages on the error console:

Error: Cc['@mozilla.org/browser/shell-service;1'] is undefined
Source File: chrome://browser/content/preferences/applications.js
Line: 441
Error: gApplicationsPane is undefined
Source File: chrome://global/content/bindings/preferences.xml
Line: 669

I think we never implemented the shell service class on OS/2 because it wasn't necessary before.
That code should probably either fail gracefully, or be ifdefed HAVE_SHELL_SERVICE. I'll quickly review any patches, I should have caught this in the initial review!
Keywords: helpwanted
Attached patch fix (obsolete) — Splinter Review
Thanks for the hint, didn't know about HAVE_SHELL_SERVICE. Not sure at the moment if null is the correct syntax for this in JS but it works without giving any other warnings when clicking around on the entries of the application prefpane.
Assignee: nobody → mozilla
Status: NEW → ASSIGNED
Attachment #295154 - Flags: review?(gavin.sharp)
Keywords: helpwanted
Hmm, I suppose this works because all uses of _shellSvc are in try/catch blocks (because getting defaultFeedReader might throw). I think it would be clearer to also put the users of _shellSvc in ifdefs.
Keywords: helpwanted
Attached patch fix v2Splinter Review
I had thought that the try/catch blocks around were there for this purpose but OK. This version with additional ifdefs works fine, too.
Attachment #295164 - Flags: review?(gavin.sharp)
Attachment #295154 - Attachment is obsolete: true
Attachment #295154 - Flags: review?(gavin.sharp)
Attachment #295164 - Flags: review?(gavin.sharp) → review+
Attachment #295164 - Flags: approval1.9?
Attachment #295164 - Flags: approval1.9? → approval1.9+
Patch "fix v2" checked into trunk. Thanks for the help!
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: