Граф коммитов

74 Коммитов

Автор SHA1 Сообщение Дата
JerryShih fa00bf1ff1 Bug 1310681 - do not use devtools colorUtils in browser. r=kmag,tromey
MozReview-Commit-ID: 3qbsBGC7Lt6

--HG--
extra : rebase_source : 3af07b87a2c07fb0283a46c144a8104445da918b
2016-10-21 10:03:58 -04:00
Tomislav Jovanovic a668cce095 bug 1320439 - Fix submenus in page_action, browser_action contextMenus, r=kmag
MozReview-Commit-ID: AGhu1tbofrB

--HG--
extra : rebase_source : 1bee9519a2456e5cc328db4f879cce2d1a071963
2016-11-28 03:15:02 +01:00
Tomislav Jovanovic 92b6927b24 bug 1253418 - implement contextMenu page_action and browser_action contexts r=kmag
MozReview-Commit-ID: Ftp77zmxo4B

--HG--
extra : rebase_source : ed46fe948f0898e13dcc551721d56c5151a4bc4c
2016-11-09 21:03:33 +01:00
Kris Maglione 5afec92baa Bug 1315575: Part 3 - Convert ImageData objects at the binding layer, and remove unnecessary content bindings. r=aswan
MozReview-Commit-ID: CjqXRiFcMWp

--HG--
extra : rebase_source : 5e9a839c8193699083e304c27138b876675ea8a7
2016-11-06 17:35:07 -08:00
Bob Silverberg 822f3154e2 Bug 1310019 - web extension API : chrome.tabs.query doesn’t get tabs title at first call, r=kmag
Add permission to the active tab on mousedown in ext-browserAction.js

MozReview-Commit-ID: H0oXQElppo7

--HG--
extra : rebase_source : 09ac61c479b57cb487bd81855dd9acae27537f39
extra : source : 935c49da3488b4270cf45447451d6bb0abe3f369
2016-10-31 17:30:16 -04:00
Kris Maglione e6b9c2b457 Bug 1307551: Don't attempt to pre-load popup for disabled browserAction. r=bsilverberg
MozReview-Commit-ID: 8imoqD1Xoja

--HG--
extra : rebase_source : 8f0fa63b813f77bc8cde28aa1878c880ac96a3df
extra : amend_source : dee66aef3c55b737fb8f946d9184fc82794f0ff5
2016-11-01 09:41:30 -07:00
Rob Wu fcb710d311 Bug 1287007 - Move part of browserAction and pageAction to child r=billm
And remove redundant `Promise.resolve()` because it is the default
for async functions.

setIcon is not supported on Android, so there was no need to change
mobile/android/components/extensions/ext-pageAction.js.

MozReview-Commit-ID: 94ebaJFxLAi

--HG--
extra : rebase_source : 20466181501b264ba33fc8ab61fdf2bed20f9eef
2016-09-11 04:18:35 -07:00
Rob Wu 4ec02709a6 Bug 1287007 - Mark all browserAction methods as async r=billm
E.g. browser.browserAction.enable(...).then(...) now works as expected.
Removed a Promise.resolve() because that is the default.

MozReview-Commit-ID: 4Shxtn0rjYH

--HG--
extra : rebase_source : 2f2516686c7d79094fac5ff1176c1c9310f1abe5
2016-09-02 14:22:09 -07:00
Kris Maglione 062bc47b74 Bug 1287209: Handle popup and options browser resizing using a frame script. r=aswan
MozReview-Commit-ID: DIfynklqrus

--HG--
extra : source : 68806639c03110bfb67dd6c705a5441a917afcd6
extra : intermediate-source : cc7503f09572bc49cd2f86184d0d3abc810351c3
2016-10-20 15:27:51 -07:00
Phil Ringnalda ad36def0ad Backed out 2 changesets (bug 1287209) for failures in browser_ext_pageAction_popup_resize.js
Backed out changeset 50dcca551b63 (bug 1287209)
Backed out changeset cc7503f09572 (bug 1287209)

MozReview-Commit-ID: A5q4SnWzgOa
2016-10-20 19:23:33 -07:00
Kris Maglione 1b0cc16a74 Bug 1287209: Handle popup and options browser resizing using a frame script. r=aswan
MozReview-Commit-ID: DIfynklqrus

