Commit Graph

17 Commits

Author SHA1 Message Date
Kris Maglione
c8ea1d4273 Bug 1421459: Update to ESLint 4 "indent" rule. r=aswan
MozReview-Commit-ID: LxLDWlsIlSk
2017-11-28 14:13:59 -08:00
Bob Silverberg
2adf022ca1 Bug 1420969 - API to open search results in new tab, r=mixedpuppy
This introduces browserSettings.openSearchResultsInNewTabs which exposes
the browser.search.openintab preference to extensions.

Note that until bug 1394304 is fixed this only works for searches performed
via the search box, and not for searches performed via the address bar.

MozReview-Commit-ID: HuoJ0uOvMjX
2017-11-29 09:49:46 -05:00
Bob Silverberg
b3a11fe2e4 Bug 1420974 - API to open bookmarks in new tab, r=mixedpuppy
This introduces browserSettings.openBookmarksInNewTabs which exposes
the browser.tabs.loadBookmarksInTabs preference to extensions.

MozReview-Commit-ID: AZlir2GoiCo
2017-11-28 09:20:31 -05:00
Bob Silverberg
af464fdaf9 Bug 1408472 - Read-only browserSettings should return false on write attempts, r=mixedpuppy
This updates browserSettings so that calling set and clear return false, rather than undefined,
for read-only settings. It also returns "not_controllable" rather than "controllable_by_this_extension"
for levelOfControl from calls to get for read-only settings.

MozReview-Commit-ID: 9c0bKDaYIC7
2017-11-28 12:11:23 -05:00
Bob Silverberg
b9c6563f90 Bug 1419426 - Implement browserSettings.contextMenuShowEvent, r=kmag
This new API exposes the ui.context_menus.after_mouseup preference to extensions
so mouse gesture add-ons can modify it.

Note that this is not supported on Android, and also calling it with a value of
"mousedown" on Windows is a no-op.

MozReview-Commit-ID: AkhRmAyzuSp
2017-11-21 12:33:15 -05:00
Brindusan Cristian
4e36ea8d5f Backed out changeset e8d475fed206 (bug 1419426) for opt-test-verify failures on extensions/test/xpcshell/test_ext_browserSettings.js. r=backout a=backout on a CLOSED TREE 2017-11-23 16:19:37 +02:00
Bob Silverberg
a55b03f221 Bug 1419426 - Implement browserSettings.contextMenuShowEvent, r=kmag
This new API exposes the ui.context_menus.after_mouseup preference to extensions
so mouse gesture add-ons can modify it.

Note that this is not supported on Android, and also calling it with a value of
"mousedown" on Windows is a no-op.

MozReview-Commit-ID: AkhRmAyzuSp
2017-11-21 12:33:15 -05:00
Andrew Swan
26ec3250a3 Bug 1404584 Part 1: Use extensionId in ExtensionSettingsStore and ExtensionPreferencesManager methods, r=aswan
This code changes all of the functions in the ESS and the EPM to accept an extensionId rather than an
extension object, which is required for responding to the new onUpdate event.

MozReview-Commit-ID: FwMVa0fShGj
2017-10-24 20:18:03 -07:00
Bob Silverberg
ebaad828fd Bug 1364942 - Allow WebExtensions to disable Web API notifications, r=mixedpuppy
This works by allowing an extension to set a value of Services.perms.DENY_ACTION
for permissions.default.desktop-notification, which stores the default permission
for desktop notifications. This means that if no permissions have been explicitly
set for a given page, the default will be used, but if a user overrides the permissions
for a specific page then their chosen permission will override this default.

An extension can only use this to make the default behaviour to disable notifications.
It cannot be used to globally enable notifications.

MozReview-Commit-ID: H5bDZe1ICiC
2017-10-18 17:46:38 -04:00
Bob Silverberg
67dd56c12b Bug 1364972 - Allow WebExtensions to disable animated images, r=mixedpuppy
This adds a browserSetting.imageAnimationBehavior API which accepts one of three
values: "normal", "none", "once". Behind the scenes it sets the image.animation_mode
preference to the same value.

MozReview-Commit-ID: GLT6oJgpF3
2017-09-06 16:46:38 -04:00
Wes Kocher
135e3326d8 Backed out changeset 674775dda8ad (bug 1364972) for eslint failures a=backout
MozReview-Commit-ID: 5tmy6XSi0sL
2017-09-07 12:31:11 -07:00
Bob Silverberg
fac011c134 Bug 1364972 - Allow WebExtensions to disable animated images, r=mixedpuppy
This adds a browserSetting.imageAnimationBehavior API which accepts one of three
values: "normal", "none", "once". Behind the scenes it sets the image.animation_mode
preference to the same value.

MozReview-Commit-ID: GLT6oJgpF3
2017-09-06 16:46:38 -04:00
Bob Silverberg
abb21b1d3c Bug 1397081 - Update browserSettings to report the current home page and new tab page in all cases, r=mixedpuppy
This updates the browserSettings API to report the current value of the home page and the new tab page regardless of whether they are currently overridden by an extension.

MozReview-Commit-ID: 3usY3F4oIxl
2017-09-05 16:11:04 -04:00
Bob Silverberg
ccd9787851 Bug 1322308 - Allow WebExtensions to read the overriden homepage and newTab values, r=mixedpuppy
This introduces browser.browserSettings.homepageOverride and browser.browserSettings.newTabPageOverride
which will return the values of the overridden home page and the overridden new tab page.

These browserSettings are read-only.

MozReview-Commit-ID: A9vJP2QIaoA
2017-07-17 14:16:02 -04:00
Bob Silverberg
7ca1f24ce4 Bug 1339550 - Implement browser.settings.allowPopupsForUserEvents, r=aswan
This will modify the "dom.popup_allowed_events" preference to control whether events from
user actions are allowed to open pop-up windows or not. If set to `false` then pop-ups from
user actions will not be allowed and will result in a doorhanger being displayed informing
the user that a pop-up was blocked. If set to `true` then all of the default events
will be allowed to open pop-up windows.

MozReview-Commit-ID: 8UFziq23zug
2017-07-31 16:46:36 -04:00
Bob Silverberg
4b8df9ba3a Bug 1374237 - Part 2: Declare all top-level functions in toolkit API files files via const., r=mixedpuppy
Also changed some function names to attempt to guarantee uniqueness across API files.

MozReview-Commit-ID: GnwWwTADF3a
2017-06-21 14:29:37 -04:00
Bob Silverberg
6b9767d0c2 Bug 1364936 - Allow WebExtensions to disable the browser cache, r=aswan
MozReview-Commit-ID: KhupGnBT5mZ
2017-05-24 13:17:42 -04:00