Allow RemotePageManager to accept an array of URLs

RESOLVED FIXED in Firefox 57

Status

()

enhancement
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: k88hudson, Assigned: ahillier)

Tracking

unspecified
Firefox 57
Points:
---

Firefox Tracking Flags

(firefox57 fixed)

Details

Attachments

(1 attachment)

(Reporter)

Description

2 years ago
For Activity Stream, we need to be able to target messages from both about:newtab and about:home; it would be great if we could configure the RemotePageManager to listen to both.
Assignee: nobody → ahillier
(Assignee)

Updated

2 years ago
Attachment #8897454 - Flags: review?(dtownsend)

Comment 2

2 years ago
mozreview-review
Comment on attachment 8897454 [details]
Bug 1390282 - Allow RemotePageManager to accept an array of URLs

https://reviewboard.mozilla.org/r/168750/#review174084

I'd like to see some tests for this please.

::: toolkit/modules/RemotePageManager.jsm:67
(Diff revision 1)
> - * messages from all loaded pages from the requested url.
> + * messages from all loaded pages from the requested urls.
>   */
> -this.RemotePages = function(url) {
> -  this.url = url;
> +this.RemotePages = function(urls) {
> +  this.urls = Array.isArray(urls) ? urls : [urls];
> +  // In case anyone is still using .url property
> +  this.url = this.urls[0];

Do we have anyone in-tree using this? If not let's just remove it.
Attachment #8897454 - Flags: review?(dtownsend)

Comment 3

2 years ago
ahillier, what's the plan with having RemotePages take an array? Will AboutNewTab be updated to register both about:home and about:newtab? I suppose registering the existing about:home should effectively be a no-op as that page isn't listening for activity stream messages anyway.. ?
Flags: needinfo?(ahillier)
(Assignee)

Comment 4

2 years ago
Mardak: Yeah, with this patch and with AboutNewTab registering both pages, setting ActivityStream as the home page in AboutRedirector gives a build with a working ActivityStream home page.
Flags: needinfo?(ahillier)
Comment hidden (mozreview-request)

Comment 6

2 years ago
mozreview-review
Comment on attachment 8897454 [details]
Bug 1390282 - Allow RemotePageManager to accept an array of URLs

https://reviewboard.mozilla.org/r/168750/#review174248
Attachment #8897454 - Flags: review?(dtownsend) → review+

Comment 7

2 years ago
Pushed by khudson@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7eed04597d5e
Allow RemotePageManager to accept an array of URLs r=mossop

Comment 8

2 years ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/7eed04597d5e
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 57
You need to log in before you can comment on or make changes to this bug.