The probes in this patch are annotated with the extra "dom-push-api"
to distinguish from future Fennec-specific push messages. These
probes allow to determine for each user the difference:
{# sites subscribed to} - {# sites unsubscribed from}.
If we assume the same site is not subscribed to multiple times, this
is a good approximation to the total number of sites the user receives
push messages from.
To test manually:
0) Install Fennec and execute |adb shell setprop log.tag.Telemetry DEBUG|.
1) Subscribe to notifications on a site like serviceworke.rs.
Observe a UI Telemetry SAVE event, like:
D/Telemetry( 7109): SendUIEvent: event = save.1 method = service timestamp = 277456 extras = dom-push-api
2) Send a push notification using the sites' interface.
Observe a UI Telemetry PUSH_RECEIVED_MESSAGE event, like:
D/Telemetry( 7109): SendUIEvent: event = action.1 method = service timestamp = 361795 extras = dom-push-api
3) Unsubscribe to notifications by revoking permission using Site
Settings from the URL bar.
Observe a UI Telemetry PUSH_UNSUBSCRIBED_FROM_SITE event, like:
D/Telemetry( 7109): SendUIEvent: event = unsave.1 method = service timestamp = 393600 extras = dom-push-api
MozReview-Commit-ID: IOCwfXFnowA
--HG--
extra : rebase_source : 705440ac545de0bc82ec72951fb646da3fc7d67b
This will be re-implemented without reference to Fennec's Tab/Tabs
data structures.
MozReview-Commit-ID: I12Dlb3ef58
--HG--
extra : rebase_source : 397405a12bd913ac0f837fbc264890786d45ce56
extra : source : ab088eb19b46d9e8dc5551e39aa4a871a4c9ee23
These have no consumer and deserve to be properly reworked.
MozReview-Commit-ID: KmjE44nmLXx
--HG--
extra : rebase_source : 973f13ad0c111413aa73dff233fd771d9f641191
extra : source : dcffecae84b741d837295ad77d0dd9e7ece391eb
The existing code assumes an Activity, not just a Context, but doesn't
statically guarantee it. This patch is safe because it dynamically
type-checks, but it would be better to declare the member to be an
Activity.
MozReview-Commit-ID: 9AigV055I5j
--HG--
extra : rebase_source : e2d273221767735504a93855623961fc171ae413
extra : source : 0476a0d0575b4b07c404eb15bc5a943ae04d0289
GlobalHistory is Fennec-specific: it accesses the Fennec history data
store, and collects Telemetry. This allows other consumers to
implement their own store as appropriate.
MozReview-Commit-ID: 75Uxc5k8V0O
--HG--
extra : rebase_source : 7e25d183045082edaee4295cb95c62100e956c8e
extra : source : 476cdaa0ce08b0808c3892d3d5ee55f701504666
This moves some Fennec-specific home-screen icon manipulations out of
GeckoAppShell. A GeckoView interface can follow.
MozReview-Commit-ID: 7OhRAT9Agdh
--HG--
extra : rebase_source : c5bc8a871a22c5892b320068dea6501ed8884d8e
extra : source : f39f05fa8df3717c57452ac44a16e4a86d9cbd2c
This is just a small simplification to allow us to not depend on
org.mozilla.gecko.R.
MozReview-Commit-ID: TjSYwYyAMS
--HG--
extra : rebase_source : 1a5a256656063b649c4efc2d2cc8c33e476aec88
extra : source : 33e39362305beb355699cbd88cefe4a37354136c
This commit adds the `getCensusIndividuals` utility for getting the individual
node IDs that match the census leaves specified by the given indices in a
pre-order depth-first traversal of a census report generated with the given
breakdown.
MozReview-Commit-ID: A4IRcP82iCC
--HG--
extra : histedit_source : e48cc59b522ce82f649f077b4686cea4715980f1
The `flatten` function takes an array of arrays and flattens them to a single
array, removing one level of nesting. It does not recursively flatten multiple
levels of nesting.
MozReview-Commit-ID: ErDMHbT2IX
--HG--
extra : histedit_source : eb6e4f8c54f536c84b08da22ef60cfa56a5075c8
This was implemented, but never wired up.
I thought long and hard about how to unit test this, and it's quite
difficult. First, we'd have to chose a layer of testing. We could
unit test:
* the JS <-> Java message passing;
* the permission prompts <-> JS interface;
* some interactions with the Service Worker interface.
The first is difficult because none of our current testing emulators
have Google Play Services and GCM enabled, so we'd need to allow to
mock or otherwise fake the GCM registration. Then we'd need to stand
up a mock autopush server (using httpd.js or the Java-side
equivalent), or mock out the autopush client as well. At this point,
we're testing sendMessage. This could be done, but I'd rather slide
this fix in before building out quite a bit of test infrastructure.
(For the record, the Java Push Service state machine is thoroughly
tested with Java unit tests, so I have confidence that the unsubscribe
logic works.)
The second is tested via the PushWebSocket tests, which are now
running on Android. That is, if permissions and the PushService are
interacting badly, we should see it with the existing test suite.
Since PushServiceAndroidGCM is pretty much a pass-through, there's
little value to be added here.
Finally, the third is also tested via the PushWebSocket tests.
There's absolutely nothing GCM specific about the Service Worker
interface to the PushService.
So I'm left manually testing this -- and now we can unsubscribe from
Push messages from sites.
MozReview-Commit-ID: HiRiqasHJ27
--HG--
extra : rebase_source : ce01aa738d583a7200e9dc93ffa38dea9663779c
extra : amend_source : 03fc8a099e83871fa7bfe345168c063b69938d5e
The devtools host window updates its title when its target navigates.
This was done using a contentDocument CPOW, and thus failing on e10s.
The url and title are now stored in TabTarget and updated on tab navigation.
Updated existing test to cover the case of pages with a title.
MozReview-Commit-ID: 4G1keOA7yB6
--HG--
extra : rebase_source : 720084e9929f334092ffe18e4c786cbf731fe52e