--HG--
extra : source : 68806639c03110bfb67dd6c705a5441a917afcd6
extra : intermediate-source : 7ea8213113d73fcbdd5160397db9ed4fbe295ee0
extra : histedit_source : 62c8339301d4e1939b5873554d2c751d76a15c22%2C291e31423225845deb0a7785cd06e9f4cec81221
2016-10-20 15:27:51 -07:00
Wes Kocher c405db181b Backed out 2 changesets (bug 1287209) for browser_ext_commands_execute_browser_action.js leaks a=backout
Backed out changeset a6787db4d131 (bug 1287209)
Backed out changeset 7ea8213113d7 (bug 1287209)
2016-10-20 14:37:12 -07:00
Kris Maglione bdc9da3225 Bug 1287209: Handle popup and options browser resizing using a frame script. r=aswan
MozReview-Commit-ID: DIfynklqrus

--HG--
extra : source : 68806639c03110bfb67dd6c705a5441a917afcd6
extra : histedit_source : fa626fa73864633321201ab46e6c08ed1692280b%2C8ac18763ca4bb7f7c40c4b0cd58ca53ddc26618e
2016-10-20 09:57:13 -07:00
Sebastian Hengst 0c23c32b56 Backed out changeset 68806639c031 (bug 1287209) for failing browser-chrome test browser_ext_popup_corners.js. r=backout 2016-10-20 09:17:03 +02:00
Kris Maglione 00de90e4be Bug 1287209: Handle popup and options browser resizing using a frame script. r=aswan
MozReview-Commit-ID: DIfynklqrus

--HG--
extra : rebase_source : fe673f907b56f4d2bdc53be2e37271541c5332d6
2016-10-19 20:19:43 -07:00
Kris Maglione 5fa61868b6 Bug 1246034: Part 1 - [webext] Add a helper function to trigger a browserAction. r=jaws
MozReview-Commit-ID: JUW6oUpWiN4

--HG--
extra : rebase_source : 324a7ece3b7bc550478326b5bd2795599a5ec6bb
2016-09-07 11:05:11 +01:00
Greg Tatum 1e5a5a50e2 Bug 1290988 - Collect devtools/shared/css-* files into a folder. r=tromey
In preparation for the additional files in the `mach generate-css-db`
command, collect the CSS files into a folder.

MozReview-Commit-ID: 9JRVsC2NMK8

--HG--
rename : devtools/shared/css-color-db.js => devtools/shared/css/color-db.js
rename : devtools/shared/css-color.js => devtools/shared/css/color.js
rename : devtools/shared/css-lexer.js => devtools/shared/css/lexer.js
rename : devtools/shared/css-parsing-utils.js => devtools/shared/css/parsing-utils.js
rename : devtools/shared/css-properties-db.js => devtools/shared/css/properties-db.js
extra : rebase_source : 51d8d92db0ae91a7368b109aae9a509ba8012b3f
extra : histedit_source : ee3409615461cba0c656b32fee7f80d4b72a09d1
2016-09-14 10:00:27 -05:00
Sebastian Hengst d11146270a Backed out changeset 1bca17123507 (bug 1290988) for xpcshell failures (test_rewriteDeclarations.js) and devtools failures (browser_styleeditor_syncAddProperty.js). r=backout
--HG--
rename : devtools/shared/css/color-db.js => devtools/shared/css-color-db.js
rename : devtools/shared/css/lexer.js => devtools/shared/css-lexer.js
rename : devtools/shared/css/properties-db.js => devtools/shared/css-properties-db.js
2016-09-13 17:43:44 +02:00
Greg Tatum da1990f19b Bug 1290988 - Collect devtools/shared/css-* files into a folder; r=tromey
In preparation for the additional files in the `mach generate-css-db`
command, collect the CSS files into a folder.

MozReview-Commit-ID: 9JRVsC2NMK8

--HG--
rename : devtools/shared/css-color-db.js => devtools/shared/css/color-db.js
rename : devtools/shared/css-lexer.js => devtools/shared/css/lexer.js
rename : devtools/shared/css-properties-db.js => devtools/shared/css/properties-db.js
extra : rebase_source : b73bbe7fcf8177a25b41ecdd6d6c760ed1472fb7
2016-08-29 11:02:34 -05:00
Rob Wu be3652cd57 Bug 1287010 - Make environment of Context explicit. r=billm
- 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
2016-08-16 15:51:50 -07:00
Kris Maglione e9d8b48ce4 Bug 1259093: Part 3 - Preload browserAction popups to prevent flicker during opening. r=Gijs r=jaws r=bwinton f=mattw
MozReview-Commit-ID: EpAKLV8VPTn

