Closed Bug 1311180 Opened 8 years ago Closed 8 years ago

Switch mozAddonManager over to frame message managers

Categories

(Toolkit :: Add-ons Manager, defect)

51 Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla52
Tracking Status
firefox52 --- fixed

People

(Reporter: aswan, Assigned: aswan)

References

Details

Attachments

(1 file)

mozAddonManager currently uses process message managers but to lay the groundwork for showing notifications during installations, it needs to switch over to using frame message managers so that we can easily get a handle on the window/browser corresponding to individual requests.
Comment on attachment 8802301 [details]
Bug 1311180 Switch mozAddonManager to frame message managers

whoops, pushed too fast, i want to clean this up a bit more before getting it reviewed.
Attachment #8802301 - Flags: review?(rhelmer)
Rob, I got a little carried away with some refactoring to ES6 classes that isn't strictly part of the subject of this bug.  If you want me to break that work into a separate commit or even a separate bug let me know...
Comment on attachment 8802301 [details]
Bug 1311180 Switch mozAddonManager to frame message managers

https://reviewboard.mozilla.org/r/86722/#review86034

::: toolkit/mozapps/extensions/amWebAPI.js:118
(Diff revision 3)
> - * wrapping the returned object or error appropriately for the page.
> - * We must take care only to wrap and reject with errors that are meant
> - * to be visible to content, and not internal errors.
> - * This function is a wrapper to handle the common bits.
> - *
> - *   apiRequest is the name of the command to invoke in the parent process
> +  // This helper method ensures that:
> +  //  - Returned Promise objects are from the content window
> +  //  - Rejected Promises have Error objects from the content window
> +  //  - Only non-internal errors are exposed to the caller
> +  //
> +  // apiRequest is the name of the command to invoke in the parent process

Could this be a jsdoc-style comment?
Attachment #8802301 - Flags: review?(rhelmer) → review+
Pushed by aswan@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/098bb827dd32
Switch mozAddonManager to frame message managers r=rhelmer
https://hg.mozilla.org/mozilla-central/rev/098bb827dd32
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: