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

48 Коммитов

Автор SHA1 Сообщение Дата
Mathieu Leplatre 1cdc04dfda Bug 1541888 - Enable ESLinting in dom/push/ r=glasserc,lina
Enable ESLinting in dom/push/

Differential Revision: https://phabricator.services.mozilla.com/D26321

--HG--
extra : moz-landing-system : lando
2019-04-09 10:05:51 +00:00
Kris Maglione e930b89c34 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16750

--HG--
extra : rebase_source : 359574ee3064c90f33bf36c2ebe3159a24cc8895
extra : histedit_source : b93c8f42808b1599f9122d7842d2c0b3e656a594%2C64a3a4e3359dc889e2ab2b49461bab9e27fc10a7
2019-01-17 10:18:31 -08:00
Kris Maglione 2fe0de01dc Bug 1519596: Part 1 - Remove several unnecessary/unused ChromeUtils.import() calls. r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D16377

--HG--
extra : rebase_source : 6c4311387d25de425806aeb6c4691e12c9fcb855
2019-01-11 16:59:23 -08:00
Kris Maglione 3a5c05e76f Bug 1484496: Part 5e - Convert remaining nsISimpleEnumerator users to use JS iteration. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D3733

--HG--
extra : rebase_source : c0fac176d7b3d840c4dbb14f8d95ccfc7f83a5a8
extra : histedit_source : a92c40117d0808a3ad68c972f622a7a42c9ae8ba
2018-08-18 18:13:14 -07:00
Florian Quèze 682b1ec3b2 Bug 1440284 - change this.EXPORTED_SYMBOLS back to var EXPORTED_SYMBOLS in JS modules, r=mccr8. 2018-02-23 20:50:01 +01:00
Andrew McCreight 5dec0e0beb Bug 1432992, part 1 - Remove definitions of Ci, Cr, Cc, and Cu. r=florian
This patch was autogenerated by my decomponents.py

It covers almost every file with the extension js, jsm, html, py,
xhtml, or xul.

It removes blank lines after removed lines, when the removed lines are
preceded by either blank lines or the start of a new block. The "start
of a new block" is defined fairly hackily: either the line starts with
//, ends with */, ends with {, <![CDATA[, """ or '''. The first two
cover comments, the third one covers JS, the fourth covers JS embedded
in XUL, and the final two cover JS embedded in Python. This also
applies if the removed line was the first line of the file.

It covers the pattern matching cases like "var {classes: Cc,
interfaces: Ci, utils: Cu, results: Cr} = Components;". It'll remove
the entire thing if they are all either Ci, Cr, Cc or Cu, or it will
remove the appropriate ones and leave the residue behind. If there's
only one behind, then it will turn it into a normal, non-pattern
matching variable definition. (For instance, "const { classes: Cc,
Constructor: CC, interfaces: Ci, utils: Cu } = Components" becomes
"const CC = Components.Constructor".)

MozReview-Commit-ID: DeSHcClQ7cG

--HG--
extra : rebase_source : d9c41878036c1ef7766ef5e91a7005025bc1d72b
2018-02-06 09:36:57 -08:00
Kris Maglione 918ed6c474 Bug 1431533: Part 5a - Auto-rewrite code to use ChromeUtils import methods. r=florian
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm

MozReview-Commit-ID: 1Nc3XDu0wGl

--HG--
extra : source : 12fc4dee861c812fd2bd032c63ef17af61800c70
extra : intermediate-source : 34c999fa006bffe8705cf50c54708aa21a962e62
extra : histedit_source : b2be2c5e5d226e6c347312456a6ae339c1e634b0
2018-01-29 15:20:18 -08:00
Cosmin Sabou 9a65a40178 Backed out 3 changesets (bug 1431533) for Android mochitest failures on testEventDispatcher on a CLOSED TREE
Backed out changeset a1eca62826a1 (bug 1431533)
Backed out changeset 34c999fa006b (bug 1431533)
Backed out changeset e2674287e57f (bug 1431533)
2018-01-30 07:17:48 +02:00
Kris Maglione 6476f95b13 Bug 1431533: Part 5a - Auto-rewrite code to use ChromeUtils import methods. r=florian
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm

MozReview-Commit-ID: 1Nc3XDu0wGl

--HG--
extra : source : 12fc4dee861c812fd2bd032c63ef17af61800c70
2018-01-29 15:20:18 -08:00
Brindusan Cristian af8879d1eb Backed out 2 changesets (bug 1431533) for ESlint failures on a CLOSED TREE
Backed out changeset 6e56f4c8843e (bug 1431533)
Backed out changeset 12fc4dee861c (bug 1431533)
2018-01-30 02:32:43 +02:00
Kris Maglione c276bb9375 Bug 1431533: Part 5a - Auto-rewrite code to use ChromeUtils import methods. r=florian
This was done using the following script:
37e3803c7a/processors/chromeutils-import.jsm

MozReview-Commit-ID: 1Nc3XDu0wGl

--HG--
extra : rebase_source : c004a023389f1f6bf3d2f3efe93c13d423b23ccd
2018-01-29 15:20:18 -08:00
Marco Castelluccio 51d8b32912 Bug 1357517 - Remove Preferences.jsm usage from some dom/push/* files. r=kitcambridge
--HG--
extra : rebase_source : 77dce879e3ceb5352ea7a65673dffd53c9b9276f
2017-07-28 23:13:57 +02:00
Florian Quèze 66f6d259bc Bug 1374282 - script generated patch to remove Task.jsm calls, r=Mossop. 2017-06-22 12:51:42 +02:00
Marco Bonardo eb7475a826 Bug 977177 - Move favicons to a separate store. r=adw
This patch moves favicons blobs to a separate database names favicons.sqlite.
The dabatase is then ATTACHED to the main Places connection, so that its tables
can be used as if they were all part of the same database.
The favicons.database contains 3 tables:
  1. moz_pages_w_icons
     This is the way to join with moz_places, through page_url_hash and page_url.
     We are not using the place id to avoid possible mismatches between places.sqlite
     and favicons.sqlite. This way the database is "portable" and reusable even
     if places.sqlite changes.
  2. moz_icons
     Contains icons payloads, each payload can either be an SVG or a PNG. These
     are the only stored formats, any other format is rescaled and converted to
     PNG. ICO files are split into single frames and stored as multiple PNGs.
     SVG are distinguishable through width == UINT16_MAX
     In future the table will also contain mask-icon color for SVG and average
     color for PNGs.
     The fixed_icon_url_hash is "fixed" to allow quickly fetch root icons, that
     means icons like "domain/favicon.ico" that can also be reused for any page
     under that domain.
  3. moz_icons_to_pages
     This is the relation table between icons and pages.
     Each page can have multiple icons, each icon can be used by multiple pages.
     There is a FOREIGN_KEY constraint between this (child) table and icons
     or pages (parents), so that it's not possible to insert non-existing ids
     in this table, and if an entry is removed from a parent table, the relation
     will be automatically removed from here.
     Note though that removing from the relation table won't remove from the
     parent tables.
Since the relations are now many-many, it's no more possible to simply join
places with the icons table and obtain a single icon, thus it's suggested that
consumers go through the "page-icon" protocol.
The migration process from the old favicons table is async and interruptible,
it will be restarted along with the favicons service until the temp preference
places.favicons.convertPayloads is set to true.


MozReview-Commit-ID: CUCoL9smRyt

--HG--
extra : rebase_source : 4d25966596dcdf63c9c872425c5bf147406d25ac
2016-11-14 16:22:46 +01:00
Kit Cambridge be7ad3ff16 Bug 1345001 - Remove expiring Push telemetry probes. r=liuche
We haven't found these probes useful for understanding the value of
Push, and many can be better determined from server metrics.

MozReview-Commit-ID: GM9K59OAbMT

--HG--
extra : rebase_source : b4478fe2aad5ce01ba5955406300973b3e0fb699
2017-03-06 19:06:32 -08:00
Jim Chen 9ad1c54661 Bug 1333590 - 3. Change remaining Messaging calls to EventDispatcher calls; r=sebastian
Convert calls in several places where we still use Messaging.* instead
of EventDispatcher.
2017-02-01 17:35:44 -05:00
Florian Quèze fc6379e827 Bug 1329182 - remove trailing newURI null parameters in the rest of the tree, r=jaws. 2017-01-09 20:27:26 +01:00
Kit Cambridge bfc6259dcd Bug 1307577 - Switch to `createCodebasePrincipal` in `PushRecord`. r=mt
`createCodebasePrincipalFromOrigin` mangles the origin after extracting
the suffix. The proper long-term fix is to serialize and store the
original principal, instead of reconstructing a new codebase principal
from the scope and origin suffix.

MozReview-Commit-ID: bS2lRx3n7j

--HG--
extra : rebase_source : b62001f997718455b2b6c7cb3074ee79fa68ec25
2016-10-20 10:29:58 -07:00
Edouard Oger 83666a61d8 Bug 1287643 - FxA Push registration and handling of device disconnection message. r=kitcambridge,nalexander
MozReview-Commit-ID: 8IH3kBivp26

--HG--
extra : rebase_source : b3e2d2587f111c9d2c8d0eab887027caf92fe859
2016-07-20 10:47:04 -07:00
Kit Cambridge 55b7ef53d9 Bug 1207743 - Track recent push messages to avoid duplicate notifications on reconnect. r=dragana
MozReview-Commit-ID: KezPfa0yyO1

--HG--
extra : rebase_source : 86c3b0d78f2772369ebedd11d640a8b05e46d24f
extra : histedit_source : 531a495b7b3b3d8d4bf8b399f6beebf0805ac3bc
2016-06-04 13:17:12 -07:00
Kit Cambridge f2f4e5708d Bug 1206424 - Ensure `daysElapsed` is always non-negative when updating the push quota. r=wchen
--HG--
extra : rebase_source : 4c203d359f7bf965591442a3755675fd1d37ba3c
2016-05-09 20:54:05 -07:00
Kit Cambridge 14ee7e9341 Bug 1266433 - Indicate push subscriptions created by privileged code. r=dragana
MozReview-Commit-ID: HYKndQiU98U

--HG--
extra : rebase_source : 5671a231b02dacf71de77a0d15c284c9b6365a73
2016-04-23 19:41:59 -07:00
Kit Cambridge 21365c8060 Bug 1247685 - Validate and store app server keys in the Push service. r=mt
MozReview-Commit-ID: KLm6mP22y2E

--HG--
extra : rebase_source : ccda66192d5a64427bfd8699a70081f581dac5a1
2016-03-16 02:53:13 -07:00
Kit Cambridge a6d5a040d9 Bug 1257821 - Remove the authenticated `aesgcm128` content coding scheme. r=mt,marco
MozReview-Commit-ID: 5pX2GHJ2lNz

--HG--
extra : rebase_source : 8747786a915e0adb3be7555dd1648e3e03b4fbf0
2016-03-22 19:20:36 -07:00
Marco Bonardo d1f0a04370 Bug 1243778 - PushRecord::getLastVisit cannot rely on the Places url index anymore. r=kitcambridge
--HG--
extra : commitid : 4zr7xfJixhU
extra : rebase_source : b3fa86b314d338b2ee0fc846d212ba6bb6c2ab0c
2016-02-08 14:42:07 +01:00
Kit Cambridge 0333c16142 Bug 1239558 - Exempt system Push subscriptions from quota and permissions checks. r=dragana
--HG--
extra : commitid : 6weiBkKPMVj
extra : rebase_source : b5d6479902725a37c5b212bc4b23dc8296f34c9a
2015-12-16 09:21:22 -08:00
Kit Cambridge d1e4feb4e5 Bug 1189998, Part 1 - Consolidate Push client interfaces. r=mt,dragana
--HG--
extra : commitid : GZtcmH86Wg4
extra : rebase_source : b1f7410370991819a29c9142d6dee11261f09905
2015-12-08 15:41:41 -05:00
Martin Thomson 6e6387eecb Bug 1225968 - Add authentication secret to push API, r=kitcambridge,smaug
--HG--
extra : commitid : 5qD0xsj9DLR
extra : rebase_source : 407d4152f897f87fa9b5fae8b6b93ef510cce59f
2015-12-09 07:26:42 +11:00
Kit Cambridge da70e5e668 Bug 1170115 - Use `clear-origin-data` to remove Push records. r=allstars.chh
--HG--
extra : commitid : HPTqiGSIMbc
extra : rebase_source : 04ebebe52cd847c2258913ca97ed2dcc09aa9c32
2015-11-13 15:18:10 -08:00
William Chen 8588891ca7 Bug 1210211 - Part 1: Delay updating push quota. r=kitcambridge
--HG--
extra : commitid : 70QSm4u4WLW
extra : rebase_source : e52cc3bae822448e64dca6c40be48d74ea924e0b
2015-11-16 21:33:11 -08:00
Phil Ringnalda 6edbd4d1af Back out 3 changesets (bug 1210211) for b2g build bustage
CLOSED TREE

Backed out changeset 204a1746f421 (bug 1210211)
Backed out changeset e5d16111e809 (bug 1210211)
Backed out changeset b78d00c9af42 (bug 1210211)
2015-11-16 19:34:14 -08:00
William Chen e791f70b13 Bug 1210211 - Part 1: Delay updating push quota. r=kitcambridge
--HG--
extra : commitid : GXDHaPbe8pi
extra : rebase_source : 260a2a8e1434355671b25d58e36007c88b934464
2015-11-16 13:20:09 -08:00
Kit Cambridge 53cdf28e5a Bug 1223202 - Only send subscription change events if the Push permission is granted. r=mt
--HG--
extra : commitid : 4m6UEhlrFtl
extra : rebase_source : 512c9e2ea4be850994e891fc8193df17a2788260
2015-11-10 14:27:47 -08:00
Nick Alexander 8b9481fa99 Bug 1214366 - Part 3: Use getLastVisited equivalent in PushService.jsm. r=kitcambridge,rnewman
--HG--
extra : commitid : 7BJvkjwmp6t
extra : rebase_source : b856fccd39ddf3cf8692b45b6b2d77e6c229f51a
2015-10-23 10:07:05 -07:00
Kit Cambridge 3898c24797 Bug 1191453 - Drop subscriptions for a site when the user revokes push permissions. r=mt,MattN
--HG--
extra : commitid : JlZvX8xAxRf
extra : rebase_source : 14372dacf2d519784890550a0e77d4c05e4f2c1a
2015-10-06 08:14:25 -07:00
Kit Cambridge 74ef03c1a6 Bug 1192458, Part 1 - Consolidate push and desktop notification permissions. r=nsm,wchen,MattN
--HG--
extra : commitid : 1veevVaOOYv
2015-10-05 16:39:34 -07:00
Stephanie Ouillon 5e14a3b3a8 Bug 1178533 - Add nsIInstallPackagedWebapp for registering permissions when navigating to signed packages r=bholley,fabrice,valentin 2015-08-26 13:12:13 +02:00
Carsten "Tomcat" Book 64c0a617b7 Backed out 1 changesets (bug 1178533) for xpcshell-1 test failures
Backed out changeset b12584fad334 (bug 1178533)
2015-09-24 08:41:04 +02:00
Stephanie Ouillon 478b31c634 Bug 1178533 - Add nsIInstallPackagedWebapp for registering permissions when navigating to signed packages. r=bholley, r=fabrice, r=valentin 2015-09-23 07:41:00 +02:00
Carsten "Tomcat" Book 58878018ac Backed out 1 changesets (bug 1178533) for s4 testfailures
Backed out changeset 8bbdb80f67e0 (bug 1178533)

--HG--
extra : rebase_source : 040491f382ad7b03ba803686601f1272416ab47d
2015-09-23 10:17:54 +02:00
Stephanie Ouillon ad9e2b8a95 Bug 1178533 - Add nsIInstallPackagedWebapp for registering permissions when navigating to signed packages. r=bholley, r=fabrice, r=valentin 2015-09-22 11:55:00 +02:00
Kit Cambridge 6c8172cef8 Bug 1185544 - Add data delivery to the WebSocket backend. r=dragana,nsm
--HG--
extra : commitid : EntjTGDbYag
extra : rebase_source : 79b325dacbed5d96fea17ac26a4bc8103c8dfae1
2015-09-17 05:08:50 -07:00
Nikhil Marathe eac943182b Bug 914481 - Patch 3 - Subscription and quota expiration times. r=kitcambridge, p=ally
--HG--
extra : commitid : JADysGJDrMp
extra : rebase_source : dd937d960dd05028806debd00ecc875adfdd08b5
2015-08-06 12:05:47 -07:00
Carsten "Tomcat" Book 6bd408e0ae Backed out 4 changesets (bug 914481) for xpc and push service test failures
Backed out changeset 6165f6eba17f (bug 914481)
Backed out changeset a8c47e9431d0 (bug 914481)
Backed out changeset f03e8c42861e (bug 914481)
Backed out changeset 84b11173d98f (bug 914481)

--HG--
extra : rebase_source : 9496d5740c290bc6d8169782a8f1a2950711f3d7
2015-09-17 12:31:49 +02:00
Nikhil Marathe 6e258d2336 Bug 914481 - Patch 3 - Subscription and quota expiration times. r=kitcambridge, p=ally
--HG--
extra : rebase_source : d6a29b72e95cb8b75492d2f7634dcefed86ae2dd
2015-08-06 12:05:47 -07:00
Shu-yu Guo 64db2267cf Bug 1202902 - Mass replace toplevel 'let' with 'var' in preparation for global lexical scope. (rs=jorendorff) 2015-09-15 11:19:45 -07:00
Kit Cambridge 1acca57a40 Bug 1196512 - Use principals to test for push permissions. r=nsm
--HG--
extra : commitid : 7scu10UsEc9
extra : rebase_source : ce8993d0662dfea702b82abf54b98a3f318c386f
extra : amend_source : 0ce3c201cebb227a2e16be35e907f42f73426e03
2015-08-19 16:03:15 -07:00
Kit Cambridge 97018538cd Bug 1153504 - Add per-origin push quotas. r=nsm,mt,markh
--HG--
extra : commitid : 8CPpVl9sAYo
extra : rebase_source : d4e6330e3717c89f39686c620ae0aeb90e2156c8
2015-06-25 14:52:57 -07:00