--HG--
extra : rebase_source : 6ce6e622734214c7214fc2ddb7ddb2233fc0c8fd
2016-08-19 12:29:11 -07:00
Rob Wu bacc209644 Bug 1295082 - Put Extension in BaseContext r=kmag
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
2016-08-15 01:04:58 -07:00
Sebastian Hengst 2164cd95c8 Backed out changeset 0ce1cc39aa3d (bug 1295082) for timing out in test_ext_schemas_api_injection.js. r=backout 2016-08-18 16:47:09 +02:00
Rob Wu dfc11d6f00 Bug 1295082 - Put Extension in BaseContext r=kmag
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 : 9a85d95f0c147198938b86c57127f6e7403fd53c
2016-08-15 01:04:58 -07:00
Kris Maglione 4f1b1dda0b Bug 1225215: [webext] Raise the expected errors when given invalid tab IDs. r=aswan
MozReview-Commit-ID: E5G0GmVhzLh

--HG--
extra : rebase_source : 5c6624b9d2d06109a1b047ad48dcac7e9405ee59
extra : amend_source : fb23020f7d2772f56fabc61f2e32f7d9c4c2f52a
2016-02-26 17:56:30 -08:00
Kris Maglione 0dba25a0da Bug 1288979: Always convert badge background color to a ColorTuple. r=aswan
MozReview-Commit-ID: CWmaa9wwQLD

--HG--
extra : rebase_source : aa8eaa19bad2b825c818abd29172f75fa84368dd
2016-08-04 14:50:52 -07:00
Jared Wein 871ed4e3ba Bug 1291855 - Enable the no-else-return rule for eslint. r=Felipe,kmag,mossop
MozReview-Commit-ID: DYOmE6xwMJh

--HG--
extra : rebase_source : bc81b68ea5599fd1815dc34dac7106eef7044483
2016-08-03 18:54:59 -04:00
Pushpankar c6670d980f Bug 1286854 - Replace ownerDocument.defaultView with ownerGlobal in browser/. r=dao
--HG--
extra : rebase_source : 72d50e73baf595840a2aade57ae782e4c40d4c27
2016-07-16 10:20:04 +02:00
Kris Maglione 63c5aef93a Bug 1272222: Use larger icons for browser actions in the menu panel. r=Gijs
MozReview-Commit-ID: 26lmlcrngPk

--HG--
extra : rebase_source : b9d6bfb7669d3cb826ccaa6728e153ad3e3b2b8b
2016-07-13 15:16:00 -07:00
Matthew Wein 569e667c08 Bug 1270742 - Add support for default_icon in chrome.pageAction r=kmag
MozReview-Commit-ID: D9uR0JUXJwx

--HG--
extra : transplant_source : %FC%FBu%0Cboh%DFv%BB%8D%AC%20%ED%A5%E1%3E%DE%126
2016-05-23 15:59:33 -07:00
Kris Maglione c80375c0f9 Bug 1272219: Use 16px icons for BrowserAction buttons, support 18px as a legacy fallback. r=bwinton ui-r=bwinton
MozReview-Commit-ID: 2c0UWR6hITQ

--HG--
extra : rebase_source : 5dd417ba99bb85a50dd1ae87cf2fb5603da07ce8
2016-06-05 21:05:36 -07:00
Kris Maglione a1dac7caad Bug 1279392: [webext] Move API permission definitions to the schemas. r=aswan
MozReview-Commit-ID: 8m7wJrAbFwS

--HG--
extra : source : a00cf073f5c00380d4e42b13bc0cd3146b708845
extra : amend_source : d74ef90e88acbe62e33af3b5b9cf870d5c0a9d3e
2016-06-09 17:44:47 -07:00
Sebastian Hengst f8035f62a8 Backed out changeset a00cf073f5c0 (bug 1279392) for failing mochitest test_ext_contentscript_create_iframe.html at least on Linux x64 opt. r=backout 2016-06-14 13:37:52 +02:00
Kris Maglione b465305345 Bug 1279392: [webext] Move API permission definitions to the schemas. r=aswan
MozReview-Commit-ID: 8m7wJrAbFwS

