summaryrefslogtreecommitdiff
path: root/chromium/third_party/blink/public/web
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2021-10-26 13:57:00 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2021-11-02 11:31:01 +0000
commit1943b3c2a1dcee36c233724fc4ee7613d71b9cf6 (patch)
tree8c1b5f12357025c197da5427ae02cfdc2f3570d6 /chromium/third_party/blink/public/web
parent21ba0c5d4bf8fba15dddd97cd693bad2358b77fd (diff)
downloadqtwebengine-chromium-1943b3c2a1dcee36c233724fc4ee7613d71b9cf6.tar.gz
BASELINE: Update Chromium to 94.0.4606.111
Change-Id: I924781584def20fc800bedf6ff41fdb96c438193 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium/third_party/blink/public/web')
-rw-r--r--chromium/third_party/blink/public/web/DEPS8
-rw-r--r--chromium/third_party/blink/public/web/OWNERS2
-rw-r--r--chromium/third_party/blink/public/web/modules/autofill/OWNERS1
-rw-r--r--chromium/third_party/blink/public/web/modules/media/audio/fuchsia_audio_device_factory.h12
-rw-r--r--chromium/third_party/blink/public/web/modules/media/audio/web_audio_device_factory.h6
-rw-r--r--chromium/third_party/blink/public/web/modules/media/audio/web_audio_input_ipc_factory.h4
-rw-r--r--chromium/third_party/blink/public/web/modules/media/audio/web_audio_output_ipc_factory.h4
-rw-r--r--chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_sink.h6
-rw-r--r--chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_source.h11
-rw-r--r--chromium/third_party/blink/public/web/modules/mediastream/webmediaplayer_ms.h10
-rw-r--r--chromium/third_party/blink/public/web/web_ax_context.h9
-rw-r--r--chromium/third_party/blink/public/web/web_ax_object.h7
-rw-r--r--chromium/third_party/blink/public/web/web_custom_element.h5
-rw-r--r--chromium/third_party/blink/public/web/web_document.h24
-rw-r--r--chromium/third_party/blink/public/web/web_document_loader.h15
-rw-r--r--chromium/third_party/blink/public/web/web_element.h3
-rw-r--r--chromium/third_party/blink/public/web/web_frame.h6
-rw-r--r--chromium/third_party/blink/public/web/web_image.h4
-rw-r--r--chromium/third_party/blink/public/web/web_local_frame.h27
-rw-r--r--chromium/third_party/blink/public/web/web_local_frame_client.h34
-rw-r--r--chromium/third_party/blink/public/web/web_manifest_manager.h3
-rw-r--r--chromium/third_party/blink/public/web/web_navigation_params.h22
-rw-r--r--chromium/third_party/blink/public/web/web_optimization_guide_hints.h25
-rw-r--r--chromium/third_party/blink/public/web/web_performance.h2
-rw-r--r--chromium/third_party/blink/public/web/web_plugin.h7
-rw-r--r--chromium/third_party/blink/public/web/web_print_preset_options.h31
-rw-r--r--chromium/third_party/blink/public/web/web_remote_frame.h20
-rw-r--r--chromium/third_party/blink/public/web/web_remote_frame_client.h1
-rw-r--r--chromium/third_party/blink/public/web/web_savable_resources_test_support.h1
-rw-r--r--chromium/third_party/blink/public/web/web_security_policy.h12
-rw-r--r--chromium/third_party/blink/public/web/web_settings.h2
-rw-r--r--chromium/third_party/blink/public/web/web_view.h23
-rw-r--r--chromium/third_party/blink/public/web/web_view_client.h8
-rw-r--r--chromium/third_party/blink/public/web/web_widget.h17
34 files changed, 197 insertions, 175 deletions
diff --git a/chromium/third_party/blink/public/web/DEPS b/chromium/third_party/blink/public/web/DEPS
index 5c4e4a116a4..317e571b16c 100644
--- a/chromium/third_party/blink/public/web/DEPS
+++ b/chromium/third_party/blink/public/web/DEPS
@@ -34,19 +34,22 @@ include_rules = [
"+services/metrics/public/cpp/ukm_source_id.h",
"+services/network/public/cpp/web_sandbox_flags.h",
"+services/network/public/mojom/web_client_hints_types.mojom-shared.h",
- "+services/network/public/mojom/web_sandbox_flags.mojom-shared.h",
- "+services/network/public/mojom/web_sandbox_flags.mojom-blink-forward.h",
"+services/network/public/mojom/content_security_policy.mojom-shared.h",
"+services/network/public/mojom/cors.mojom-shared.h",
"+services/network/public/mojom/cors_origin_pattern.mojom-shared.h",
"+services/network/public/mojom/fetch_api.mojom-shared.h",
+ "+services/network/public/mojom/restricted_cookie_manager.mojom-shared.h",
"+services/network/public/mojom/ip_address_space.mojom-shared.h",
+ "+services/network/public/mojom/link_header.mojom-shared.h",
"+services/network/public/mojom/referrer_policy.mojom-shared.h",
"+services/network/public/mojom/url_loader.mojom-shared.h",
"+services/network/public/mojom/url_loader_factory.mojom-shared.h",
+ "+services/network/public/mojom/web_sandbox_flags.mojom-blink-forward.h",
+ "+services/network/public/mojom/web_sandbox_flags.mojom-shared.h",
"+services/service_manager/public",
"+ui/base/dragdrop/mojom/drag_drop_types.mojom-shared.h",
"+ui/base/ime/ime_text_span.h",
+ "+ui/display/mojom",
"+ui/events/types",
"+ui/gfx/geometry",
"+ui/gfx/range/range.h",
@@ -62,7 +65,6 @@ include_rules = [
"+ui/base/ime/mojom/virtual_keyboard_types.mojom-shared.h",
# Allowed only inside INSIDE_BLINK
- "+third_party/abseil-cpp/absl/types/optional.h",
"+third_party/blink/renderer/core",
"+third_party/blink/renderer/platform",
]
diff --git a/chromium/third_party/blink/public/web/OWNERS b/chromium/third_party/blink/public/web/OWNERS
index 5dff49dda0c..e17c4e5dde3 100644
--- a/chromium/third_party/blink/public/web/OWNERS
+++ b/chromium/third_party/blink/public/web/OWNERS
@@ -1,10 +1,8 @@
# Accessibility
per-file web_ax_object.h=file://third_party/blink/renderer/modules/accessibility/OWNERS
per-file web_ax_enums.h=file://third_party/blink/renderer/modules/accessibility/OWNERS
-per-file web_ax_enums.h=dtseng@chromium.org
# Page load metrics
-per-file web_performance.h=bmcquade@chromium.org
per-file web_performance.h=csharrison@chromium.org
# Workers
diff --git a/chromium/third_party/blink/public/web/modules/autofill/OWNERS b/chromium/third_party/blink/public/web/modules/autofill/OWNERS
deleted file mode 100644
index d691287b2d5..00000000000
--- a/chromium/third_party/blink/public/web/modules/autofill/OWNERS
+++ /dev/null
@@ -1 +0,0 @@
-jochen@chromium.org
diff --git a/chromium/third_party/blink/public/web/modules/media/audio/fuchsia_audio_device_factory.h b/chromium/third_party/blink/public/web/modules/media/audio/fuchsia_audio_device_factory.h
index 3022c1004d1..50497c70e7d 100644
--- a/chromium/third_party/blink/public/web/modules/media/audio/fuchsia_audio_device_factory.h
+++ b/chromium/third_party/blink/public/web/modules/media/audio/fuchsia_audio_device_factory.h
@@ -12,32 +12,32 @@
namespace blink {
// TODO(https://crbug.com/787252): Move this class out of the Blink API layer.
-class BLINK_MODULES_EXPORT FuchsiaAudioDeviceFactory
+class BLINK_MODULES_EXPORT FuchsiaAudioDeviceFactory final
: public WebAudioDeviceFactory {
public:
FuchsiaAudioDeviceFactory();
- ~FuchsiaAudioDeviceFactory() final;
+ ~FuchsiaAudioDeviceFactory() override;
protected:
scoped_refptr<media::AudioRendererSink> CreateFinalAudioRendererSink(
const LocalFrameToken& frame_token,
const media::AudioSinkParameters& params,
- base::TimeDelta auth_timeout) final;
+ base::TimeDelta auth_timeout) override;
scoped_refptr<media::AudioRendererSink> CreateAudioRendererSink(
WebAudioDeviceSourceType source_type,
const LocalFrameToken& frame_token,
- const media::AudioSinkParameters& params) final;
+ const media::AudioSinkParameters& params) override;
scoped_refptr<media::SwitchableAudioRendererSink>
CreateSwitchableAudioRendererSink(
WebAudioDeviceSourceType source_type,
const LocalFrameToken& frame_token,
- const media::AudioSinkParameters& params) final;
+ const media::AudioSinkParameters& params) override;
scoped_refptr<media::AudioCapturerSource> CreateAudioCapturerSource(
const LocalFrameToken& frame_token,
- const media::AudioSourceParameters& params) final;
+ const media::AudioSourceParameters& params) override;
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/modules/media/audio/web_audio_device_factory.h b/chromium/third_party/blink/public/web/modules/media/audio/web_audio_device_factory.h
index 230b24261de..c7c26342456 100644
--- a/chromium/third_party/blink/public/web/modules/media/audio/web_audio_device_factory.h
+++ b/chromium/third_party/blink/public/web/modules/media/audio/web_audio_device_factory.h
@@ -6,7 +6,6 @@
#define THIRD_PARTY_BLINK_PUBLIC_WEB_MODULES_MEDIA_AUDIO_WEB_AUDIO_DEVICE_FACTORY_H_
#include "base/callback.h"
-#include "base/macros.h"
#include "base/memory/scoped_refptr.h"
#include "media/audio/audio_sink_parameters.h"
#include "media/audio/audio_source_parameters.h"
@@ -31,6 +30,9 @@ namespace blink {
// AudioCapturerSourceFactory.
class BLINK_MODULES_EXPORT WebAudioDeviceFactory {
public:
+ WebAudioDeviceFactory(const WebAudioDeviceFactory&) = delete;
+ WebAudioDeviceFactory& operator=(const WebAudioDeviceFactory&) = delete;
+
// Maps the source type to the audio latency it requires.
static media::AudioLatency::LatencyType GetSourceLatencyType(
WebAudioDeviceSourceType source);
@@ -116,8 +118,6 @@ class BLINK_MODULES_EXPORT WebAudioDeviceFactory {
const LocalFrameToken& frame_token,
const media::AudioSinkParameters& params,
base::TimeDelta auth_timeout);
-
- DISALLOW_COPY_AND_ASSIGN(WebAudioDeviceFactory);
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/modules/media/audio/web_audio_input_ipc_factory.h b/chromium/third_party/blink/public/web/modules/media/audio/web_audio_input_ipc_factory.h
index 0d5d50dd946..c91f0f3deb9 100644
--- a/chromium/third_party/blink/public/web/modules/media/audio/web_audio_input_ipc_factory.h
+++ b/chromium/third_party/blink/public/web/modules/media/audio/web_audio_input_ipc_factory.h
@@ -29,6 +29,8 @@ class BLINK_MODULES_EXPORT WebAudioInputIPCFactory {
WebAudioInputIPCFactory(
scoped_refptr<base::SequencedTaskRunner> main_task_runner,
scoped_refptr<base::SingleThreadTaskRunner> io_task_runner);
+ WebAudioInputIPCFactory(const WebAudioInputIPCFactory&) = delete;
+ WebAudioInputIPCFactory& operator=(const WebAudioInputIPCFactory&) = delete;
~WebAudioInputIPCFactory();
static WebAudioInputIPCFactory& GetInstance();
@@ -45,8 +47,6 @@ class BLINK_MODULES_EXPORT WebAudioInputIPCFactory {
private:
const scoped_refptr<base::SequencedTaskRunner> main_task_runner_;
const scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_;
-
- DISALLOW_COPY_AND_ASSIGN(WebAudioInputIPCFactory);
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/modules/media/audio/web_audio_output_ipc_factory.h b/chromium/third_party/blink/public/web/modules/media/audio/web_audio_output_ipc_factory.h
index afa834b5d2c..5ae0c1f6527 100644
--- a/chromium/third_party/blink/public/web/modules/media/audio/web_audio_output_ipc_factory.h
+++ b/chromium/third_party/blink/public/web/modules/media/audio/web_audio_output_ipc_factory.h
@@ -36,6 +36,8 @@ class BLINK_MODULES_EXPORT WebAudioOutputIPCFactory {
public:
explicit WebAudioOutputIPCFactory(
scoped_refptr<base::SingleThreadTaskRunner> io_task_runner);
+ WebAudioOutputIPCFactory(const WebAudioOutputIPCFactory&) = delete;
+ WebAudioOutputIPCFactory& operator=(const WebAudioOutputIPCFactory&) = delete;
~WebAudioOutputIPCFactory();
static WebAudioOutputIPCFactory& GetInstance();
@@ -61,8 +63,6 @@ class BLINK_MODULES_EXPORT WebAudioOutputIPCFactory {
// Blink public API layer, move this Pimpl class back to its outer class.
class Impl;
std::unique_ptr<Impl> impl_;
-
- DISALLOW_COPY_AND_ASSIGN(WebAudioOutputIPCFactory);
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_sink.h b/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_sink.h
index 28930c5f290..5b23e745312 100644
--- a/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_sink.h
+++ b/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_sink.h
@@ -36,8 +36,10 @@ class BLINK_MODULES_EXPORT MediaStreamVideoSink : public WebMediaStreamSink {
// UsesAlpha indicates if this MediaStreamVideoSink might use its source's
// alpha channel (if the source has one). This should be kDefault unless it is
- // guaranteed that the alpha channel of |track| will be ignored.
- enum class UsesAlpha { kDefault, kNo };
+ // guaranteed that the alpha channel of |track| will be ignored. If
+ // kDependsOnOtherSinks is used, the sink will not receive alpha if all other
+ // sinks do not use alpha.
+ enum class UsesAlpha { kDefault, kDependsOnOtherSinks, kNo };
protected:
MediaStreamVideoSink();
diff --git a/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_source.h b/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_source.h
index 1195a51f935..5662be529ee 100644
--- a/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_source.h
+++ b/chromium/third_party/blink/public/web/modules/mediastream/media_stream_video_source.h
@@ -10,9 +10,7 @@
#include <vector>
#include "base/compiler_specific.h"
-#include "base/macros.h"
#include "base/memory/weak_ptr.h"
-#include "base/threading/thread_checker.h"
#include "media/base/video_frame.h"
#include "media/capture/video_capture_types.h"
#include "third_party/abseil-cpp/absl/types/optional.h"
@@ -60,7 +58,10 @@ class BLINK_MODULES_EXPORT MediaStreamVideoSource
// RestartCallback is used for both the StopForRestart and Restart operations.
using RestartCallback = base::OnceCallback<void(RestartResult)>;
- MediaStreamVideoSource();
+ explicit MediaStreamVideoSource(
+ scoped_refptr<base::SingleThreadTaskRunner> main_task_runner);
+ MediaStreamVideoSource(const MediaStreamVideoSource&) = delete;
+ MediaStreamVideoSource& operator=(const MediaStreamVideoSource&) = delete;
~MediaStreamVideoSource() override;
// Returns the MediaStreamVideoSource object owned by |source|.
@@ -181,7 +182,7 @@ class BLINK_MODULES_EXPORT MediaStreamVideoSource
virtual VideoCaptureFeedbackCB GetFeedbackCallback() const;
size_t NumTracks() const {
- DCHECK_CALLED_ON_VALID_THREAD(thread_checker_);
+ DCHECK(GetTaskRunner()->BelongsToCurrentThread());
return tracks_.size();
}
@@ -365,8 +366,6 @@ class BLINK_MODULES_EXPORT MediaStreamVideoSource
// died before this callback is resolved, we still need to trigger the
// callback to notify the caller that the request is canceled.
base::OnceClosure remove_last_track_callback_;
-
- DISALLOW_COPY_AND_ASSIGN(MediaStreamVideoSource);
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/modules/mediastream/webmediaplayer_ms.h b/chromium/third_party/blink/public/web/modules/mediastream/webmediaplayer_ms.h
index 9ac5e9b6777..53782ddd9d7 100644
--- a/chromium/third_party/blink/public/web/modules/mediastream/webmediaplayer_ms.h
+++ b/chromium/third_party/blink/public/web/modules/mediastream/webmediaplayer_ms.h
@@ -8,7 +8,6 @@
#include <memory>
#include <string>
-#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/single_thread_task_runner.h"
#include "base/synchronization/lock.h"
@@ -90,6 +89,9 @@ class BLINK_MODULES_EXPORT WebMediaPlayerMS
std::unique_ptr<WebVideoFrameSubmitter> submitter_,
WebMediaPlayer::SurfaceLayerMode surface_layer_mode);
+ WebMediaPlayerMS(const WebMediaPlayerMS&) = delete;
+ WebMediaPlayerMS& operator=(const WebMediaPlayerMS&) = delete;
+
~WebMediaPlayerMS() override;
WebMediaPlayer::LoadTiming Load(LoadType load_type,
@@ -174,10 +176,10 @@ class BLINK_MODULES_EXPORT WebMediaPlayerMS
void OnFrameShown() override;
void OnIdleTimeout() override;
- void OnFirstFrameReceived(media::VideoRotation video_rotation,
+ void OnFirstFrameReceived(media::VideoTransformation video_transform,
bool is_opaque);
void OnOpacityChanged(bool is_opaque);
- void OnRotationChanged(media::VideoRotation video_rotation);
+ void OnTransformChanged(media::VideoTransformation video_transform);
// WebMediaStreamObserver implementation
void TrackAdded(const WebString& track_id) override;
@@ -355,8 +357,6 @@ class BLINK_MODULES_EXPORT WebMediaPlayerMS
base::WeakPtr<WebMediaPlayerMS> weak_this_;
base::WeakPtrFactory<WebMediaPlayerMS> weak_factory_{this};
-
- DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerMS);
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/web_ax_context.h b/chromium/third_party/blink/public/web/web_ax_context.h
index c3e1728d463..cefdd30da9b 100644
--- a/chromium/third_party/blink/public/web/web_ax_context.h
+++ b/chromium/third_party/blink/public/web/web_ax_context.h
@@ -8,6 +8,10 @@
#include "third_party/blink/public/web/web_ax_object.h"
#include "third_party/blink/public/web/web_document.h"
+namespace ui {
+class AXMode;
+} // namespace ui
+
namespace blink {
class AXContext;
@@ -16,12 +20,15 @@ class AXContext;
// support for the given document.
class WebAXContext {
public:
- BLINK_EXPORT explicit WebAXContext(WebDocument document);
+ BLINK_EXPORT explicit WebAXContext(WebDocument document,
+ const ui::AXMode& mode);
BLINK_EXPORT ~WebAXContext();
// Returns the root element of the document's accessibility tree.
BLINK_EXPORT WebAXObject Root() const;
+ BLINK_EXPORT const ui::AXMode& GetAXMode() const;
+
private:
std::unique_ptr<AXContext> private_;
};
diff --git a/chromium/third_party/blink/public/web/web_ax_object.h b/chromium/third_party/blink/public/web/web_ax_object.h
index 1e5b15d3567..7342f45a663 100644
--- a/chromium/third_party/blink/public/web/web_ax_object.h
+++ b/chromium/third_party/blink/public/web/web_ax_object.h
@@ -38,7 +38,9 @@
#include "ui/accessibility/ax_enums.mojom-shared.h"
#include "ui/accessibility/ax_mode.h"
-class SkMatrix44;
+namespace skia {
+class Matrix44;
+}
namespace gfx {
class Point;
@@ -133,7 +135,6 @@ class WebAXObject {
BLINK_EXPORT void Serialize(ui::AXNodeData* node_data,
ui::AXMode accessibility_mode) const;
- BLINK_EXPORT bool IsAnchor() const;
BLINK_EXPORT ax::mojom::CheckedState CheckedState() const;
BLINK_EXPORT bool IsCheckable() const;
BLINK_EXPORT bool IsClickable() const;
@@ -346,7 +347,7 @@ class WebAXObject {
// or similar, set |clips_children| to true.
BLINK_EXPORT void GetRelativeBounds(WebAXObject& offset_container,
gfx::RectF& bounds_in_container,
- SkMatrix44& container_transform,
+ skia::Matrix44& container_transform,
bool* clips_children = nullptr) const;
// Retrieves a vector of all WebAXObjects in this document whose
diff --git a/chromium/third_party/blink/public/web/web_custom_element.h b/chromium/third_party/blink/public/web/web_custom_element.h
index fca6c280668..84305f05477 100644
--- a/chromium/third_party/blink/public/web/web_custom_element.h
+++ b/chromium/third_party/blink/public/web/web_custom_element.h
@@ -31,7 +31,6 @@
#ifndef THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_CUSTOM_ELEMENT_H_
#define THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_CUSTOM_ELEMENT_H_
-#include "base/macros.h"
#include "third_party/blink/public/platform/web_common.h"
namespace blink {
@@ -52,12 +51,14 @@ class WebCustomElement {
class BLINK_EXPORT EmbedderNamesAllowedScope {
public:
EmbedderNamesAllowedScope();
+ EmbedderNamesAllowedScope(const EmbedderNamesAllowedScope&) = delete;
+ EmbedderNamesAllowedScope& operator=(const EmbedderNamesAllowedScope&) =
+ delete;
~EmbedderNamesAllowedScope();
static bool IsAllowed();
private:
- DISALLOW_COPY_AND_ASSIGN(EmbedderNamesAllowedScope);
void* operator new(size_t) = delete;
};
diff --git a/chromium/third_party/blink/public/web/web_document.h b/chromium/third_party/blink/public/web/web_document.h
index 4c9a6b2743c..9b465acce1c 100644
--- a/chromium/third_party/blink/public/web/web_document.h
+++ b/chromium/third_party/blink/public/web/web_document.h
@@ -34,6 +34,8 @@
#include "net/cookies/site_for_cookies.h"
#include "services/metrics/public/cpp/ukm_source_id.h"
#include "services/network/public/mojom/referrer_policy.mojom-shared.h"
+#include "services/network/public/mojom/restricted_cookie_manager.mojom-shared.h"
+#include "third_party/blink/public/platform/cross_variant_mojo_util.h"
#include "third_party/blink/public/platform/web_security_origin.h"
#include "third_party/blink/public/platform/web_vector.h"
#include "third_party/blink/public/web/web_draggable_region.h"
@@ -82,8 +84,8 @@ class WebDocument : public WebNode {
BLINK_EXPORT WebString Encoding() const;
BLINK_EXPORT WebString ContentLanguage() const;
BLINK_EXPORT WebString GetReferrer() const;
- BLINK_EXPORT absl::optional<SkColor> ThemeColor() const;
- // The url of the OpenSearch Desription Document (if any).
+ BLINK_EXPORT absl::optional<SkColor> ThemeColor();
+ // The url of the OpenSearch Description Document (if any).
BLINK_EXPORT WebURL OpenSearchDescriptionURL() const;
// Returns the frame the document belongs to or 0 if the document is
@@ -106,7 +108,7 @@ class WebDocument : public WebNode {
BLINK_EXPORT WebElement Head();
BLINK_EXPORT WebString Title() const;
BLINK_EXPORT WebString ContentAsTextForTesting() const;
- BLINK_EXPORT WebElementCollection All();
+ BLINK_EXPORT WebElementCollection All() const;
BLINK_EXPORT WebVector<WebFormElement> Forms() const;
BLINK_EXPORT WebURL CompleteURL(const WebString&) const;
BLINK_EXPORT WebElement GetElementById(const WebString&) const;
@@ -142,6 +144,22 @@ class WebDocument : public WebNode {
BLINK_EXPORT bool IsLoaded();
+ // Returns true if the document is in prerendering.
+ BLINK_EXPORT bool IsPrerendering();
+
+ // Return true if accessibility processing has been enabled.
+ BLINK_EXPORT bool IsAccessibilityEnabled();
+
+ // Adds `callback` to the post-prerendering activation steps.
+ // https://jeremyroman.github.io/alternate-loading-modes/#document-post-prerendering-activation-steps-list
+ BLINK_EXPORT void AddPostPrerenderingActivationStep(
+ base::OnceClosure callback);
+
+ // Sets a cookie manager which can be used for this document.
+ BLINK_EXPORT void SetCookieManager(
+ CrossVariantMojoRemote<
+ network::mojom::RestrictedCookieManagerInterfaceBase> cookie_manager);
+
#if INSIDE_BLINK
BLINK_EXPORT WebDocument(Document*);
BLINK_EXPORT WebDocument& operator=(Document*);
diff --git a/chromium/third_party/blink/public/web/web_document_loader.h b/chromium/third_party/blink/public/web/web_document_loader.h
index f897ebebab6..273fc965ba6 100644
--- a/chromium/third_party/blink/public/web/web_document_loader.h
+++ b/chromium/third_party/blink/public/web/web_document_loader.h
@@ -36,6 +36,7 @@
#include "services/network/public/mojom/ip_address_space.mojom-shared.h"
#include "services/network/public/mojom/referrer_policy.mojom-shared.h"
#include "third_party/blink/public/common/loader/previews_state.h"
+#include "third_party/blink/public/mojom/loader/code_cache.mojom.h"
#include "third_party/blink/public/platform/web_archive_info.h"
#include "third_party/blink/public/platform/web_common.h"
#include "third_party/blink/public/platform/web_source_location.h"
@@ -47,8 +48,6 @@ class WebDocumentSubresourceFilter;
class WebServiceWorkerNetworkProvider;
class WebURL;
class WebURLResponse;
-template <typename T>
-class WebVector;
namespace mojom {
enum class FetchCacheMode : int32_t;
@@ -93,14 +92,6 @@ class BLINK_EXPORT WebDocumentLoader {
virtual bool HasUnreachableURL() const = 0;
virtual WebURL UnreachableURL() const = 0;
- // Returns all redirects that occurred (both client and server) before
- // at last committing the current page. This will contain one entry
- // for each intermediate URL, and one entry for the last URL (so if
- // there are no redirects, it will contain exactly the current URL, and
- // if there is one redirect, it will contain the source and destination
- // URL).
- virtual void RedirectChain(WebVector<WebURL>&) const = 0;
-
// Returns whether the navigation associated with this datasource is a
// client redirect.
virtual bool IsClientRedirect() const = 0;
@@ -156,6 +147,10 @@ class BLINK_EXPORT WebDocumentLoader {
// Returns true when the document is a FTP directory.
virtual bool IsListingFtpDirectory() const = 0;
+ // Sets the CodeCacheHost for this loader.
+ virtual void SetCodeCacheHost(
+ mojo::PendingRemote<mojom::CodeCacheHost> code_cache_host) = 0;
+
protected:
~WebDocumentLoader() = default;
};
diff --git a/chromium/third_party/blink/public/web/web_element.h b/chromium/third_party/blink/public/web/web_element.h
index 18351649707..940937d6e00 100644
--- a/chromium/third_party/blink/public/web/web_element.h
+++ b/chromium/third_party/blink/public/web/web_element.h
@@ -85,6 +85,9 @@ class BLINK_EXPORT WebElement : public WebNode {
// Returns true if this is an autonomous custom element.
bool IsAutonomousCustomElement() const;
+ // Returns the owning shadow host for this element, if there is one.
+ WebElement OwnerShadowHost() const;
+
// Returns an author ShadowRoot attached to this element, regardless
// of open or closed. This returns null WebNode if this
// element has no ShadowRoot or has a UA ShadowRoot.
diff --git a/chromium/third_party/blink/public/web/web_frame.h b/chromium/third_party/blink/public/web/web_frame.h
index a70289aff20..2eeeafe1c5c 100644
--- a/chromium/third_party/blink/public/web/web_frame.h
+++ b/chromium/third_party/blink/public/web/web_frame.h
@@ -162,6 +162,10 @@ class BLINK_EXPORT WebFrame {
// the given node is not a frame, iframe or if the frame is empty.
static WebFrame* FromFrameOwnerElement(const WebNode&);
+ // Whether the owner element of this frame is in the document tree or the
+ // shadow tree, per https://w3c.github.io/webcomponents/spec/shadow/.
+ mojom::TreeScopeType GetTreeScopeType() const { return scope_; }
+
// This identifier represents the stable identifier between a
// LocalFrame <--> RenderFrameHostImpl or a
// RemoteFrame <--> RenderFrameProxyHost in the browser process.
@@ -170,8 +174,6 @@ class BLINK_EXPORT WebFrame {
#if INSIDE_BLINK
static WebFrame* FromCoreFrame(Frame*);
static Frame* ToCoreFrame(const WebFrame&);
-
- bool InShadowTree() const { return scope_ == mojom::TreeScopeType::kShadow; }
#endif
protected:
diff --git a/chromium/third_party/blink/public/web/web_image.h b/chromium/third_party/blink/public/web/web_image.h
index 3a4cfc5329e..413b5ef4d6e 100644
--- a/chromium/third_party/blink/public/web/web_image.h
+++ b/chromium/third_party/blink/public/web/web_image.h
@@ -56,7 +56,9 @@ class WebImage {
// Decodes the given image data. If the image has multiple frames,
// then the frame whose size is desired_size is returned. Otherwise,
- // the first frame is returned.
+ // the first frame is returned. If the image contains EXIF data that changes
+ // the orientation, the returned image will be rotated such that the result is
+ // top-left oriented.
BLINK_EXPORT static SkBitmap FromData(const WebData&,
const gfx::Size& desired_size);
diff --git a/chromium/third_party/blink/public/web/web_local_frame.h b/chromium/third_party/blink/public/web/web_local_frame.h
index fd6ce9a3df3..7635bf51cb1 100644
--- a/chromium/third_party/blink/public/web/web_local_frame.h
+++ b/chromium/third_party/blink/public/web/web_local_frame.h
@@ -27,6 +27,7 @@
#include "third_party/blink/public/mojom/commit_result/commit_result.mojom-shared.h"
#include "third_party/blink/public/mojom/devtools/devtools_agent.mojom-shared.h"
#include "third_party/blink/public/mojom/devtools/inspector_issue.mojom-shared.h"
+#include "third_party/blink/public/mojom/dom_storage/storage_area.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/lifecycle.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/media_player_action.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/user_activation_notification_type.mojom-shared.h"
@@ -45,7 +46,6 @@
#include "third_party/blink/public/web/web_frame_load_type.h"
#include "third_party/blink/public/web/web_history_item.h"
#include "third_party/blink/public/web/web_navigation_params.h"
-#include "third_party/blink/public/web/web_optimization_guide_hints.h"
#include "ui/accessibility/ax_tree_id.h"
#include "ui/base/ime/ime_text_span.h"
#include "ui/gfx/range/range.h"
@@ -369,6 +369,9 @@ class WebLocalFrame : public WebFrame {
// Returns the world ID associated with |script_context|.
virtual int32_t GetScriptContextWorldId(
v8::Local<v8::Context> script_context) const = 0;
+ virtual v8::Local<v8::Context> GetScriptContextFromWorldId(
+ v8::Isolate* isolate,
+ int world_id) const = 0;
// Executes script in the context of the current page and returns the value
// that the script evaluated to with callback. Script execution can be
@@ -794,12 +797,6 @@ class WebLocalFrame : public WebFrame {
UserActivationUpdateSource update_source =
UserActivationUpdateSource::kRenderer) = 0;
- // Optimization Guide --------------------------------------------------------
-
- // Sets the optimization hints provided by the optimization guide service. See
- // //components/optimization_guide/README.md.
- virtual void SetOptimizationGuideHints(const WebOptimizationGuideHints&) = 0;
-
// Testing ------------------------------------------------------------------
// Get the total spool size (the bounding box of all the pages placed after
@@ -842,6 +839,22 @@ class WebLocalFrame : public WebFrame {
// Reset TextFinder state for the web test runner in between two tests.
virtual void ClearActiveFindMatchForTesting() = 0;
+ virtual bool ServiceWorkerSubresourceFilterEnabled() = 0;
+
+ // Sets a local storage area which can be used for this frame. This storage
+ // area is ignored if a cached storage area already exists for the storage
+ // key.
+ virtual void SetLocalStorageArea(
+ CrossVariantMojoRemote<mojom::StorageAreaInterfaceBase>
+ local_storage_area) = 0;
+
+ // Sets a session storage area which can be used for this frame. This storage
+ // area is ignored if a cached storage area already exists for the storage
+ // key and namespace.
+ virtual void SetSessionStorageArea(
+ CrossVariantMojoRemote<mojom::StorageAreaInterfaceBase>
+ session_storage_area) = 0;
+
protected:
explicit WebLocalFrame(mojom::TreeScopeType scope,
const LocalFrameToken& frame_token)
diff --git a/chromium/third_party/blink/public/web/web_local_frame_client.h b/chromium/third_party/blink/public/web/web_local_frame_client.h
index c17f15d9cbf..99ddb8f4494 100644
--- a/chromium/third_party/blink/public/web/web_local_frame_client.h
+++ b/chromium/third_party/blink/public/web/web_local_frame_client.h
@@ -51,6 +51,7 @@
#include "third_party/blink/public/mojom/frame/lifecycle.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/triggering_event_info.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/user_activation_update_types.mojom-shared.h"
+#include "third_party/blink/public/mojom/loader/same_document_navigation_type.mojom-shared.h"
#include "third_party/blink/public/mojom/media/renderer_audio_input_stream_factory.mojom-shared.h"
#include "third_party/blink/public/mojom/portal/portal.mojom-shared.h"
#include "third_party/blink/public/platform/blame_context.h"
@@ -262,6 +263,13 @@ class BLINK_EXPORT WebLocalFrameClient {
return nullptr;
}
+ // Request the creation of a new fenced frame, and return the WebRemoteFrame*
+ // associated with it.
+ virtual WebRemoteFrame* CreateFencedFrame(
+ const WebElement& fenced_frame_element) {
+ return nullptr;
+ }
+
// Called when Blink cannot find a frame with the given name in the frame's
// browsing instance. This gives the embedder a chance to return a frame
// from outside of the browsing instance.
@@ -419,12 +427,19 @@ class BLINK_EXPORT WebLocalFrameClient {
// |is_synchronously_committed| is true if the navigation is synchronously
// committed from within Blink, as opposed to being driven by the browser's
// navigation stack.
- virtual void DidFinishSameDocumentNavigation(WebHistoryCommitType,
- bool is_synchronously_committed,
- bool is_history_api_navigation,
- bool is_client_redirect) {}
+ virtual void DidFinishSameDocumentNavigation(
+ WebHistoryCommitType,
+ bool is_synchronously_committed,
+ mojom::SameDocumentNavigationType,
+ bool is_client_redirect) {}
+
+ // Called before a frame's page is frozen.
+ virtual void WillFreezePage() {}
- // Called when a RenderFrame's page lifecycle state gets updated.
+ // The frame's document changed its URL due to document.open().
+ virtual void DidOpenDocumentInputStream(const WebURL&) {}
+
+ // Called when a frame's page lifecycle state gets updated.
virtual void DidSetPageLifecycleState() {}
// Called upon update to scroll position, document state, and other
@@ -539,11 +554,6 @@ class BLINK_EXPORT WebLocalFrameClient {
virtual void DidObserveLayoutShift(double score, bool after_input_or_scroll) {
}
- // Reports input timestamps for segmenting layout shifts by users inputs to
- // create Session window.
- virtual void DidObserveInputForLayoutShiftTracking(
- base::TimeTicks timestamp) {}
-
// Reports the number of LayoutBlock creation, and LayoutObject::UpdateLayout
// calls. All values are deltas since the last calls of this function.
virtual void DidObserveLayoutNg(uint32_t all_block_count,
@@ -758,6 +768,10 @@ class BLINK_EXPORT WebLocalFrameClient {
// than the document's URL because it will contain a data URL if a base URL
// was used for its load or if an unreachable URL was used.
virtual WebURL LastCommittedUrlForUKM() { return WebURL(); }
+
+ // Called when script in the frame (and it subframes) wishes to be printed via
+ // a window.print() call.
+ virtual void ScriptedPrint() {}
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/web_manifest_manager.h b/chromium/third_party/blink/public/web/web_manifest_manager.h
index 503e2c676d9..d37c6a98f66 100644
--- a/chromium/third_party/blink/public/web/web_manifest_manager.h
+++ b/chromium/third_party/blink/public/web/web_manifest_manager.h
@@ -10,13 +10,12 @@
namespace blink {
-struct Manifest;
class WebLocalFrame;
class WebURL;
class WebManifestManager {
public:
- using Callback = base::OnceCallback<void(const WebURL&, const Manifest&)>;
+ using Callback = base::OnceCallback<void(const WebURL&)>;
BLINK_EXPORT static void RequestManifestForTesting(WebLocalFrame*,
Callback callback);
diff --git a/chromium/third_party/blink/public/web/web_navigation_params.h b/chromium/third_party/blink/public/web/web_navigation_params.h
index 8583eb494ab..e07991ccb63 100644
--- a/chromium/third_party/blink/public/web/web_navigation_params.h
+++ b/chromium/third_party/blink/public/web/web_navigation_params.h
@@ -11,11 +11,13 @@
#include "base/time/time.h"
#include "base/unguessable_token.h"
#include "services/metrics/public/cpp/ukm_source_id.h"
+#include "services/network/public/mojom/link_header.mojom-shared.h"
#include "services/network/public/mojom/referrer_policy.mojom-shared.h"
#include "services/network/public/mojom/url_loader_factory.mojom-shared.h"
#include "services/network/public/mojom/web_client_hints_types.mojom-shared.h"
#include "third_party/abseil-cpp/absl/types/optional.h"
#include "third_party/blink/public/common/frame/frame_policy.h"
+#include "third_party/blink/public/common/storage_key/storage_key.h"
#include "third_party/blink/public/common/tokens/tokens.h"
#include "third_party/blink/public/mojom/blob/blob_url_store.mojom-shared.h"
#include "third_party/blink/public/mojom/fetch/fetch_api_request.mojom-shared.h"
@@ -310,9 +312,18 @@ struct BLINK_EXPORT WebNavigationParams {
// The origin in which a navigation should commit. When provided, Blink
// should use this origin directly and not compute locally the new document
// origin.
- // TODO(arthursonzogni): Always provide origin_to_commit.
+ //
+ // TODO(https://crbug.com/888079): Always provide origin_to_commit.
WebSecurityOrigin origin_to_commit;
+ // The storage key of the document that will be created by the navigation.
+ // This is compatible with the `origin_to_commit`. Until the browser will be
+ // able to compute the `origin_to_commit` in all cases
+ // (https://crbug.com/888079), this is actually just a provisional
+ // `storage_key`. The final storage key is computed by the document loader
+ // taking into account the origin computed by the renderer.
+ StorageKey storage_key;
+
// The sandbox flags to apply to the new document. This is the union of:
// - the frame's current sandbox attribute, taken when the navigation started.
// - the navigation response's CSP sandbox flags.
@@ -343,8 +354,6 @@ struct BLINK_EXPORT WebNavigationParams {
bool has_text_fragment_token = false;
// Whether this navigation was browser initiated.
bool is_browser_initiated = false;
- // Whether this navigation was for prerendering.
- bool is_prerendering = false;
// Whether the document should be able to access local file:// resources.
bool grant_load_local_resources = false;
// The previews state which should be used for this navigation.
@@ -356,6 +365,10 @@ struct BLINK_EXPORT WebNavigationParams {
// The AppCache host id for this navigation.
base::UnguessableToken appcache_host_id;
+ // This is `true` only for commit requests coming from
+ // `RenderFrameImpl::SynchronouslyConmmitAboutBlankForBug778318`.
+ bool is_synchronous_commit_for_bug_778318 = false;
+
// Used for SignedExchangeSubresourcePrefetch.
// This struct keeps the information about a prefetched signed exchange.
struct BLINK_EXPORT PrefetchedSignedExchange {
@@ -428,6 +441,9 @@ struct BLINK_EXPORT WebNavigationParams {
// appHistory.
WebVector<WebHistoryItem> app_history_back_entries;
WebVector<WebHistoryItem> app_history_forward_entries;
+
+ // List of URLs which are preloaded by HTTP Early Hints.
+ WebVector<WebURL> early_hints_preloaded_resources;
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/web_optimization_guide_hints.h b/chromium/third_party/blink/public/web/web_optimization_guide_hints.h
deleted file mode 100644
index 7d1c1c83cfd..00000000000
--- a/chromium/third_party/blink/public/web/web_optimization_guide_hints.h
+++ /dev/null
@@ -1,25 +0,0 @@
-// Copyright 2020 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_OPTIMIZATION_GUIDE_HINTS_H_
-#define THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_OPTIMIZATION_GUIDE_HINTS_H_
-
-#include "third_party/abseil-cpp/absl/types/optional.h"
-#include "third_party/blink/public/mojom/optimization_guide/optimization_guide.mojom-shared.h"
-
-namespace blink {
-
-struct WebOptimizationGuideHints {
- absl::optional<mojom::DelayAsyncScriptExecutionDelayType>
- delay_async_script_execution_delay_type;
-
- absl::optional<mojom::DelayCompetingLowPriorityRequestsDelayType>
- delay_competing_low_priority_requests_delay_type;
- absl::optional<mojom::DelayCompetingLowPriorityRequestsPriorityThreshold>
- delay_competing_low_priority_requests_priority_threshold;
-};
-
-} // namespace blink
-
-#endif // THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_OPTIMIZATION_GUIDE_HINTS_H_
diff --git a/chromium/third_party/blink/public/web/web_performance.h b/chromium/third_party/blink/public/web/web_performance.h
index 1a0eb915bdd..fa2dfe0c836 100644
--- a/chromium/third_party/blink/public/web/web_performance.h
+++ b/chromium/third_party/blink/public/web/web_performance.h
@@ -32,6 +32,7 @@
#define THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_PERFORMANCE_H_
#include "base/time/time.h"
+#include "third_party/abseil-cpp/absl/types/optional.h"
#include "third_party/blink/public/platform/web_common.h"
#include "third_party/blink/public/platform/web_private_ptr.h"
#include "third_party/blink/public/platform/web_vector.h"
@@ -138,6 +139,7 @@ class WebPerformance {
BLINK_EXPORT double ParseBlockedOnScriptExecutionFromDocumentWriteDuration()
const;
BLINK_EXPORT absl::optional<base::TimeTicks> LastPortalActivatedPaint() const;
+ BLINK_EXPORT absl::optional<base::TimeDelta> PrerenderActivationStart() const;
BLINK_EXPORT absl::optional<base::TimeTicks> UnloadStart() const;
BLINK_EXPORT absl::optional<base::TimeTicks> UnloadEnd() const;
BLINK_EXPORT absl::optional<base::TimeTicks> CommitNavigationEnd() const;
diff --git a/chromium/third_party/blink/public/web/web_plugin.h b/chromium/third_party/blink/public/web/web_plugin.h
index c826ca02570..d055e7e4cce 100644
--- a/chromium/third_party/blink/public/web/web_plugin.h
+++ b/chromium/third_party/blink/public/web/web_plugin.h
@@ -147,8 +147,6 @@ class WebPlugin {
virtual bool GetPrintPresetOptionsFromDocument(WebPrintPresetOptions*) {
return false;
}
- // Returns true if the plugin is a PDF plugin.
- virtual bool IsPdfPlugin() { return false; }
// Sets up printing with the specified printParams. Returns the number of
// pages to be printed at these settings.
@@ -238,10 +236,7 @@ class WebPlugin {
virtual void StopFind() {}
// View rotation types.
- enum RotationType {
- kRotationType90Clockwise,
- kRotationType90Counterclockwise
- };
+ enum class RotationType { k90Clockwise, k90Counterclockwise };
// Whether the plugin can rotate the view of its content.
virtual bool CanRotateView() { return false; }
// Rotates the plugin's view of its content.
diff --git a/chromium/third_party/blink/public/web/web_print_preset_options.h b/chromium/third_party/blink/public/web/web_print_preset_options.h
index be28b55ec5c..c0c0cb834d4 100644
--- a/chromium/third_party/blink/public/web/web_print_preset_options.h
+++ b/chromium/third_party/blink/public/web/web_print_preset_options.h
@@ -5,44 +5,25 @@
#ifndef THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_PRINT_PRESET_OPTIONS_H_
#define THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_PRINT_PRESET_OPTIONS_H_
-#include <vector>
-
#include "printing/mojom/print.mojom-shared.h"
+#include "third_party/abseil-cpp/absl/types/optional.h"
#include "ui/gfx/geometry/size.h"
namespace blink {
-struct WebPageRange;
-typedef std::vector<WebPageRange> WebPageRanges;
-
-struct WebPageRange {
- int from;
- int to;
-};
-
struct WebPrintPresetOptions {
- WebPrintPresetOptions()
- : is_scaling_disabled(false),
- copies(0),
- duplex_mode(printing::mojom::DuplexMode::kUnknownDuplexMode) {}
-
// Specifies whether scaling is disabled.
- bool is_scaling_disabled;
+ bool is_scaling_disabled = false;
// Specifies the number of copies to be printed.
- int copies;
+ int copies = 0;
// Specifies duplex mode to be used for printing.
- printing::mojom::DuplexMode duplex_mode;
-
- // Specifies page range to be used for printing.
- WebPageRanges page_ranges;
-
- // True if all the pages in the PDF are the same size.
- bool is_page_size_uniform;
+ printing::mojom::DuplexMode duplex_mode =
+ printing::mojom::DuplexMode::kUnknownDuplexMode;
// Only valid if the page sizes are uniform. The page size in points.
- gfx::Size uniform_page_size;
+ absl::optional<gfx::Size> uniform_page_size;
};
} // namespace blink
diff --git a/chromium/third_party/blink/public/web/web_remote_frame.h b/chromium/third_party/blink/public/web/web_remote_frame.h
index c05190b0ce4..112f3b0b1d8 100644
--- a/chromium/third_party/blink/public/web/web_remote_frame.h
+++ b/chromium/third_party/blink/public/web/web_remote_frame.h
@@ -7,7 +7,6 @@
#include "third_party/blink/public/common/permissions_policy/permissions_policy.h"
#include "third_party/blink/public/common/tokens/tokens.h"
-#include "third_party/blink/public/mojom/ad_tagging/ad_frame.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/frame_owner_element_type.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/user_activation_notification_type.mojom-shared.h"
#include "third_party/blink/public/mojom/frame/user_activation_update_types.mojom-shared.h"
@@ -54,15 +53,15 @@ class WebRemoteFrame : public WebFrame {
WebFrame* opener);
// Also performs core initialization to associate the created remote frame
- // with the provided <portal> element.
- BLINK_EXPORT static WebRemoteFrame* CreateForPortal(
+ // with the provided <portal> or <fencedframe> element.
+ BLINK_EXPORT static WebRemoteFrame* CreateForPortalOrFencedFrame(
mojom::TreeScopeType,
WebRemoteFrameClient*,
InterfaceRegistry*,
AssociatedInterfaceProvider*,
const RemoteFrameToken& frame_token,
const base::UnguessableToken& devtools_frame_token,
- const WebElement& portal_element);
+ const WebElement& frame_owner);
// Specialized factory methods to allow the embedder to replicate the frame
// tree between processes.
@@ -117,14 +116,10 @@ class WebRemoteFrame : public WebFrame {
virtual void SetReplicatedInsecureNavigationsSet(
const WebVector<unsigned>&) = 0;
- virtual void SetReplicatedAdFrameType(
- blink::mojom::AdFrameType ad_frame_type) = 0;
+ virtual void SetReplicatedIsAdSubframe(bool is_ad_subframe) = 0;
virtual void DidStartLoading() = 0;
- // Returns true if this frame should be ignored during hittesting.
- virtual bool IsIgnoredForHitTest() const = 0;
-
// Update the user activation state in appropriate part of this frame's
// "local" frame tree (ancestors-only vs all-nodes).
//
@@ -136,13 +131,6 @@ class WebRemoteFrame : public WebFrame {
virtual void SetHadStickyUserActivationBeforeNavigation(bool value) = 0;
- virtual void SynchronizeVisualProperties() = 0;
- virtual void ResendVisualProperties() = 0;
-
- // Returns the ideal raster scale factor for the OOPIF's compositor so that it
- // doesn't raster at a higher scale than it needs to.
- virtual float GetCompositingScaleFactor() = 0;
-
// Unique name is an opaque identifier for maintaining association with
// session restore state for this frame.
virtual WebString UniqueName() const = 0;
diff --git a/chromium/third_party/blink/public/web/web_remote_frame_client.h b/chromium/third_party/blink/public/web/web_remote_frame_client.h
index 6184d3e4714..3f6402358d9 100644
--- a/chromium/third_party/blink/public/web/web_remote_frame_client.h
+++ b/chromium/third_party/blink/public/web/web_remote_frame_client.h
@@ -7,7 +7,6 @@
#include "cc/paint/paint_canvas.h"
#include "components/viz/common/surfaces/surface_id.h"
-#include "third_party/abseil-cpp/absl/types/optional.h"
#include "third_party/blink/public/common/associated_interfaces/associated_interface_provider.h"
#include "third_party/blink/public/common/tokens/tokens.h"
#include "third_party/blink/public/mojom/blob/blob_url_store.mojom-shared.h"
diff --git a/chromium/third_party/blink/public/web/web_savable_resources_test_support.h b/chromium/third_party/blink/public/web/web_savable_resources_test_support.h
index 8281f5c4359..ec09a18964b 100644
--- a/chromium/third_party/blink/public/web/web_savable_resources_test_support.h
+++ b/chromium/third_party/blink/public/web/web_savable_resources_test_support.h
@@ -5,7 +5,6 @@
#ifndef THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_SAVABLE_RESOURCES_TEST_SUPPORT_H_
#define THIRD_PARTY_BLINK_PUBLIC_WEB_WEB_SAVABLE_RESOURCES_TEST_SUPPORT_H_
-#include "base/macros.h"
#include "third_party/blink/public/platform/web_common.h"
namespace blink {
diff --git a/chromium/third_party/blink/public/web/web_security_policy.h b/chromium/third_party/blink/public/web/web_security_policy.h
index 40e49d9306b..c6613ea15a2 100644
--- a/chromium/third_party/blink/public/web/web_security_policy.h
+++ b/chromium/third_party/blink/public/web/web_security_policy.h
@@ -130,6 +130,18 @@ class WebSecurityPolicy {
// Registers an URL scheme as an error page.
BLINK_EXPORT static void RegisterURLSchemeAsError(const WebString&);
+ // Registers an URL scheme as a browser extension.
+ BLINK_EXPORT static void RegisterURLSchemeAsExtension(const WebString&);
+
+ // Registers an URL scheme as trusted browser UI.
+ BLINK_EXPORT static void RegisterURLSchemeAsWebUI(const WebString&);
+
+ // Registers an URL scheme which can use code caching but must check in the
+ // renderer whether the script content has changed rather than relying on a
+ // response time match from the network cache.
+ BLINK_EXPORT static void RegisterURLSchemeAsCodeCacheWithHashing(
+ const WebString&);
+
private:
WebSecurityPolicy() = delete;
};
diff --git a/chromium/third_party/blink/public/web/web_settings.h b/chromium/third_party/blink/public/web/web_settings.h
index e555570ac36..73a644ee08a 100644
--- a/chromium/third_party/blink/public/web/web_settings.h
+++ b/chromium/third_party/blink/public/web/web_settings.h
@@ -172,7 +172,6 @@ class WebSettings {
virtual void SetMinimumLogicalFontSize(int) = 0;
virtual void SetHideScrollbars(bool) = 0;
virtual void SetOfflineWebApplicationCacheEnabled(bool) = 0;
- virtual void SetPassiveEventListenerDefault(PassiveEventListenerDefault) = 0;
virtual void SetPasswordEchoDurationInSeconds(double) = 0;
virtual void SetPasswordEchoEnabled(bool) = 0;
virtual void SetPictographFontFamily(const WebString&,
@@ -285,6 +284,7 @@ class WebSettings {
virtual void SetSelectionClipboardBufferAvailable(bool) = 0;
virtual void SetAccessibilityIncludeSvgGElement(bool) = 0;
virtual void SetWebXRImmersiveArAllowed(bool) = 0;
+ virtual void SetLitePageSubresourceRedirectOrigin(const WebString&) = 0;
protected:
~WebSettings() = default;
diff --git a/chromium/third_party/blink/public/web/web_view.h b/chromium/third_party/blink/public/web/web_view.h
index 7acd3f2bf49..f54b993e9fb 100644
--- a/chromium/third_party/blink/public/web/web_view.h
+++ b/chromium/third_party/blink/public/web/web_view.h
@@ -41,13 +41,13 @@
#include "third_party/blink/public/mojom/page/page.mojom-shared.h"
#include "third_party/blink/public/mojom/page/page_visibility_state.mojom-shared.h"
#include "third_party/blink/public/mojom/renderer_preference_watcher.mojom-shared.h"
-#include "third_party/blink/public/mojom/widget/screen_orientation.mojom-shared.h"
#include "third_party/blink/public/platform/cross_variant_mojo_util.h"
#include "third_party/blink/public/platform/scheduler/web_agent_group_scheduler.h"
#include "third_party/blink/public/platform/web_string.h"
#include "third_party/blink/public/platform/web_url.h"
#include "third_party/blink/public/web/web_settings.h"
#include "third_party/skia/include/core/SkColor.h"
+#include "ui/display/mojom/screen_orientation.mojom-shared.h"
#include "ui/gfx/geometry/size.h"
namespace cc {
@@ -98,6 +98,8 @@ class WebView {
//
// clients may be null, but should both be null or not together.
// |is_hidden| defines the initial visibility of the page.
+ // |is_prerendering| defines whether the page is being prerendered by the
+ // Prerender2 feature (see content/browser/prerender/README.md).
// [is_inside_portal] defines whether the page is inside_portal.
// |compositing_enabled| dictates whether accelerated compositing should be
// enabled for the page. It must be false if no clients are provided, or if a
@@ -114,10 +116,14 @@ class WebView {
// to inform blink it is in the foreground or background. Whereas this bit
// refers to user-visibility and whether the tab needs to produce pixels to
// put on the screen at some point or not.
+ // |page_base_background_color| initial base background color used by the main
+ // frame. Set on create to avoid races. Passing in nullopt indicates the
+ // default base background color should be used.
// TODO(yuzus): Remove |is_hidden| and start using |PageVisibilityState|.
BLINK_EXPORT static WebView* Create(
WebViewClient*,
bool is_hidden,
+ bool is_prerendering,
bool is_inside_portal,
bool compositing_enabled,
bool widgets_never_composited,
@@ -125,7 +131,8 @@ class WebView {
CrossVariantMojoAssociatedReceiver<mojom::PageBroadcastInterfaceBase>
page_handle,
scheduler::WebAgentGroupScheduler& agent_group_scheduler,
- const SessionStorageNamespaceId& session_storage_namespace_id);
+ const SessionStorageNamespaceId& session_storage_namespace_id,
+ absl::optional<SkColor> page_base_background_color);
// Destroys the WebView.
virtual void Close() = 0;
@@ -283,7 +290,7 @@ class WebView {
// Override the screen orientation override.
virtual void SetScreenOrientationOverrideForTesting(
- absl::optional<blink::mojom::ScreenOrientation> orientation) = 0;
+ absl::optional<display::mojom::ScreenOrientation> orientation) = 0;
// Enable/Disable synchronous resize mode that is used for web tests.
virtual void UseSynchronousResizeModeForTesting(bool enable) = 0;
@@ -353,11 +360,6 @@ class WebView {
// Custom colors -------------------------------------------------------
- // Sets the default background color when the page has not loaded enough to
- // know a background colour. This can be overridden by the methods below as
- // well.
- virtual void SetBaseBackgroundColor(SkColor) {}
-
virtual void SetDeviceColorSpaceForTesting(
const gfx::ColorSpace& color_space) = 0;
@@ -462,7 +464,10 @@ class WebView {
virtual int32_t HistoryBackListCount() const = 0;
virtual int32_t HistoryForwardListCount() const = 0;
- // Portals --------------------------------------------------------------
+ // Misc -------------------------------------------------------------
+
+ // Returns the number of live WebView instances in this process.
+ BLINK_EXPORT static size_t GetWebViewCount();
protected:
~WebView() = default;
diff --git a/chromium/third_party/blink/public/web/web_view_client.h b/chromium/third_party/blink/public/web/web_view_client.h
index 75bdef8fa35..7b65e9d08cc 100644
--- a/chromium/third_party/blink/public/web/web_view_client.h
+++ b/chromium/third_party/blink/public/web/web_view_client.h
@@ -84,14 +84,6 @@ class WebViewClient {
// the layers.
virtual void InvalidateContainer() {}
- // Called when script in the page calls window.print(). If frame is
- // non-null, then it selects a particular frame, including its
- // children, to print. Otherwise, the main frame and its children
- // should be printed.
- virtual void PrintPage(WebLocalFrame*) {}
-
- virtual void OnPageFrozenChanged(bool frozen) {}
-
// UI ------------------------------------------------------------------
// Called when the View has changed size as a result of an auto-resize.
diff --git a/chromium/third_party/blink/public/web/web_widget.h b/chromium/third_party/blink/public/web/web_widget.h
index 190cc57ddbb..0eaa04ff2a2 100644
--- a/chromium/third_party/blink/public/web/web_widget.h
+++ b/chromium/third_party/blink/public/web/web_widget.h
@@ -60,14 +60,17 @@ class LayerTreeHost;
class LayerTreeSettings;
}
+namespace display {
+struct ScreenInfo;
+struct ScreenInfos;
+} // namespace display
+
namespace ui {
class Cursor;
class LatencyInfo;
}
namespace blink {
-struct ScreenInfo;
-struct ScreenInfos;
struct VisualProperties;
class WebCoalescedInputEvent;
@@ -84,7 +87,7 @@ class WebWidget {
// override the defaults.
virtual void InitializeCompositing(
scheduler::WebAgentGroupScheduler& agent_group_scheduler,
- const ScreenInfos& screen_info,
+ const display::ScreenInfos& screen_info,
const cc::LayerTreeSettings* settings) = 0;
// Set the compositor as visible. If |visible| is true, then the compositor
@@ -195,17 +198,17 @@ class WebWidget {
// Returns information about the screen where this view's widgets are being
// displayed.
- virtual const ScreenInfo& GetScreenInfo() = 0;
+ virtual const display::ScreenInfo& GetScreenInfo() = 0;
// Returns information about all available screens.
- virtual const ScreenInfos& GetScreenInfos() = 0;
+ virtual const display::ScreenInfos& GetScreenInfos() = 0;
// Returns original (non-emulated) information about the screen where this
// view's widgets are being displayed.
- virtual const ScreenInfo& GetOriginalScreenInfo() = 0;
+ virtual const display::ScreenInfo& GetOriginalScreenInfo() = 0;
// Returns original (non-emulated) information about all available screens.
- virtual const ScreenInfos& GetOriginalScreenInfos() = 0;
+ virtual const display::ScreenInfos& GetOriginalScreenInfos() = 0;
// Called to get the position of the widget's window in screen
// coordinates. Note, the window includes any decorations such as borders,