gecko-dev/browser/base
Chris Pearce 4a6ff21ab5 Bug 1473671 - Don't store persistent block permission if ESC pressed while showing permission doorhanger. r=florian
While showing a doorhanger permisison prompt, if the user presses the ESC key
we call the secondary action callback, passing in whether any checkbox on
the popup notification was checked.

In the case of an autoplay-media permission prompt, we have a "remember"
checkbox, which is checked by default. So pressing ESC means the user will
remember a "block" result for the current site.

We believe that users don't expect pressing ESC to result in a remembered
decision, they expect pressing ESC to avoid making a decision. So we want to
ignore the checkbox when ESC is pressed for autoplay-media.

So this patch adds a new PopupNotification behaviour which reports the source
of event which caused the action callback to be called. This enables the ESC
key press to ignore storing a permission.

Note: the change here to not store a permission on ESC press applies to all
permissions, not just autoplay-media.


MozReview-Commit-ID: IUWFN8LG9VF

--HG--
extra : rebase_source : b004bc211177a7bfb6dcea563d75db9a6750b214
2018-07-17 14:45:17 +12:00
..
content Bug 1473671 - Don't store persistent block permission if ESC pressed while showing permission doorhanger. r=florian 2018-07-17 14:45:17 +12:00
jar.mn Bug 1473160 - Move non browser window startup and shutdown functionality into a separate JS file;r=Gijs 2018-07-11 06:47:16 -07:00
moz.build Bug 1462468 - Add a tracking protection option to the hamburger menu. r=mikedeboer 2018-05-22 16:26:55 +02:00