--HG--
extra : rebase_source : cba877c0ef400917b0b7e5913895e64ebefb34b9
extra : amend_source : 6e943015e3e00854c431cbd653994a6734e66ce4
2016-06-09 17:44:47 -07:00
Blake Winton 6866a9d937 Bug 1269081 - Only apply Firefox's default styles if the add-on author sets "browser_style" to true in the manifest. r=kmag.
MozReview-Commit-ID: JjH0sCkh1U7

--HG--
extra : rebase_source : 92b126d4acd77bb15bb7c952b82d4dd6156d5c2a
2016-05-02 10:59:36 -04:00
Matthew Wein 863d9f6ce1 Bug 1246035 - Add support for _execute_page_action r=kmag
MozReview-Commit-ID: LPQAC7uJTkr
2016-03-14 14:54:57 +01:00
Sebastian Hengst 53b1ca7a7f Backed out changeset 4a92742ac20d and ddf8219182fb (bug 1246035) for failing modified ddf8219182fb on OS X 10.6 opt M(bc2). r=backout 2016-03-25 23:14:25 +01:00
Matthew Wein 6bfb9ef781 Bug 1246035 - Add support for _execute_page_action. r=kmag
MozReview-Commit-ID: LPQAC7uJTkr

--HG--
extra : transplant_source : %9Fc%B4C%C75Nd%40.%EBj%25%8Cg%5B%B3%C0%E5F
2016-03-14 14:54:57 +01:00
Carsten "Tomcat" Book df65ba1904 Backed out changeset 70960616621c (bug 1246035) for eslint failures
--HG--
extra : rebase_source : 1aabe3c342278594617826d065640425eb557b19
2016-03-18 10:04:15 +01:00
Matthew Wein 8b0e3b8eb2 Bug 1246035 - Add support for _execute_page_action. r=kmag
MozReview-Commit-ID: LPQAC7uJTkr

--HG--
extra : transplant_source : %85%1C%3D%2B%EF%E7%02ya%21/ad%A3%A4R%E9%13%0C%13
2016-03-14 14:54:57 +01:00
Kris Maglione dce2b3c2cd Bug 1214955: [webext] Automatically localize all localizable manifest properties. r=billm
MozReview-Commit-ID: 2kvYT44NIE8

--HG--
extra : rebase_source : ebab864b517c2e576dde27cf1439cf2deadb0685
2016-02-29 19:34:49 -08:00
Kris Maglione ba2e5f60f4 Bug 1248855 - [webext] Add "object-curly-spacing" ESLint rule and auto-fix errors. r=billm
MozReview-Commit-ID: BAZ2rRl7eSM
2016-02-16 20:10:00 -08:00
Kris Maglione a2027208b5 Bug 1234020: Part 2g - [webext] Return promises from the browserAction API. r=rpl
--HG--
extra : commitid : GQvpkew9gD
extra : rebase_source : ec53fa009edc8c874895f2f1abf8d896c5dd6753
2016-02-01 18:14:05 -08:00
Kris Maglione 59c0ce29a5 Bug 1217129: Part 5 - [webext] Use CustomizableUI views for BrowserAction popups. r=gijs ui-r=bwinton
This version addresses some popup sizing bugs, and also a few other issues I
ran into when debugging Blake's problems:

 * The standalone popup needs a max width of 800px for Chrome compatibility,
   which is wider than our default max width.

 * I added a flex attribute to our browser so that it fills the entire space
   of the slide-in panel. This is only necessary for browsers with content
   that is shorter than the height of the panel when it gets its desired
   width, but becomes longer when it doesn't, so it didn't show up in my
   initial tests.

 * I also added an extra pixel to the width calculations, since I noticed that
   a lot of single lines of text were unexpectedly wrapping without it. I'll
   look into this more in a follow-up bug.

I also added some comments, and renamed a couple of variables, where things
seemed unclear.

The test changes are mostly just updates to older browser action tests to use
newer helpers, rather than ad-hoc events, to open/close/click the widgets. A
few tests also needed updates to explicitly close the panel when they were
done with it.

