Closed Bug 1684656 Opened 3 years ago Closed 3 years ago

Remaining conversion to Services.jsm in SeaMonkey code

Categories

(SeaMonkey :: General, task)

Tracking

(seamonkey2.53+ fixed, seamonkey2.57esr? affected)

RESOLVED FIXED
seamonkey 2.83
Tracking Status
seamonkey2.53 + fixed
seamonkey2.57esr ? affected

People

(Reporter: iannbugzilla, Assigned: iannbugzilla)

Details

(Whiteboard: SM2.53.7)

Attachments

(5 files)

There are still places where the SeaMonkey code can be switched to use Services.jsm

[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.7
Risk to taking this patch (and alternatives if risky): something might break
String changes made by this patch: none

Attachment #9195036 - Flags: review?(frgrahl)
Attachment #9195036 - Flags: approval-comm-release?
Attachment #9195036 - Flags: approval-comm-esr60?

[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.7
Risk to taking this patch (and alternatives if risky): things might break
String changes made by this patch: none

Attachment #9195037 - Flags: review?(frgrahl)
Attachment #9195037 - Flags: approval-comm-release?
Attachment #9195037 - Flags: approval-comm-esr60?

[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.7
Risk to taking this patch (and alternatives if risky): some things might not work
String changes made by this patch: none

Attachment #9195063 - Flags: review?(frgrahl)
Attachment #9195063 - Flags: approval-comm-release?
Attachment #9195063 - Flags: approval-comm-esr60?

[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.7
Risk to taking this patch (and alternatives if risky): some things might break
String changes made by this patch: none

Attachment #9195064 - Flags: review?(frgrahl)
Attachment #9195064 - Flags: approval-comm-release?
Attachment #9195064 - Flags: approval-comm-esr60?

[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.7
Risk to taking this patch (and alternatives if risky): minimal
String changes made by this patch: none

Attachment #9195066 - Flags: review?(frgrahl)
Attachment #9195066 - Flags: approval-comm-release?
Attachment #9195066 - Flags: approval-comm-esr60?

Comment on attachment 9195063 [details] [diff] [review]
1684656-services-base-2537.patch

suite/base/content/safeMode.js
+const appStartup = Services.startup;

Do we need the const? Only used in 3 places and not hot code. Same in content/viewApplyThemeOverlay.js.

r/a+ either way. LGTM

Attachment #9195063 - Flags: review?(frgrahl)
Attachment #9195063 - Flags: review+
Attachment #9195063 - Flags: approval-comm-release?
Attachment #9195063 - Flags: approval-comm-release+
Attachment #9195063 - Flags: approval-comm-esr60?
Attachment #9195063 - Flags: approval-comm-esr60+

Comment on attachment 9195064 [details] [diff] [review]
1684656-services-bindings-2537.patch

suite/components/bindings/notification.xml
const nsIPermissionManager = Ci.nsIPermissionManager;

The patch cleans out a few uses of this. There are still some other "const nsI* = Ci.nsI*" left. Would it make sense to remove/replace them too?

r/a+ either way. LGTM

Attachment #9195064 - Flags: review?(frgrahl)
Attachment #9195064 - Flags: review+
Attachment #9195064 - Flags: approval-comm-release?
Attachment #9195064 - Flags: approval-comm-release+
Attachment #9195064 - Flags: approval-comm-esr60?
Attachment #9195064 - Flags: approval-comm-esr60+

Comment on attachment 9195037 [details] [diff] [review]
1684656-services-browser-2537.patch

/browser/tabbrowser.xml

Needs "Servies.uriFixup." typo fixed. Otherwise LGTM

Attachment #9195037 - Flags: review?(frgrahl)
Attachment #9195037 - Flags: review+
Attachment #9195037 - Flags: approval-comm-release?
Attachment #9195037 - Flags: approval-comm-release+
Attachment #9195037 - Flags: approval-comm-esr60?
Attachment #9195037 - Flags: approval-comm-esr60+

Comment on attachment 9195066 [details] [diff] [review]
1684656-services-components-2537.patch

suite/components/helpviewer/content/help.js

NIT indention off by 1:

function log(aText) {
...

  • Services.console.logStringMessage(aText);

components/profile/content/profileSelection.js

  • var ps = Services.prompt;

I would probably just use Services.prompt. everywhere because not hot code but just a personal preference. Fine with me as is.

LGTM r/a+

Attachment #9195066 - Flags: review?(frgrahl)
Attachment #9195066 - Flags: review+
Attachment #9195066 - Flags: approval-comm-release?
Attachment #9195066 - Flags: approval-comm-release+
Attachment #9195066 - Flags: approval-comm-esr60?
Attachment #9195066 - Flags: approval-comm-esr60+

Comment on attachment 9195036 [details] [diff] [review]
1684656-services-mailnews-2537.patch

suite/mailnews/content/mailViewList.js

  • let ps = Services.prompt;
    Seems only used in one place so I would use it directly.

LGTM either way r/a+

Attachment #9195036 - Flags: review?(frgrahl)
Attachment #9195036 - Flags: review+
Attachment #9195036 - Flags: approval-comm-release?
Attachment #9195036 - Flags: approval-comm-release+
Attachment #9195036 - Flags: approval-comm-esr60?
Attachment #9195036 - Flags: approval-comm-esr60+

(In reply to Frank-Rainer Grahl (:frg) from comment #6)

Comment on attachment 9195063 [details] [diff] [review]
1684656-services-base-2537.patch

suite/base/content/safeMode.js
+const appStartup = Services.startup;

Do we need the const? Only used in 3 places and not hot code. Same in content/viewApplyThemeOverlay.js.

r/a+ either way. LGTM

Matching how it is done in mozilla code, so easier to port patches (and makes it more readable).

(In reply to Frank-Rainer Grahl (:frg) from comment #7)

Comment on attachment 9195064 [details] [diff] [review]
1684656-services-bindings-2537.patch

suite/components/bindings/notification.xml
const nsIPermissionManager = Ci.nsIPermissionManager;

The patch cleans out a few uses of this. There are still some other "const nsI* = Ci.nsI*" left. Would it make sense to remove/replace them too?

r/a+ either way. LGTM

I did think about that, but decided it would be better in a separate patch so as not to confuse this one.

(In reply to Frank-Rainer Grahl (:frg) from comment #9)

Comment on attachment 9195066 [details] [diff] [review]
1684656-services-components-2537.patch

components/profile/content/profileSelection.js

  • var ps = Services.prompt;

I would probably just use Services.prompt. everywhere because not hot code but just a personal preference. Fine with me as is.

I think using ps makes the code more readable (especially when using vi at 80 character width).

(In reply to Frank-Rainer Grahl (:frg) from comment #10)

Comment on attachment 9195036 [details] [diff] [review]
1684656-services-mailnews-2537.patch

suite/mailnews/content/mailViewList.js

  • let ps = Services.prompt;
    Seems only used in one place so I would use it directly.

Yeah, probably okay, only makes a minor difference in readability.

Pushed by frgrahl@gmx.net:
https://hg.mozilla.org/comm-central/rev/0ade240416a7
Remaining conversion to Services.jsm in SeaMonkey code - mailnews part. r=frg
https://hg.mozilla.org/comm-central/rev/11d15386eaa3
Remaining conversion to Services.jsm in SeaMonkey code - browser part. r=frg
https://hg.mozilla.org/comm-central/rev/8e38a8558338
Remaining conversion to Services.jsm in SeaMonkey code - base part. r=frg
https://hg.mozilla.org/comm-central/rev/8888ab3dadb1
Remaining conversion to Services.jsm in SeaMonkey code - bindings part. r=frg
https://hg.mozilla.org/comm-central/rev/5ca19d5395ff
Remaining conversion to Services.jsm in SeaMonkey code - components part. r=frg

Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Whiteboard: SM2.53.7
Target Milestone: --- → seamonkey 2.83

https://gitlab.com/seamonkey-project/seamonkey-2.53-comm/-/commit/bc253331eb48c29eaf93f571f9dee4541624905d
Remaining conversion to Services.jsm in SeaMonkey code - mailnews part. r=frg a=frg
https://gitlab.com/seamonkey-project/seamonkey-2.53-comm/-/commit/d20df46f03cd85488bf6752a7b07a6316621583d
Remaining conversion to Services.jsm in SeaMonkey code - browser part. r=frg a=frg
https://gitlab.com/seamonkey-project/seamonkey-2.53-comm/-/commit/91a027a2b6aafb7a1e4a933b099d955855ea1010
Remaining conversion to Services.jsm in SeaMonkey code - base part. r=frg a=frg
https://gitlab.com/seamonkey-project/seamonkey-2.53-comm/-/commit/94986585cabd1c7bb7947163aecac4afc2bb0f59
Remaining conversion to Services.jsm in SeaMonkey code - bindings part. r=frg a=frg
https://gitlab.com/seamonkey-project/seamonkey-2.53-comm/-/commit/dd3294eca6b27231d76c697f774fe9af47a9bbe5
Remaining conversion to Services.jsm in SeaMonkey code - components part. r=frg a=frg
Target 2.53.7

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: