forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FileChooser: Mojoify FileChooser IPC, part 4
Introduce content::FileSelectListener, which receives the result of FileSelectHelper. An implementation class of FileSelectListener will implement blink.mojom.FileChooser mojo interface in a following CL. a) Add content::FileSelectListener - content/public/browser/BUILD.gn - content/public/browser/file_select_listener.h b) Receive FileSelectHelper arguments, and call its methods to notify results instead of RFH::FilesSelectedInChooser() and RVH:: DirectoryEnumerationFinished(). - chrome/browser/file_select_helper.cc - chrome/browser/file_select_helper.h c) Add FileChooserImpl class implementing content::FileSelectListener. A FileChooserImpl instance is passed to RenderFrameHostDelgate:: RunFileChooser(). RFH::FilesSelectedInChooser() is removed because FileChooserImpl receives a file list, and it sends the list via IPC. - content/public/browser/render_frame_host.h - content/browser/frame_host/render_frame_host_impl.cc - content/browser/frame_host/render_frame_host_impl.h d) Add ViewFileChooser class implementing content::FileSelectListener. A ViewFileChooser instance is passed to WebContentsDelegate:: EnumerateDirectory(). RVH::DirectoryEnumerationFinished() is called by ViewFileChooser instead of FileSelectHelper. - content/browser/web_contents/web_contents_impl.cc - content/browser/web_contents/web_contents_impl.h e) Add FileSelectListener argument, and call FileSelectListener::FileSelected() instead of RFH::FilesSelectedInChooser(). Maintain a FileSelectListener instance in AwWebContentsDelegate class. - android_webview/browser/aw_web_contents_delegate.cc - android_webview/browser/aw_web_contents_delegate.h f) Add FileSelectListener argument, and forward it to another function or call FileSelectListener::FileSelectionCanceled() - chrome/browser/android/tab_web_contents_delegate_android.cc - chrome/browser/android/tab_web_contents_delegate_android.h - chrome/browser/devtools/devtools_window.cc - chrome/browser/devtools/devtools_window.h - chrome/browser/extensions/extension_view_host.cc - chrome/browser/extensions/extension_view_host.h - chrome/browser/ui/apps/chrome_app_delegate.cc - chrome/browser/ui/apps/chrome_app_delegate.h - chrome/browser/ui/browser.cc - chrome/browser/ui/browser.h - components/guest_view/browser/guest_view_base.cc - components/guest_view/browser/guest_view_base.h - content/browser/frame_host/render_frame_host_delegate.cc - content/browser/frame_host/render_frame_host_delegate.h - content/public/browser/web_contents_delegate.cc - content/public/browser/web_contents_delegate.h - extensions/browser/app_window/app_delegate.h - extensions/browser/app_window/app_window.cc - extensions/browser/app_window/app_window.h - extensions/shell/browser/shell_app_delegate.cc - extensions/shell/browser/shell_app_delegate.h g) Add FileSelectListener argument, and call FileSelectListener::FileSelected() instead of RFH::FilesSelectedInChooser() - chrome/browser/ssl/security_state_tab_helper_browsertest.cc - content/test/content_browser_test_utils_internal.cc - content/test/content_browser_test_utils_internal.h h) Add MockFileLister and pass it to RunFileChooser() to avoid null dereference. - content/browser/web_contents/web_contents_impl_browsertest.cc FYI: All-in-one CL: https://chromium-review.googlesource.com/1170454 Bug: 869257 Change-Id: I190159bd5819d228c703028584b9929aa2ad80c2 Reviewed-on: https://chromium-review.googlesource.com/c/1251182 Reviewed-by: Istiaque Ahmed <lazyboy@chromium.org> Reviewed-by: Richard Coles <torne@chromium.org> Reviewed-by: Avi Drissman <avi@chromium.org> Commit-Queue: Kent Tamura <tkent@chromium.org> Cr-Commit-Position: refs/heads/master@{#596451}
- Loading branch information
1 parent
229a1a8
commit 512a27e
Showing
36 changed files
with
398 additions
and
126 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.