--HG--
extra : commitid : BhHv1aZSrBL
extra : rebase_source : 6fe0069ebd2f94b0ffd02ad757a799fbdff9226e
extra : source : 628af985c7eba7e4665a1b62f9a60f6a6fd39822
2016-01-15 15:14:25 -08:00
Kris Maglione 3284cbb0ee Bug 1217129: Part 4b - [webext] Use the extension name as the default title value for browserAction/pageAction popups. r=billm
This brings our behavior closer in line with Chrome's.

--HG--
extra : commitid : DaDofvmQEZW
extra : rebase_source : cbeda3889362511c5002f2710c063a2c83047d3c
extra : source : 7ad8b56958c54787313ecbe60eb1e8fbafb2f376
2016-01-15 21:43:26 -08:00
Carsten "Tomcat" Book cc15740ff7 Backed out 8 changesets (bug 1217129) for test failures in browser_ext_pageAction_context.js
Backed out changeset dc5742de0823 (bug 1217129)
Backed out changeset 106365a3847c (bug 1217129)
Backed out changeset 628af985c7eb (bug 1217129)
Backed out changeset 7ad8b56958c5 (bug 1217129)
Backed out changeset 71f46fe62f59 (bug 1217129)
Backed out changeset 7d8dee4c335b (bug 1217129)
Backed out changeset 3b5fb2845c3b (bug 1217129)
Backed out changeset 93266f211716 (bug 1217129)
2016-01-18 09:08:35 +01:00
Kris Maglione afba49d5ab Bug 1217129: Part 5 - [webext] Use CustomizableUI views for BrowserAction popups. r=gijs ui-r=bwinton
This version addresses some popup sizing bugs, and also a few other issues I
ran into when debugging Blake's problems:

 * The standalone popup needs a max width of 800px for Chrome compatibility,
   which is wider than our default max width.

 * I added a flex attribute to our browser so that it fills the entire space
   of the slide-in panel. This is only necessary for browsers with content
   that is shorter than the height of the panel when it gets its desired
   width, but becomes longer when it doesn't, so it didn't show up in my
   initial tests.

 * I also added an extra pixel to the width calculations, since I noticed that
   a lot of single lines of text were unexpectedly wrapping without it. I'll
   look into this more in a follow-up bug.

I also added some comments, and renamed a couple of variables, where things
seemed unclear.

The test changes are mostly just updates to older browser action tests to use
newer helpers, rather than ad-hoc events, to open/close/click the widgets. A
few tests also needed updates to explicitly close the panel when they were
done with it.

--HG--
extra : commitid : 9OyRnaMTqn8
extra : rebase_source : efd28a49ca5961e2cf545420a81bd19b796d8957
2016-01-15 15:14:25 -08:00
Kris Maglione 5c12caa1dc Bug 1217129: Part 4b - [webext] Use the extension name as the default title value for browserAction/pageAction popups. r=billm
This brings our behavior closer in line with Chrome's.

--HG--
extra : commitid : 7X5knx0CtGm
extra : rebase_source : b301e9c568df0edb313b10cf06e2f7a9c23a6e78
2016-01-10 21:00:09 -08:00
Bill McCloskey a3d3a41850 Bug 1208257 - [webext] browser_action.json (r=kmag) 2015-12-23 08:57:13 -08:00
Kris Maglione b729a30707 Bug 1229874: Part 3 - Enable ESLint in WebExtension code. r=billm
The base .eslintrc is essentially a merge of the root Toolkit .eslintrc and
the devtools .eslintrc, with some minor changes to match our prevalent style.

For the most enforces the coding styles that we've been using most
consistently. There are a couple of significant differences, though:

 * The rule for opening brace alignment can only be applied globally, and
   doesn't make exceptions for top-level functions. I chose to turn it on, and
   change the brace style of existing top-level functions that violated it,
   since the rule seemed worth using, and that's the direction most Toolkit JS
   code has been headed anyway.

 * The rule for switch/case statements requires an added indentation level for
   case statements. Most of our switch statements did not use an extra level
   of indentation, and I initially wrote the rule to enforce that style, until
   I came across case statements that used blocks, and required the extra
   indentation level for sanity.

--HG--
rename : devtools/.eslintrc => toolkit/components/extensions/.eslintrc
extra : commitid : 4aDZOi5MNPc
extra : rebase_source : f34ba43aeb8046a0c971cb76b76410497bd12b42
extra : source : 2a7eb4ef7b375e5fd52d843ca206a071367a6475
2015-12-02 16:58:53 -08:00