CLOSED TREE
Backed out changeset 2d42350d209a (bug 1203330)
Backed out changeset 3a12c51c3eca (bug 1203330)
Backed out changeset 31fac390e15d (bug 1203330)
To verify, run the test in isolation:
mach mochitest browser/components/extensions/test/browser/browser_ext_tabs_executeScript_no_create.js
Without the fix, the test fails in e10s; with the fix, the test passes.
MozReview-Commit-ID: Imf0Ue7ORHd
--HG--
extra : rebase_source : a34ba67cf05f56dc360d46a6e30f0b0083a5a8a4
This could still use a fair amount of additional cleanup.
MozReview-Commit-ID: BteBFMlZCsy
--HG--
extra : rebase_source : cc0dc4854167c49593a4f4046c3d6527afe1eddf
extra : source : b0521588011d866ee6b2019ee71654768b9e7677
This could still use a fair amount of additional cleanup.
MozReview-Commit-ID: BteBFMlZCsy
--HG--
extra : rebase_source : 8b37748c25cc5c871ebac3eaab34ae6780175f37
In one of the previous patches, the viewType of popup changed from
"popup" to "tab". As a result it was closed by the `page-shutdown`
event handler in ext-tabs.js. This prevents that from happening.
Also added a test that checks whether the options page type is a tab, to
prevent future regressions.
MozReview-Commit-ID: 3Qcf08PgNqb
--HG--
extra : rebase_source : c4b89d122df52a7280ff5818903cb1d8737fb31c
Accessing <browser> in ContentChild does not work when extensions run in
a separate process.
MozReview-Commit-ID: EK0aOYeGaZ5
--HG--
extra : rebase_source : 359cb1f9022b8097d27aa74a30e133c4a7e7c742
"viewType" is more easily searchable and not as ambiguous as "type".
MozReview-Commit-ID: 8sG4qagFCBu
--HG--
extra : rebase_source : 39d76379996e631b9fc33f0c77d565cf302b9df9
Call tabs.create immediately after the tab is created without delay to
reduce the chance of losing tabs.onUpdated events.
If needed, the tab waiting is done by `executeScript`, etc.
MozReview-Commit-ID: 7A1zH99zafK
--HG--
extra : rebase_source : 56fb363f45040e76a120e6a3de8feaad1575c337
- Use the frame's message manager to direct messages via the
ProxyMessenger to the right tab instead of directly to the tab.
- Put the implementation in a separate file that is only loaded in
child processes (in the future).
- Explicitly list all addon-process specific files in a new category
instead of reusing the content one.
MozReview-Commit-ID: 8oIMx9ol7Tl
--HG--
extra : rebase_source : f93805ecdf44d4607dffc20ffe1cf0cbeb8c86be
- Introduce a proxy for IPC messages to allow the following APIs
to be run out-of-process (ProxyMessenger):
* runtime.connect
* runtime.sendMessage
* tabs.connect
* tabs.sendMessage
* runtime.onConnect
* runtime.onMessage
- Update getSender in ext-tabs, make it independent of the context
(in particular do not throw an error when a message is received while
the tab is gone), and move it from MessageChannel to ProxyMessenger to
make sure that it works in webext-oop. MessageChannel lives in a child
process, whereas the TabManager (used by getSender) requires data from
the main process.
- Set the third parameter of `addMessageListener` to true in some places
to make sure that messages get delivered even after unloading the
context. This is needed for the next two points.
- Put the `messageManager` property in BaseContext, and let it be set by
`setContentWindow` - runtime.sendMessage/connect and tabs.sendMessage/
connect depends on this property, and using the frame message manager
makes sense.
- Unconditionally use the frame message manager in
runtime.sendMessage/connect instead of sometimes the cpmm.
MozReview-Commit-ID: 4QkPnlMOkjS
--HG--
extra : rebase_source : f2c753a9d396e4b5c40e46cd926024e664372002
- Add `envType` to BaseContext.
- Pass an explicit envType to all `registerSchemaAPI` invocations.
- The factories passed to `registerSchemaAPI` will be split up later, so
that content scripts (`content_child`) and addon pages can share
common implementations.
- The factories that implement the addon API will also be split up,
to separate code running in the main process (`addon_parent`) from
code running in a child process (`addon_child`).
- Remove the use of a hardcoded list of `namespaces` from ProxyContext.
Now `envType` is used to specify whether an API should be activated.
MozReview-Commit-ID: Jiff8HIwG92
--HG--
extra : rebase_source : 946a3c0009a4e3223c2d10044b3099a94c845394
ExtensionContext in Extension.jsm has |extension| as an instance member,
so use it instead of passing |extension| to registerSchemaAPI's
callback.
And to make sure that this pattern also works in content processes, move
the |extension| member to BaseContext.
MozReview-Commit-ID: BgsGGCPQxJR
--HG--
extra : rebase_source : 7aa9fb7a53e057e8d3d8c477bd6821f8344c571a