Commit Graph
93 Commits
Author SHA1 Message Date
Daniel Holbert 61d9a712bc Bug 2043068: Use MakeRefPtr to do allocation for various RefPtr variables in widget/. r=spohl
Differential Revision: https://phabricator.services.mozilla.com/D302922
2026-05-29 04:29:33 +00:00
Emilio Cobos Álvarez 1bd0da8bf7 Bug 2033243 - Rename GetOwnerGlobal to GetRelevantGlobal. r=dom-core,media-playback-reviewers,credential-management-reviewers,webrtc-reviewers,dom-storage-reviewers,firefox-style-system-reviewers,dimi,janv,dshin,aosmond,smaug
As per the HTML terminology (https://html.spec.whatwg.org/#relevant)

Automatic rename using sed + lints.

Differential Revision: https://phabricator.services.mozilla.com/D297184
2026-05-02 22:04:17 +00:00
iulian moraru 480fc572da Revert "Bug 2036439, Bug 2033243 - Deal with ownerGlobal -> documentGlobal rename in extensions. r=robwu,home-newtab-reviewers,mconley" for causing newtab failures.
This reverts commit 4f62279d01.

Revert "Bug 2033243 - Other miscellaneous ownerGlobal-related naming removal. r=dom-core,smaug"

This reverts commit 91a4ece356.

Revert "Bug 2033243 - BindToOwner -> BindToGlobal. r=dom-core,smaug"

This reverts commit 5a95a889e1.

Revert "Bug 2033243 - Rename GetOwnerGlobal to GetRelevantGlobal. r=dom-core,media-playback-reviewers,credential-management-reviewers,webrtc-reviewers,dom-storage-reviewers,firefox-style-system-reviewers,dimi,janv,dshin,aosmond,smaug"

This reverts commit 7177a68e67.

Revert "Bug 2033243 - Replace ownerGlobal with documentGlobal, and stop exposing ownerGlobal to JS. r=firefox-desktop-core-reviewers ,webidl,joschmidt,perftest-reviewers,sparky,smaug,mossop ,webidl,joschmidt,perftest-reviewers,sparky,smaug,mossop"

This reverts commit 5263254690.
2026-05-02 16:43:35 +00:00
Emilio Cobos Álvarez 7177a68e67 Bug 2033243 - Rename GetOwnerGlobal to GetRelevantGlobal. r=dom-core,media-playback-reviewers,credential-management-reviewers,webrtc-reviewers,dom-storage-reviewers,firefox-style-system-reviewers,dimi,janv,dshin,aosmond,smaug
As per the HTML terminology (https://html.spec.whatwg.org/#relevant)

Automatic rename using sed + lints.

Differential Revision: https://phabricator.services.mozilla.com/D297184
2026-05-02 15:33:23 +00:00
rperta d4cc71008d Revert "Bug 2033243 - Other miscellaneous ownerGlobal-related naming removal. r=dom-core,smaug" on developer request
This reverts commit e58e122135.

This reverts commit 84ca206f3e.

This reverts commit a7945292ed.

This reverts commit 367d83d299.
2026-05-02 06:20:30 +00:00
Emilio Cobos Álvarez a7945292ed Bug 2033243 - Rename GetOwnerGlobal to GetRelevantGlobal. r=dom-core,media-playback-reviewers,credential-management-reviewers,webrtc-reviewers,dom-storage-reviewers,firefox-style-system-reviewers,dimi,janv,dshin,aosmond,smaug
As per the HTML terminology (https://html.spec.whatwg.org/#relevant)

Automatic rename using sed + lints.

Differential Revision: https://phabricator.services.mozilla.com/D297184
2026-05-01 11:58:14 +00:00
agoloman c814da612d Revert "Bug 2033243 - Other miscellaneous ownerGlobal-related naming removal. r=dom-core,smaug" for causing multiple failures.
This reverts commit c7246654bc.

Revert "Bug 2033243 - BindToOwner -> BindToGlobal. r=dom-core,smaug"

This reverts commit 8873ddf33c.

Revert "Bug 2033243 - Rename GetOwnerGlobal to GetRelevantGlobal. r=dom-core,media-playback-reviewers,credential-management-reviewers,webrtc-reviewers,dom-storage-reviewers,firefox-style-system-reviewers,dimi,janv,dshin,aosmond,smaug"

This reverts commit 8bf999e03c.

Revert "Bug 2033243 - Replace ownerGlobal with documentGlobal, and stop exposing ownerGlobal to JS. r=firefox-desktop-core-reviewers ,webidl,joschmidt,perftest-reviewers,sparky,smaug,mossop"

This reverts commit 7dea1af2e0.
2026-04-30 20:13:14 +00:00
Emilio Cobos Álvarez 8bf999e03c Bug 2033243 - Rename GetOwnerGlobal to GetRelevantGlobal. r=dom-core,media-playback-reviewers,credential-management-reviewers,webrtc-reviewers,dom-storage-reviewers,firefox-style-system-reviewers,dimi,janv,dshin,aosmond,smaug
As per the HTML terminology (https://html.spec.whatwg.org/#relevant)

Automatic rename using sed + lints.

Differential Revision: https://phabricator.services.mozilla.com/D297184
2026-04-30 17:47:11 +00:00
Emilio Cobos Álvarez f097472815 Bug 2022763 - Propagate owner global from input element to DOM files properly. r=dom-core,win-reviewers,smaug,gstoll,devtools-reviewers,jdescottes
This required some refactoring of the MockFilePicker to test somewhat (ugh)
reliably, but hopefully an improvement.

Differential Revision: https://phabricator.services.mozilla.com/D288166
2026-04-18 10:00:15 +00:00
rperta 2b400e7aa3 Revert "Bug 2022763 - Propagate owner global from input element to DOM files properly. r=dom-core,win-reviewers,smaug,gstoll,devtools-reviewers,jdescottes" for causing bc failures at browser_screenshots_test_downloads.js This reverts commit 0f75054261. 2026-04-18 02:20:17 +00:00
Emilio Cobos Álvarez 0f75054261 Bug 2022763 - Propagate owner global from input element to DOM files properly. r=dom-core,win-reviewers,smaug,gstoll,devtools-reviewers,jdescottes
This required some refactoring of the MockFilePicker to test somewhat (ugh)
reliably, but hopefully an improvement.

Differential Revision: https://phabricator.services.mozilla.com/D288166
2026-04-17 22:25:42 +00:00
Atila Butkovits ffcaa992e6 Revert "Bug 2022763 - Clean up existing usages of MockFilePicker.init(). r=dom-core,mtigley,extension-reviewers,credential-management-reviewers,devtools-reviewers,omc-reviewers,migration-reviewers,profiles-reviewers,layout-reviewers,emz,fchasen,nchevobbe,mconley,smaug,mossop,robwu,hanna_a,jwatt" for causing multiple failures.
This reverts commit 85b2d0d3dd.

Revert "Bug 2022763 - Propagate owner global from input element to DOM files properly. r=dom-core,win-reviewers,smaug,gstoll"

This reverts commit ff40c521b2.
2026-04-17 10:52:18 +00:00
Emilio Cobos Álvarez ff40c521b2 Bug 2022763 - Propagate owner global from input element to DOM files properly. r=dom-core,win-reviewers,smaug,gstoll
This required some refactoring of the MockFilePicker to test somewhat (ugh)
reliably, but hopefully an improvement.

Differential Revision: https://phabricator.services.mozilla.com/D288166
2026-04-17 09:07:32 +00:00
Sylvestre Ledru 4f6b8b516d Bug 2023419 - Remove Emacs/Vim modelines from widget/ r=emilio
replaced by .editorconfig
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D287877
2026-03-16 17:22:02 +00:00
serge-sans-paille a437cd7714 Bug 2016034 - Use move instead of copy for nsCOMPtr in various place r=emilio,necko-reviewers,profiles-reviewers,layout-reviewers,mossop,kershaw
While we're at it, also std::move some shared_ptr.

As spotted by https://github.com/llvm/llvm-project/pull/179467

Differential Revision: https://phabricator.services.mozilla.com/D282759
2026-02-12 08:17:10 +00:00
Magnus Melin 5070e716c6 Bug 1955634 - nsBaseFilePicker::Init should null-check input browsingContext param. r=win-reviewers,gstoll
Differential Revision: https://phabricator.services.mozilla.com/D242556
2025-03-21 15:28:41 +00:00
Edgar Chen d44e0b7046 Bug 1952343 - Notify nsI{Color|File}PickerShownCallback asynchronously when picker is blocked; r=emilio
Otherwise, the HTMLInputElement doesn't handle the mPickerRunning flag right if
it is in parent process. There is no such problem on content process because
the IPC is async.

Differential Revision: https://phabricator.services.mozilla.com/D241440
2025-03-15 19:52:58 +00:00
Alexandru Marc 2fba52d6a9 Backed out 2 changesets (bug 1952343) for causing linting failure
Backed out changeset bb4a8e6e5b41 (bug 1952343)
Backed out changeset 60d4fd3913aa (bug 1952343)
2025-03-14 23:21:53 +02:00
Edgar Chen 23e0512adc Bug 1952343 - Notify nsI{Color|File}PickerShownCallback asynchronously when picker is blocked; r=emilio
Otherwise, the HTMLInputElement doesn't handle the mPickerRunning flag right if
it is in parent process. There is no such problem on content process because
the IPC is async.

Differential Revision: https://phabricator.services.mozilla.com/D241440
2025-03-14 19:55:01 +00:00
Makoto Kato b441849346 Bug 1674428 - Part 2. Add method to collect files that is selected WebKitDirectory. r=dom-core,sefeng
When using Android 13 or later, there is no permission to enumerate
directories if on user storage. So `GetFilesHelper` and etc won't work on
Android.

We have to use content resolver APIs to enumerate files in directory.
So I have to add a method to collect files in FilePicker and return
DOM Files.

Differential Revision: https://phabricator.services.mozilla.com/D228761
2025-03-07 12:44:07 +00:00
Edgar Chen 550690c003 Bug 1837963 - Disallow opening file pickers from background tabs; r=geckoview-reviewers,emilio,m_kato
Differential Revision: https://phabricator.services.mozilla.com/D230087
2025-01-16 11:30:36 +00:00
Sandor Molnar 5a87a4f673 Backed out 3 changesets (bug 1837963) for causing build bustages. CLOSED TREE
Backed out changeset cd000de4a239 (bug 1837963)
Backed out changeset d19b71505a16 (bug 1837963)
Backed out changeset 7c4052454ec2 (bug 1837963)
2025-01-15 02:54:56 +02:00
Edgar Chen ff32fd204b Bug 1837963 - Disallow opening file pickers from background tabs; r=geckoview-reviewers,emilio,m_kato
Differential Revision: https://phabricator.services.mozilla.com/D230087
2025-01-15 00:14:37 +00:00
Norisz Fay f8452b2129 Backed out 4 changesets (bug 1837963) for causing build bustages on nsColorPicker.cpp
Backed out changeset 6465dbafe002 (bug 1837963)
Backed out changeset 5ed6d107133f (bug 1837963)
Backed out changeset 90114d0e72d1 (bug 1837963)
Backed out changeset 36f4b96eb15b (bug 1837963)
2025-01-14 15:23:14 +02:00
Edgar Chen eda589c635 Bug 1837963 - Disallow opening file pickers from background tabs; r=geckoview-reviewers,emilio,m_kato
Differential Revision: https://phabricator.services.mozilla.com/D230087
2025-01-14 12:33:43 +00:00
Edgar Chen 0f435c68b4 Bug 1930101 - Minor cleanup of nsBaseFilePicker; r=emilio
No functional changes.

Differential Revision: https://phabricator.services.mozilla.com/D228421
2024-11-18 23:38:17 +00:00
Edgar Chen e4cb522cb9 Bug 1930101 - Move AsyncShowFilePicker to cocoa/nsFilePicker; r=win-reviewers,mac-reviewers,emilio,rkraesig,bradwerth
Then other plaforms don't need to implement Show() method.
No functional changes.

Differential Revision: https://phabricator.services.mozilla.com/D228418
2024-11-18 23:38:16 +00:00
Ray Kraesig 2a7b3b1db5 Bug 1881329 - Revert addition of nsIFilePicker::Close() r=emilio
This function can't be implemented for Win32 (yet?), partly due to
internal architectural issues. (See bug 1870660 for more details.)

Remove the existing stubs (and perfectly-functional Gtk implementation)
as dead code until such time as they can be made live.

(This commit also reverts a fix to this code from bug 1872834, which
should be restored if and when the rest of it is.)

Differential Revision: https://phabricator.services.mozilla.com/D214317
2024-07-01 15:47:46 +00:00
Gregory Pappas 3a68660a11 Bug 1878401 - part 1 - Pass BrowsingContext to nsIFilePicker::Init instead of mozIDOMWindow r=geckoview-reviewers,win-reviewers,emilio,nika,m_kato,rkraesig
This will improve the situation in bug 1878336

Differential Revision: https://phabricator.services.mozilla.com/D200546
2024-02-28 21:29:37 +00:00
Sandor Molnar c853f2f3e9 Backed out 8 changesets (bug 1878401, bug 1879041) for causing build bustages on widget/nsBaseFilePicker.cpp CLOSED TREE
Backed out changeset 2e2b8df3bdd6 (bug 1879041)
Backed out changeset 6d6952f9df2c (bug 1878401)
Backed out changeset 30b5bb590d3e (bug 1878401)
Backed out changeset 9a4b830334b9 (bug 1878401)
Backed out changeset 3c3d67f1fcb7 (bug 1878401)
Backed out changeset c83ba4026822 (bug 1878401)
Backed out changeset 6bcb670ce475 (bug 1878401)
Backed out changeset f263b196df96 (bug 1878401)
2024-02-28 17:56:48 +02:00
Gregory Pappas 44b053ba1a Bug 1878401 - part 1 - Pass BrowsingContext to nsIFilePicker::Init instead of mozIDOMWindow r=geckoview-reviewers,win-reviewers,emilio,nika,m_kato,rkraesig
This will improve the situation in bug 1878336

Differential Revision: https://phabricator.services.mozilla.com/D200546
2024-02-28 15:07:44 +00:00
Gregory Pappas b8a57ea6f0 Bug 1708289 - Implement AllowFileSelectionDialogs policy r=fluent-reviewers,mkaply,emilio,Gijs,bolsson,win-reviewers,rkraesig
Differential Revision: https://phabricator.services.mozilla.com/D199328
2024-02-01 00:48:24 +00:00
Greg Stoll df896d7e12 Bug 1872179 - Part 3: File picker file uploads consult content analysis r=rkraesig,win-reviewers
File picker upload operations check with any connected content analysis
tool before giving access to the web page.

Differential Revision: https://phabricator.services.mozilla.com/D198456
2024-01-22 13:56:07 +00:00
Oliver Medhurst 9e312ddb6c Bug 1866517 - Part 1: Start implementing close method for file picker r=emilio
Implements it in IPC/base/etc, and also in GTK. Win32 and Cocoa do not implement it yet in this initial patch.

Differential Revision: https://phabricator.services.mozilla.com/D194631
2023-12-13 15:10:33 +00:00
Ray Kraesig a58004b51e Bug 1858225 - [9/9] remove async-to-sync code from Windows build r=win-reviewers,mhowell
This is no longer needed on Windows, so #ifdef it out.

Differential Revision: https://phabricator.services.mozilla.com/D193741
2023-12-01 05:03:21 +00:00
Cosmin Sabou 3c7a65e66b Backed out 11 changesets (bug 1858225) for causing build bustages on nsFilePicker.cpp. CLOSED TREE
Backed out changeset 808f68da4438 (bug 1858225)
Backed out changeset e6f456e40dda (bug 1858225)
Backed out changeset d1efbf517c7e (bug 1858225)
Backed out changeset 61c8a62b47c5 (bug 1858225)
Backed out changeset 9b1f0d37b74b (bug 1858225)
Backed out changeset f57ac4a387f2 (bug 1858225)
Backed out changeset 9b2c6eaf137e (bug 1858225)
Backed out changeset 6aacb8fde7e1 (bug 1858225)
Backed out changeset 2eb38cba55d6 (bug 1858225)
Backed out changeset c31dfa5f9be5 (bug 1858225)
Backed out changeset 82b7b851c429 (bug 1858225)
2023-12-01 00:18:29 +02:00
Ray Kraesig 0213a61f97 Bug 1858225 - [9/9] remove async-to-sync code from Windows build r=win-reviewers,mhowell
This is no longer needed on Windows, so #ifdef it out.

Differential Revision: https://phabricator.services.mozilla.com/D193741
2023-11-30 19:59:18 +00:00
Mike Conley cb7855dca2 Bug 1852839 - Part 1: Add nsIFilePicker.isModeSupported method. r=spohl
Differential Revision: https://phabricator.services.mozilla.com/D188131
2023-09-19 19:44:50 +00:00
Cosmin Sabou 8ae5c8fac6 Backed out 2 changesets (bug 1852839) for causing build bustages on nsFilePicker.cpp. CLOSED TREE
Backed out changeset ac93fddded79 (bug 1852839)
Backed out changeset 6235d3df9ecf (bug 1852839)
2023-09-19 21:36:34 +03:00
Mike Conley 3d8cc9887e Bug 1852839 - Part 1: Add nsIFilePicker.isModeSupported method. r=spohl
Differential Revision: https://phabricator.services.mozilla.com/D188131
2023-09-19 17:57:39 +00:00
Calixte a618a7cc5d Bug 1844530 - Add an option to filter pdf files in the file chooser r=spohl
Differential Revision: https://phabricator.services.mozilla.com/D184092
2023-07-21 06:59:05 +00:00
Ray Kraesig b8fd10dd87 Bug 1838244 - [1/1] Resolve special directory paths in the parent process r=gstoll
Avoid (one instance of) loading `shell32.dll` in the content process by
delaying the resolution of special-directory names to paths until
they're passed up into the client process.

Differential Revision: https://phabricator.services.mozilla.com/D180988
2023-06-15 20:04:06 +00:00
Ray Kraesig 3641a399e3 Bug 1816740 [5/6] - convert nsIFilePicker::capture* to a proper enum r=ipc-reviewers,karlt,mstange,handyman,nika
Convert the various capture* constants in nsIFilePicker into a proper
enum, and perform validation when passing it across IPC.

Additionally, unlike the previous two enums, reduce the size of
CaptureTarget to 8 bits. This is a workaround for its use with
nsAttrValue, which at present very specifically requires that parseable
enums' values fit within an `int16_t` -- and a `uint16_t` does not.

Differential Revision: https://phabricator.services.mozilla.com/D169854
2023-02-22 21:05:24 +00:00
Ray Kraesig eb8a5041cb Bug 1816740 [4/6] - convert nsIFilePicker::mode* into a proper enum r=ipc-reviewers,karlt,mstange,handyman,nika
Convert the various mode* constants in nsIFilePicker into a proper
enum, and perform validation when passing it across IPC.

Differential Revision: https://phabricator.services.mozilla.com/D169853
2023-02-22 21:05:24 +00:00
Ray Kraesig c192386b3f Bug 1816740 [3/6] - convert nsIFilePicker::result* into a proper enum r=ipc-reviewers,karlt,mstange,handyman,nika
Convert the various result* constants in nsIFilePicker into a proper
enum, and perform validation when passing it across IPC.

Differential Revision: https://phabricator.services.mozilla.com/D169852
2023-02-22 21:05:23 +00:00
Alexis Beingessner b376547204 Bug 1686616 - make StringBundle use Components instead of Services. r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D105531
2021-02-18 13:26:32 +00:00
Simon Giesecke a69d79b6db Bug 1648010 - Replace uses of NS_LITERAL_STRING/NS_LITERAL_CSTRING macros by _ns literals. r=geckoview-reviewers,jgilbert,agi,hsivonen,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D80860
2020-07-01 08:29:29 +00:00
Simon Giesecke 1ee0a47195 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in widget. r=jmathies
Differential Revision: https://phabricator.services.mozilla.com/D66012
2020-03-16 10:56:57 +00:00
Bogdan Tara 22b0fa7e80 Backed out 4 changesets (bug 1613985) for causing build bustages CLOSED TREE
Backed out changeset fba0caac746c (bug 1613985)
Backed out changeset 8605d7a19107 (bug 1613985)
Backed out changeset 41e858fbf235 (bug 1613985)
Backed out changeset 847433cf1e0a (bug 1613985)
2020-03-16 12:41:41 +02:00
Simon Giesecke 36f6c9d797 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in widget. r=jmathies
Differential Revision: https://phabricator.services.mozilla.com/D66012
2020-03-16 09:14:12 +00:00