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

RESOLVED FIXED

Status

()

Firefox
Preferences
RESOLVED FIXED
11 years ago
11 years ago

People

(Reporter: Peter Weilbacher, Assigned: Peter Weilbacher)

Tracking

Trunk
x86
OS/2
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

11 years ago
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
(Assignee)

Comment 2

11 years ago
Created attachment 295154 [details] [diff] [review]
fix

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
Keywords: helpwanted
(Assignee)

Comment 4

11 years ago
Created attachment 295164 [details] [diff] [review]
fix v2

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+
(Assignee)

Updated

11 years ago
Attachment #295164 - Flags: approval1.9?

Updated

11 years ago
Attachment #295164 - Flags: approval1.9? → approval1.9+
(Assignee)

Comment 5

11 years ago
Patch "fix v2" checked into trunk. Thanks for the help!
Status: ASSIGNED → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.