mirror of
https://github.com/electron/electron.git
synced 2026-01-28 00:38:35 -05:00
Convert ColorChooser from ipc to mojo.
https://chromium-review.googlesource.com/c/chromium/src/+/800350 https://chromium-review.googlesource.com/c/chromium/src/+/821954
This commit is contained in:
committed by
Samuel Attard
parent
c29f08c53e
commit
f6665edc73
@@ -231,7 +231,7 @@ bool CommonWebContentsDelegate::CanOverscrollContent() const {
|
||||
content::ColorChooser* CommonWebContentsDelegate::OpenColorChooser(
|
||||
content::WebContents* web_contents,
|
||||
SkColor color,
|
||||
const std::vector<content::ColorSuggestion>& suggestions) {
|
||||
const std::vector<blink::mojom::ColorSuggestionPtr>& suggestions) {
|
||||
return chrome::ShowColorChooser(web_contents, color);
|
||||
}
|
||||
|
||||
|
||||
@@ -72,7 +72,8 @@ class CommonWebContentsDelegate
|
||||
content::ColorChooser* OpenColorChooser(
|
||||
content::WebContents* web_contents,
|
||||
SkColor color,
|
||||
const std::vector<content::ColorSuggestion>& suggestions) override;
|
||||
const std::vector<blink::mojom::ColorSuggestionPtr>& suggestions)
|
||||
override;
|
||||
void RunFileChooser(content::RenderFrameHost* render_frame_host,
|
||||
const content::FileChooserParams& params) override;
|
||||
void EnumerateDirectory(content::WebContents* web_contents,
|
||||
|
||||
@@ -731,7 +731,7 @@ void InspectableWebContentsImpl::CloseContents(content::WebContents* source) {
|
||||
content::ColorChooser* InspectableWebContentsImpl::OpenColorChooser(
|
||||
content::WebContents* source,
|
||||
SkColor color,
|
||||
const std::vector<content::ColorSuggestion>& suggestions) {
|
||||
const std::vector<blink::mojom::ColorSuggestionPtr>& suggestions) {
|
||||
auto* delegate = web_contents_->GetDelegate();
|
||||
if (delegate)
|
||||
return delegate->OpenColorChooser(source, color, suggestions);
|
||||
|
||||
@@ -161,7 +161,8 @@ class InspectableWebContentsImpl
|
||||
content::ColorChooser* OpenColorChooser(
|
||||
content::WebContents* source,
|
||||
SkColor color,
|
||||
const std::vector<content::ColorSuggestion>& suggestions) override;
|
||||
const std::vector<blink::mojom::ColorSuggestionPtr>& suggestions)
|
||||
override;
|
||||
void RunFileChooser(content::RenderFrameHost* render_frame_host,
|
||||
const content::FileChooserParams& params) override;
|
||||
void EnumerateDirectory(content::WebContents* source,
|
||||
|
||||
Reference in New Issue
Block a user