Last Comment Bug 793599 - convert mailnews/base/prefs/content/am-junk.js to Services.jsm
: convert mailnews/base/prefs/content/am-junk.js to Services.jsm
Status: RESOLVED FIXED
:
Product: MailNews Core
Classification: Components
Component: Account Manager (show other bugs)
: Trunk
: All All
: -- trivial (vote)
: Thunderbird 19.0
Assigned To: :aceman
:
Mentors:
Depends on: 725488
Blocks: 720356 729147
  Show dependency treegraph
 
Reported: 2012-09-24 00:14 PDT by :aceman
Modified: 2012-10-19 17:19 PDT (History)
2 users (show)
ryanvm: in‑testsuite-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
patch (7.23 KB, patch)
2012-10-08 13:07 PDT, :aceman
iann_bugzilla: review+
mconley: review+
Details | Diff | Splinter Review

Description :aceman 2012-09-24 00:14:53 PDT
var fileLocator = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties);

  gPrefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService)
(This can be removed altogether as it is not used after bug 725488.)
Comment 1 :aceman 2012-09-24 00:21:44 PDT
Also fix the header to:
/* -*- Mode: Java; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
Comment 2 :aceman 2012-10-08 13:07:48 PDT
Created attachment 669256 [details] [diff] [review]
patch
Comment 3 Mike Conley (:mconley) - (Needinfo me!) 2012-10-10 10:57:23 PDT
Comment on attachment 669256 [details] [diff] [review]
patch

Review of attachment 669256 [details] [diff] [review]:
-----------------------------------------------------------------

Great cleanup, aceman!

::: mailnews/base/prefs/content/am-junk.js
@@ +193,5 @@
>  function updateJunkTargetsAndRetention() {
>    onCheckItem("server.moveTargetMode", ["server.moveOnSpam"]);
>    updateJunkTargets();
>    onCheckItem("server.purgeSpam", ["server.moveOnSpam"]);
> +  document.getElementById("purgeLabel").disabled =

Why was this moved? If there wasn't a good reason, put it back please. :)

@@ +291,4 @@
>  
>    while (entries.hasMoreElements())
>    {
> +    let entry = entries.nextFile;

Nice cleanup in here.
Comment 4 :aceman 2012-10-10 11:47:10 PDT
(In reply to Mike Conley (:mconley) from comment #3)
> ::: mailnews/base/prefs/content/am-junk.js
> @@ +193,5 @@
> >  function updateJunkTargetsAndRetention() {
> >    onCheckItem("server.moveTargetMode", ["server.moveOnSpam"]);
> >    updateJunkTargets();
> >    onCheckItem("server.purgeSpam", ["server.moveOnSpam"]);
> > +  document.getElementById("purgeLabel").disabled =
> 
> Why was this moved? If there wasn't a good reason, put it back please. :)

This is intentional and just fixes a minor problem with patch from bug 725488.
Comment 5 Ryan VanderMeulen [:RyanVM] 2012-10-19 17:19:20 PDT
https://hg.mozilla.org/comm-central/rev/373ae165b4ce

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