annotate modules/javafx.web/src/main/native/Source/WebCore/testing/Internals.h @ 11208:db2c977a840b

8220147: Cherry pick GTK WebKit 2.22.7 changes Reviewed-by: mbilla, kcr
author arajkumar
date Fri, 08 Mar 2019 14:03:47 +0530
parents ab4db0272524
children a1fb556cdd7d
rev   line source
peterz@3550 1 /*
peterz@3550 2 * Copyright (C) 2012 Google Inc. All rights reserved.
arajkumar@10587 3 * Copyright (C) 2013-2017 Apple Inc. All rights reserved.
peterz@3550 4 *
peterz@3550 5 * Redistribution and use in source and binary forms, with or without
peterz@3550 6 * modification, are permitted provided that the following conditions
peterz@3550 7 * are met:
peterz@3550 8 *
peterz@3550 9 * 1. Redistributions of source code must retain the above copyright
peterz@3550 10 * notice, this list of conditions and the following disclaimer.
peterz@3550 11 * 2. Redistributions in binary form must reproduce the above copyright
peterz@3550 12 * notice, this list of conditions and the following disclaimer in the
peterz@3550 13 * documentation and/or other materials provided with the distribution.
peterz@3550 14 *
peterz@3550 15 * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
peterz@3550 16 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
peterz@3550 17 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
peterz@3550 18 * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
peterz@3550 19 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
peterz@3550 20 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
peterz@3550 21 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
peterz@3550 22 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
peterz@3550 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
peterz@3550 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
peterz@3550 25 */
peterz@3550 26
arajkumar@10587 27 #pragma once
peterz@3550 28
alexey@4236 29 #include "CSSComputedStyleDeclaration.h"
peterz@3550 30 #include "ContextDestructionObserver.h"
arajkumar@10587 31 #include "ExceptionOr.h"
mbilla@10730 32 #include "JSDOMPromiseDeferred.h"
mbilla@10730 33 #include "OrientationNotifier.h"
kcr@9800 34 #include "PageConsoleClient.h"
mbilla@10730 35 #include "RealtimeMediaSource.h"
arajkumar@10954 36 #include <JavaScriptCore/Float32Array.h>
mbilla@10730 37 #include <wtf/Optional.h>
arajkumar@10587 38
arajkumar@10587 39 #if ENABLE(MEDIA_SESSION)
arajkumar@10587 40 #include "MediaSessionInterruptionProvider.h"
arajkumar@10587 41 #endif
peterz@3550 42
arajkumar@11139 43 #if ENABLE(VIDEO)
arajkumar@11139 44 #include "MediaElementSession.h"
arajkumar@11139 45 #endif
arajkumar@11139 46
peterz@3550 47 namespace WebCore {
peterz@3550 48
arajkumar@10954 49 class AnimationTimeline;
kcr@9800 50 class AudioContext;
arajkumar@10954 51 class CacheStorageConnection;
mbilla@10730 52 class DOMRect;
mbilla@10730 53 class DOMRectList;
kcr@10196 54 class DOMURL;
alexey@4236 55 class DOMWindow;
peterz@3550 56 class Document;
peterz@3550 57 class Element;
arajkumar@10954 58 class ExtendableEvent;
arajkumar@10954 59 class FetchResponse;
kcr@9800 60 class File;
peterz@3550 61 class Frame;
arajkumar@10587 62 class GCObservation;
arajkumar@11139 63 class HTMLAnchorElement;
arajkumar@10587 64 class HTMLImageElement;
arajkumar@10587 65 class HTMLInputElement;
arajkumar@10587 66 class HTMLLinkElement;
kcr@9800 67 class HTMLMediaElement;
arajkumar@11139 68 class HTMLPictureElement;
arajkumar@10587 69 class HTMLSelectElement;
mbilla@10730 70 class ImageData;
kcr@10196 71 class InspectorStubFrontend;
peterz@3550 72 class InternalSettings;
kcr@9800 73 class MallocStatistics;
kcr@9800 74 class MediaSession;
mbilla@10730 75 class MediaStream;
mbilla@10730 76 class MediaStreamTrack;
ant@8798 77 class MemoryInfo;
arajkumar@10587 78 class MockCDMFactory;
arajkumar@10587 79 class MockContentFilterSettings;
arajkumar@11139 80 class MockCredentialsMessenger;
kcr@10196 81 class MockPageOverlay;
arajkumar@10954 82 class MockPaymentCoordinator;
arajkumar@10587 83 class NodeList;
alexey@4236 84 class Page;
arajkumar@10954 85 class RTCPeerConnection;
peterz@3550 86 class Range;
kcr@9800 87 class RenderedDocumentMarker;
mbilla@10730 88 class SVGSVGElement;
alexey@4236 89 class SerializedScriptValue;
kcr@9800 90 class SourceBuffer;
arajkumar@10954 91 class StringCallback;
arajkumar@10587 92 class StyleSheet;
alexey@4236 93 class TimeRanges;
alexey@4236 94 class TypeConversions;
arajkumar@10954 95 class VoidCallback;
mbilla@10730 96 class WebGLRenderingContext;
kcr@9800 97 class XMLHttpRequest;
kcr@9800 98
arajkumar@10954 99 #if ENABLE(SERVICE_WORKER)
arajkumar@10954 100 class ServiceWorker;
arajkumar@10954 101 #endif
arajkumar@10954 102
arajkumar@10954 103 class Internals final : public RefCounted<Internals>, private ContextDestructionObserver
mbilla@10730 104 #if ENABLE(MEDIA_STREAM)
mbilla@10730 105 , private RealtimeMediaSource::Observer
mbilla@10730 106 #endif
mbilla@10730 107 {
peterz@3550 108 public:
arajkumar@10587 109 static Ref<Internals> create(Document&);
peterz@3550 110 virtual ~Internals();
peterz@3550 111
arajkumar@10587 112 static void resetToConsistentState(Page&);
alexey@4236 113
arajkumar@10587 114 ExceptionOr<String> elementRenderTreeAsText(Element&);
arajkumar@10587 115 bool hasPausedImageAnimations(Element&);
peterz@3550 116
arajkumar@10954 117 bool isPaintingFrequently(Element&);
arajkumar@10954 118 void incrementFrequentPaintCounter(Element&);
arajkumar@10954 119
arajkumar@10587 120 String address(Node&);
arajkumar@10587 121 bool nodeNeedsStyleRecalc(Node&);
arajkumar@10587 122 String styleChangeType(Node&);
arajkumar@10587 123 String description(JSC::JSValue);
peterz@3550 124
alexey@4236 125 bool isPreloaded(const String& url);
alexey@4236 126 bool isLoadingFromMemoryCache(const String& url);
arajkumar@10954 127 String fetchResponseSource(FetchResponse&);
arajkumar@10587 128 String xhrResponseSource(XMLHttpRequest&);
arajkumar@10587 129 bool isSharingStyleSheetContents(HTMLLinkElement&, HTMLLinkElement&);
arajkumar@10587 130 bool isStyleSheetLoadingSubresources(HTMLLinkElement&);
arajkumar@10587 131 enum class CachePolicy { UseProtocolCachePolicy, ReloadIgnoringCacheData, ReturnCacheDataElseLoad, ReturnCacheDataDontLoad };
arajkumar@10587 132 void setOverrideCachePolicy(CachePolicy);
arajkumar@10587 133 ExceptionOr<void> setCanShowModalDialogOverride(bool allow);
arajkumar@10587 134 enum class ResourceLoadPriority { ResourceLoadPriorityVeryLow, ResourceLoadPriorityLow, ResourceLoadPriorityMedium, ResourceLoadPriorityHigh, ResourceLoadPriorityVeryHigh };
arajkumar@10587 135 void setOverrideResourceLoadPriority(ResourceLoadPriority);
kcr@10196 136 void setStrictRawResourceValidationPolicyDisabled(bool);
kcr@9800 137
kcr@9800 138 void clearMemoryCache();
kcr@9800 139 void pruneMemoryCacheToSize(unsigned size);
mbilla@10730 140 void destroyDecodedDataForAllImages();
kcr@9800 141 unsigned memoryCacheSize() const;
kcr@9800 142
arajkumar@10587 143 unsigned imageFrameIndex(HTMLImageElement&);
arajkumar@10587 144 void setImageFrameDecodingDuration(HTMLImageElement&, float duration);
arajkumar@10587 145 void resetImageAnimation(HTMLImageElement&);
mbilla@10730 146 bool isImageAnimating(HTMLImageElement&);
mbilla@10730 147 void setClearDecoderAfterAsyncFrameRequestForTesting(HTMLImageElement&, bool enabled);
mbilla@10730 148 unsigned imageDecodeCount(HTMLImageElement&);
arajkumar@10954 149 unsigned pdfDocumentCachingCount(HTMLImageElement&);
mbilla@10730 150 void setLargeImageAsyncDecodingEnabledForTesting(HTMLImageElement&, bool enabled);
arajkumar@10954 151 void setForceUpdateImageDataEnabledForTesting(HTMLImageElement&, bool enabled);
mbilla@10730 152
mbilla@10730 153 void setGridMaxTracksLimit(unsigned);
kcr@10196 154
kcr@9800 155 void clearPageCache();
kcr@9800 156 unsigned pageCacheSize() const;
peterz@3550 157
arajkumar@10587 158 void disableTileSizeUpdateDelay();
peterz@3550 159
mbilla@10730 160 void setSpeculativeTilingDelayDisabledForTesting(bool);
mbilla@10730 161
arajkumar@10587 162 Ref<CSSComputedStyleDeclaration> computedStyleIncludingVisitedInfo(Element&) const;
arajkumar@10587 163
arajkumar@10587 164 Node* ensureUserAgentShadowRoot(Element& host);
arajkumar@10587 165 Node* shadowRoot(Element& host);
arajkumar@10587 166 ExceptionOr<String> shadowRootType(const Node&) const;
arajkumar@10587 167 String shadowPseudoId(Element&);
arajkumar@10587 168 void setShadowPseudoId(Element&, const String&);
arajkumar@10587 169
arajkumar@10587 170 // CSS Deferred Parsing Testing
arajkumar@10587 171 unsigned deferredStyleRulesCount(StyleSheet&);
arajkumar@10587 172 unsigned deferredGroupRulesCount(StyleSheet&);
arajkumar@10587 173 unsigned deferredKeyframesRulesCount(StyleSheet&);
peterz@3550 174
kcr@9800 175 // DOMTimers throttling testing.
arajkumar@10587 176 ExceptionOr<bool> isTimerThrottled(int timeoutId);
kcr@9800 177 bool isRequestAnimationFrameThrottled() const;
mbilla@10730 178 double requestAnimationFrameInterval() const;
mbilla@10730 179 bool scriptedAnimationsAreSuspended() const;
kcr@9800 180 bool areTimersThrottled() const;
kcr@9800 181
arajkumar@10587 182 enum EventThrottlingBehavior { Responsive, Unresponsive };
arajkumar@10587 183 void setEventThrottlingBehaviorOverride(std::optional<EventThrottlingBehavior>);
arajkumar@10587 184 std::optional<EventThrottlingBehavior> eventThrottlingBehaviorOverride() const;
arajkumar@10587 185
ant@8798 186 // Spatial Navigation testing.
arajkumar@10587 187 ExceptionOr<unsigned> lastSpatialNavigationCandidateCount() const;
ant@8798 188
alexey@4236 189 // CSS Animation testing.
alexey@4236 190 unsigned numberOfActiveAnimations() const;
arajkumar@10587 191 ExceptionOr<bool> animationsAreSuspended() const;
arajkumar@10587 192 ExceptionOr<void> suspendAnimations() const;
arajkumar@10587 193 ExceptionOr<void> resumeAnimations() const;
arajkumar@10587 194 ExceptionOr<bool> pauseAnimationAtTimeOnElement(const String& animationName, double pauseTime, Element&);
arajkumar@10587 195 ExceptionOr<bool> pauseAnimationAtTimeOnPseudoElement(const String& animationName, double pauseTime, Element&, const String& pseudoId);
mbilla@10730 196 double animationsInterval() const;
alexey@4236 197
alexey@4236 198 // CSS Transition testing.
arajkumar@10587 199 ExceptionOr<bool> pauseTransitionAtTimeOnElement(const String& propertyName, double pauseTime, Element&);
arajkumar@10587 200 ExceptionOr<bool> pauseTransitionAtTimeOnPseudoElement(const String& property, double pauseTime, Element&, const String& pseudoId);
alexey@4236 201
arajkumar@11139 202 // For animations testing, we need a way to get at pseudo elements.
arajkumar@11139 203 ExceptionOr<RefPtr<Element>> pseudoElement(Element&, const String&);
arajkumar@11139 204
arajkumar@10587 205 Node* treeScopeRootNode(Node&);
arajkumar@10587 206 Node* parentTreeScope(Node&);
peterz@3550 207
arajkumar@10587 208 String visiblePlaceholder(Element&);
arajkumar@10587 209 void selectColorInColorChooser(HTMLInputElement&, const String& colorValue);
arajkumar@10587 210 ExceptionOr<Vector<String>> formControlStateOfPreviousHistoryItem();
arajkumar@10587 211 ExceptionOr<void> setFormControlStateOfPreviousHistoryItem(const Vector<String>&);
peterz@3550 212
mbilla@10730 213 ExceptionOr<Ref<DOMRect>> absoluteCaretBounds();
peterz@3550 214
mbilla@10730 215 Ref<DOMRect> boundingBox(Element&);
peterz@3550 216
mbilla@10730 217 ExceptionOr<Ref<DOMRectList>> inspectorHighlightRects();
arajkumar@10587 218 ExceptionOr<String> inspectorHighlightObject();
peterz@3550 219
arajkumar@10587 220 ExceptionOr<unsigned> markerCountForNode(Node&, const String&);
arajkumar@10587 221 ExceptionOr<RefPtr<Range>> markerRangeForNode(Node&, const String& markerType, unsigned index);
arajkumar@10587 222 ExceptionOr<String> markerDescriptionForNode(Node&, const String& markerType, unsigned index);
arajkumar@10587 223 ExceptionOr<String> dumpMarkerRects(const String& markerType);
arajkumar@10587 224 void addTextMatchMarker(const Range&, bool isActive);
arajkumar@10587 225 ExceptionOr<void> setMarkedTextMatchesAreHighlighted(bool);
kcr@9800 226
kcr@9800 227 void invalidateFontCache();
mbilla@10730 228 void setFontSmoothingEnabled(bool);
mbilla@10730 229
mbilla@10730 230 ExceptionOr<void> setLowPowerModeEnabled(bool);
peterz@3550 231
arajkumar@10587 232 ExceptionOr<void> setScrollViewPosition(int x, int y);
arajkumar@10954 233 ExceptionOr<void> unconstrainedScrollTo(Element&, double x, double y);
kcr@9800 234
mbilla@10730 235 ExceptionOr<Ref<DOMRect>> layoutViewportRect();
mbilla@10730 236 ExceptionOr<Ref<DOMRect>> visualViewportRect();
peterz@3550 237
arajkumar@10587 238 ExceptionOr<void> setViewBaseBackgroundColor(const String& colorValue);
peterz@3550 239
arajkumar@10587 240 ExceptionOr<void> setPagination(const String& mode, int gap, int pageLength);
arajkumar@10587 241 ExceptionOr<void> setPaginationLineGridEnabled(bool);
arajkumar@10587 242 ExceptionOr<String> configurationForViewport(float devicePixelRatio, int deviceWidth, int deviceHeight, int availableWidth, int availableHeight);
peterz@3550 243
arajkumar@10587 244 ExceptionOr<bool> wasLastChangeUserEdit(Element& textField);
arajkumar@10587 245 bool elementShouldAutoComplete(HTMLInputElement&);
arajkumar@10587 246 void setEditingValue(HTMLInputElement&, const String&);
arajkumar@10587 247 void setAutofilled(HTMLInputElement&, bool enabled);
arajkumar@11139 248 enum class AutoFillButtonType { None, Contacts, Credentials, StrongPassword };
arajkumar@10587 249 void setShowAutoFillButton(HTMLInputElement&, AutoFillButtonType);
arajkumar@10954 250 AutoFillButtonType autoFillButtonType(const HTMLInputElement&);
arajkumar@10954 251 AutoFillButtonType lastAutoFillButtonType(const HTMLInputElement&);
arajkumar@10587 252 ExceptionOr<void> scrollElementToRect(Element&, int x, int y, int w, int h);
peterz@3550 253
arajkumar@10587 254 ExceptionOr<String> autofillFieldName(Element&);
peterz@3550 255
arajkumar@11139 256 ExceptionOr<void> invalidateControlTints();
arajkumar@10587 257
arajkumar@10587 258 RefPtr<Range> rangeFromLocationAndLength(Element& scope, int rangeLocation, int rangeLength);
arajkumar@10587 259 unsigned locationFromRange(Element& scope, const Range&);
arajkumar@10587 260 unsigned lengthFromRange(Element& scope, const Range&);
arajkumar@10587 261 String rangeAsText(const Range&);
arajkumar@10587 262 Ref<Range> subrange(Range&, int rangeLocation, int rangeLength);
arajkumar@10587 263 ExceptionOr<RefPtr<Range>> rangeForDictionaryLookupAtLocation(int x, int y);
arajkumar@10587 264 RefPtr<Range> rangeOfStringNearLocation(const Range&, const String&, unsigned);
arajkumar@10587 265
arajkumar@10587 266 ExceptionOr<void> setDelegatesScrolling(bool enabled);
arajkumar@10587 267
arajkumar@10587 268 ExceptionOr<int> lastSpellCheckRequestSequence();
arajkumar@10587 269 ExceptionOr<int> lastSpellCheckProcessedSequence();
ant@8798 270
peterz@3550 271 Vector<String> userPreferredLanguages() const;
peterz@3550 272 void setUserPreferredLanguages(const Vector<String>&);
peterz@3550 273
kcr@9800 274 Vector<String> userPreferredAudioCharacteristics() const;
kcr@9800 275 void setUserPreferredAudioCharacteristic(const String&);
kcr@9800 276
arajkumar@10587 277 ExceptionOr<unsigned> wheelEventHandlerCount();
arajkumar@10587 278 ExceptionOr<unsigned> touchEventHandlerCount();
peterz@3550 279
mbilla@10730 280 ExceptionOr<Ref<DOMRectList>> touchEventRectsForEvent(const String&);
mbilla@10730 281 ExceptionOr<Ref<DOMRectList>> passiveTouchEventListenerRects();
mbilla@10730 282
mbilla@10730 283 ExceptionOr<RefPtr<NodeList>> nodesFromRect(Document&, int x, int y, unsigned topPadding, unsigned rightPadding, unsigned bottomPadding, unsigned leftPadding, bool ignoreClipping, bool allowUserAgentShadowContent, bool allowChildFrameContent) const;
peterz@3550 284
arajkumar@10587 285 String parserMetaData(JSC::JSValue = JSC::JSValue::JSUndefined);
peterz@3550 286
kcr@9800 287 void updateEditorUINowIfScheduled();
ant@8798 288
arajkumar@11139 289 bool sentenceRetroCorrectionEnabled() const
arajkumar@11139 290 {
arajkumar@11139 291 #if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400
arajkumar@11139 292 return true;
arajkumar@11139 293 #else
arajkumar@11139 294 return false;
arajkumar@11139 295 #endif
arajkumar@11139 296 }
arajkumar@10587 297 bool hasSpellingMarker(int from, int length);
arajkumar@10587 298 bool hasGrammarMarker(int from, int length);
arajkumar@10587 299 bool hasAutocorrectedMarker(int from, int length);
arajkumar@10587 300 void setContinuousSpellCheckingEnabled(bool);
arajkumar@10587 301 void setAutomaticQuoteSubstitutionEnabled(bool);
arajkumar@10587 302 void setAutomaticLinkDetectionEnabled(bool);
arajkumar@10587 303 void setAutomaticDashSubstitutionEnabled(bool);
arajkumar@10587 304 void setAutomaticTextReplacementEnabled(bool);
arajkumar@10587 305 void setAutomaticSpellingCorrectionEnabled(bool);
alexey@4236 306
arajkumar@10587 307 void handleAcceptedCandidate(const String& candidate, unsigned location, unsigned length);
kcr@10196 308
arajkumar@10587 309 bool isOverwriteModeEnabled();
arajkumar@10587 310 void toggleOverwriteModeEnabled();
peterz@3550 311
arajkumar@10587 312 ExceptionOr<RefPtr<Range>> rangeOfString(const String&, RefPtr<Range>&&, const Vector<String>& findOptions);
arajkumar@10587 313 ExceptionOr<unsigned> countMatchesForText(const String&, const Vector<String>& findOptions, const String& markMatches);
arajkumar@10587 314 ExceptionOr<unsigned> countFindMatches(const String&, const Vector<String>& findOptions);
kcr@9800 315
arajkumar@10587 316 unsigned numberOfScrollableAreas();
peterz@3550 317
arajkumar@10587 318 ExceptionOr<bool> isPageBoxVisible(int pageNumber);
peterz@3550 319
peterz@3550 320 static const char* internalsId;
peterz@3550 321
peterz@3550 322 InternalSettings* settings() const;
alexey@4236 323 unsigned workerThreadCount() const;
mbilla@10730 324 ExceptionOr<bool> areSVGAnimationsPaused() const;
mbilla@10730 325 ExceptionOr<double> svgAnimationsInterval(SVGSVGElement&) const;
alexey@4236 326
alexey@4236 327 enum {
alexey@4236 328 // Values need to be kept in sync with Internals.idl.
alexey@4236 329 LAYER_TREE_INCLUDES_VISIBLE_RECTS = 1,
alexey@4236 330 LAYER_TREE_INCLUDES_TILE_CACHES = 2,
alexey@4236 331 LAYER_TREE_INCLUDES_REPAINT_RECTS = 4,
ant@8798 332 LAYER_TREE_INCLUDES_PAINTING_PHASES = 8,
arajkumar@10587 333 LAYER_TREE_INCLUDES_CONTENT_LAYERS = 16,
arajkumar@10587 334 LAYER_TREE_INCLUDES_ACCELERATES_DRAWING = 32,
mbilla@10730 335 LAYER_TREE_INCLUDES_BACKING_STORE_ATTACHED = 64,
alexey@4236 336 };
arajkumar@10587 337 ExceptionOr<String> layerTreeAsText(Document&, unsigned short flags) const;
mbilla@10730 338 ExceptionOr<uint64_t> layerIDForElement(Element&);
arajkumar@10587 339 ExceptionOr<String> repaintRectsAsText() const;
arajkumar@10587 340 ExceptionOr<String> scrollingStateTreeAsText() const;
arajkumar@10587 341 ExceptionOr<String> mainThreadScrollingReasons() const;
mbilla@10730 342 ExceptionOr<Ref<DOMRectList>> nonFastScrollableRects() const;
alexey@4236 343
arajkumar@10587 344 ExceptionOr<void> setElementUsesDisplayListDrawing(Element&, bool usesDisplayListDrawing);
arajkumar@10587 345 ExceptionOr<void> setElementTracksDisplayListReplay(Element&, bool isTrackingReplay);
kcr@10196 346
kcr@10196 347 enum {
kcr@10196 348 // Values need to be kept in sync with Internals.idl.
kcr@10196 349 DISPLAY_LIST_INCLUDES_PLATFORM_OPERATIONS = 1,
kcr@10196 350 };
arajkumar@10587 351 ExceptionOr<String> displayListForElement(Element&, unsigned short flags);
arajkumar@10587 352 ExceptionOr<String> replayDisplayListForElement(Element&, unsigned short flags);
kcr@10196 353
arajkumar@10587 354 ExceptionOr<void> garbageCollectDocumentResources() const;
kcr@10196 355
arajkumar@10587 356 void beginSimulatedMemoryPressure();
arajkumar@10587 357 void endSimulatedMemoryPressure();
arajkumar@10587 358 bool isUnderMemoryPressure();
peterz@3550 359
arajkumar@10587 360 ExceptionOr<void> insertAuthorCSS(const String&) const;
arajkumar@10587 361 ExceptionOr<void> insertUserCSS(const String&) const;
kcr@9800 362
peterz@3550 363 unsigned numberOfLiveNodes() const;
peterz@3550 364 unsigned numberOfLiveDocuments() const;
mbilla@10730 365 unsigned referencingNodeCount(const Document&) const;
kcr@9800 366
arajkumar@11139 367 #if ENABLE(INTERSECTION_OBSERVER)
arajkumar@11139 368 unsigned numberOfIntersectionObservers(const Document&) const;
arajkumar@11139 369 #endif
arajkumar@11139 370
arajkumar@11139 371 uint64_t documentIdentifier(const Document&) const;
arajkumar@11139 372 bool isDocumentAlive(uint64_t documentIdentifier) const;
arajkumar@11139 373
arajkumar@11139 374 RefPtr<WindowProxy> openDummyInspectorFrontend(const String& url);
alexey@4236 375 void closeDummyInspectorFrontend();
arajkumar@10587 376 ExceptionOr<void> setInspectorIsUnderTest(bool);
peterz@3550 377
arajkumar@10587 378 String counterValue(Element&);
alexey@4236 379
arajkumar@10587 380 int pageNumber(Element&, float pageWidth = 800, float pageHeight = 600);
ant@8798 381 Vector<String> shortcutIconURLs() const;
alexey@4236 382
alexey@4236 383 int numberOfPages(float pageWidthInPixels = 800, float pageHeightInPixels = 600);
arajkumar@10587 384 ExceptionOr<String> pageProperty(const String& propertyName, int pageNumber) const;
arajkumar@10587 385 ExceptionOr<String> pageSizeAndMarginsInPixels(int pageNumber, int width, int height, int marginTop, int marginRight, int marginBottom, int marginLeft) const;
alexey@4236 386
arajkumar@10587 387 ExceptionOr<float> pageScaleFactor() const;
kcr@9800 388
arajkumar@10587 389 ExceptionOr<void> setPageScaleFactor(float scaleFactor, int x, int y);
arajkumar@10587 390 ExceptionOr<void> setPageZoomFactor(float);
arajkumar@10587 391 ExceptionOr<void> setTextZoomFactor(float);
arajkumar@10587 392
arajkumar@10587 393 ExceptionOr<void> setUseFixedLayout(bool);
arajkumar@10587 394 ExceptionOr<void> setFixedLayoutSize(int width, int height);
arajkumar@10587 395 ExceptionOr<void> setViewExposedRect(float left, float top, float width, float height);
mbilla@10730 396 void setPrinting(int width, int height);
alexey@4236 397
ant@8798 398 void setHeaderHeight(float);
ant@8798 399 void setFooterHeight(float);
peterz@3550 400
kcr@9800 401 void setTopContentInset(float);
kcr@9800 402
peterz@3550 403 #if ENABLE(FULLSCREEN_API)
arajkumar@10587 404 void webkitWillEnterFullScreenForElement(Element&);
arajkumar@10587 405 void webkitDidEnterFullScreenForElement(Element&);
arajkumar@10587 406 void webkitWillExitFullScreenForElement(Element&);
arajkumar@10587 407 void webkitDidExitFullScreenForElement(Element&);
arajkumar@11139 408 bool isAnimatingFullScreen() const;
peterz@3550 409 #endif
peterz@3550 410
arajkumar@11139 411 struct FullscreenInsets {
arajkumar@11139 412 float top { 0 };
arajkumar@11139 413 float left { 0 };
arajkumar@11139 414 float bottom { 0 };
arajkumar@11139 415 float right { 0 };
arajkumar@11139 416 };
arajkumar@11139 417 void setFullscreenInsets(FullscreenInsets);
arajkumar@11139 418 void setFullscreenAutoHideDuration(double);
arajkumar@11139 419 void setFullscreenControlsHidden(bool);
arajkumar@11139 420
kcr@9800 421 WEBCORE_TESTSUPPORT_EXPORT void setApplicationCacheOriginQuota(unsigned long long);
ant@8798 422
peterz@3550 423 void registerURLSchemeAsBypassingContentSecurityPolicy(const String& scheme);
peterz@3550 424 void removeURLSchemeRegisteredAsBypassingContentSecurityPolicy(const String& scheme);
peterz@3550 425
arajkumar@10587 426 void registerDefaultPortForProtocol(unsigned short port, const String& protocol);
arajkumar@10587 427
kcr@10196 428 Ref<MallocStatistics> mallocStatistics() const;
kcr@10196 429 Ref<TypeConversions> typeConversions() const;
kcr@10196 430 Ref<MemoryInfo> memoryInfo() const;
alexey@4236 431
alexey@4236 432 Vector<String> getReferencedFilePaths() const;
alexey@4236 433
arajkumar@10587 434 ExceptionOr<void> startTrackingRepaints();
arajkumar@10587 435 ExceptionOr<void> stopTrackingRepaints();
alexey@4236 436
arajkumar@10587 437 ExceptionOr<void> startTrackingLayerFlushes();
arajkumar@10587 438 ExceptionOr<unsigned> layerFlushCount();
kcr@9800 439
arajkumar@10587 440 ExceptionOr<void> startTrackingStyleRecalcs();
arajkumar@10587 441 ExceptionOr<unsigned> styleRecalcCount();
arajkumar@10587 442 unsigned lastStyleUpdateSize() const;
kcr@9800 443
arajkumar@10587 444 ExceptionOr<void> startTrackingCompositingUpdates();
arajkumar@10587 445 ExceptionOr<unsigned> compositingUpdateCount();
kcr@9800 446
arajkumar@11139 447 enum CompositingPolicy { Normal, Conservative };
arajkumar@11139 448 ExceptionOr<void> setCompositingPolicyOverride(std::optional<CompositingPolicy>);
arajkumar@11139 449 ExceptionOr<std::optional<CompositingPolicy>> compositingPolicyOverride() const;
arajkumar@11139 450
arajkumar@10587 451 ExceptionOr<void> updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(Node*);
kcr@9800 452 unsigned layoutCount() const;
kcr@9800 453
arajkumar@10587 454 Ref<ArrayBuffer> serializeObject(const RefPtr<SerializedScriptValue>&) const;
arajkumar@10587 455 Ref<SerializedScriptValue> deserializeBuffer(ArrayBuffer&) const;
alexey@4236 456
arajkumar@10587 457 bool isFromCurrentWorld(JSC::JSValue) const;
kcr@9800 458
arajkumar@10587 459 void setUsesOverlayScrollbars(bool);
arajkumar@10587 460 void setUsesMockScrollAnimator(bool);
alexey@4236 461
arajkumar@10587 462 ExceptionOr<String> getCurrentCursorInfo();
alexey@4236 463
arajkumar@10587 464 String markerTextForListItem(Element&);
alexey@4236 465
arajkumar@10587 466 String toolTipFromElement(Element&) const;
kcr@9800 467
alexey@4236 468 void forceReload(bool endToEnd);
mbilla@10730 469 void reloadExpiredOnly();
alexey@4236 470
kcr@10196 471 void enableAutoSizeMode(bool enabled, int minimumWidth, int minimumHeight, int maximumWidth, int maximumHeight);
kcr@10196 472
arajkumar@10587 473 #if ENABLE(LEGACY_ENCRYPTED_MEDIA)
alexey@4236 474 void initializeMockCDM();
alexey@4236 475 #endif
alexey@4236 476
arajkumar@10587 477 #if ENABLE(ENCRYPTED_MEDIA)
arajkumar@10587 478 Ref<MockCDMFactory> registerMockCDM();
arajkumar@10587 479 #endif
arajkumar@10587 480
arajkumar@11139 481 void enableMockMediaCapabilities();
arajkumar@11139 482
alexey@4236 483 #if ENABLE(SPEECH_SYNTHESIS)
alexey@4236 484 void enableMockSpeechSynthesizer();
alexey@4236 485 #endif
alexey@4236 486
ant@8798 487 #if ENABLE(MEDIA_STREAM)
kcr@10196 488 void setMockMediaCaptureDevicesEnabled(bool);
ant@8798 489 #endif
ant@8798 490
arajkumar@10587 491 #if ENABLE(WEB_RTC)
arajkumar@10587 492 void emulateRTCPeerConnectionPlatformEvent(RTCPeerConnection&, const String& action);
arajkumar@10587 493 void useMockRTCPeerConnectionFactory(const String&);
mbilla@10730 494 void setICECandidateFiltering(bool);
mbilla@10730 495 void setEnumeratingAllNetworkInterfacesEnabled(bool);
mbilla@10730 496 void stopPeerConnection(RTCPeerConnection&);
mbilla@10730 497 void applyRotationForOutgoingVideoSources(RTCPeerConnection&);
arajkumar@10587 498 #endif
arajkumar@10587 499
arajkumar@10587 500 String getImageSourceURL(Element&);
alexey@4236 501
alexey@4236 502 #if ENABLE(VIDEO)
mbilla@10730 503 Vector<String> mediaResponseSources(HTMLMediaElement&);
mbilla@10730 504 Vector<String> mediaResponseContentRanges(HTMLMediaElement&);
arajkumar@10587 505 void simulateAudioInterruption(HTMLMediaElement&);
arajkumar@10587 506 ExceptionOr<bool> mediaElementHasCharacteristic(HTMLMediaElement&, const String&);
arajkumar@11139 507 void beginSimulatedHDCPError(HTMLMediaElement&);
arajkumar@11139 508 void endSimulatedHDCPError(HTMLMediaElement&);
arajkumar@11139 509
arajkumar@11139 510 bool elementShouldBufferData(HTMLMediaElement&);
alexey@4236 511 #endif
alexey@4236 512
arajkumar@10587 513 bool isSelectPopupVisible(HTMLSelectElement&);
alexey@4236 514
arajkumar@10587 515 ExceptionOr<String> captionsStyleSheetOverride();
arajkumar@10587 516 ExceptionOr<void> setCaptionsStyleSheetOverride(const String&);
arajkumar@10587 517 ExceptionOr<void> setPrimaryAudioTrackLanguageOverride(const String&);
arajkumar@10587 518 ExceptionOr<void> setCaptionDisplayMode(const String&);
alexey@4236 519
alexey@4236 520 #if ENABLE(VIDEO)
arajkumar@10587 521 Ref<TimeRanges> createTimeRanges(Float32Array& startTimes, Float32Array& endTimes);
arajkumar@10587 522 double closestTimeToTimeRanges(double time, TimeRanges&);
alexey@4236 523 #endif
alexey@4236 524
mbilla@10730 525 ExceptionOr<Ref<DOMRect>> selectionBounds();
ant@8798 526
arajkumar@10587 527 ExceptionOr<bool> isPluginUnavailabilityIndicatorObscured(Element&);
arajkumar@11139 528 ExceptionOr<String> unavailablePluginReplacementText(Element&);
arajkumar@10587 529 bool isPluginSnapshotted(Element&);
ant@8798 530
ant@8798 531 #if ENABLE(MEDIA_SOURCE)
kcr@9800 532 WEBCORE_TESTSUPPORT_EXPORT void initializeMockMediaSource();
arajkumar@10587 533 Vector<String> bufferedSamplesForTrackID(SourceBuffer&, const AtomicString&);
arajkumar@10587 534 Vector<String> enqueuedSamplesForTrackID(SourceBuffer&, const AtomicString&);
arajkumar@10587 535 void setShouldGenerateTimestamps(SourceBuffer&, bool);
ant@8798 536 #endif
ant@8798 537
kcr@9800 538 #if ENABLE(VIDEO)
arajkumar@10587 539 ExceptionOr<void> beginMediaSessionInterruption(const String&);
ant@8798 540 void endMediaSessionInterruption(const String&);
mbilla@10730 541 void applicationWillBecomeInactive();
mbilla@10730 542 void applicationDidBecomeActive();
mbilla@10730 543 void applicationWillEnterForeground(bool suspendedUnderLock) const;
mbilla@10730 544 void applicationDidEnterBackground(bool suspendedUnderLock) const;
mbilla@10730 545 ExceptionOr<void> setMediaSessionRestrictions(const String& mediaType, StringView restrictionsString);
arajkumar@10587 546 ExceptionOr<String> mediaSessionRestrictions(const String& mediaType) const;
mbilla@10730 547 void setMediaElementRestrictions(HTMLMediaElement&, StringView restrictionsString);
arajkumar@10587 548 ExceptionOr<void> postRemoteControlCommand(const String&, float argument);
arajkumar@10587 549 bool elementIsBlockingDisplaySleep(HTMLMediaElement&) const;
kcr@9800 550 #endif
kcr@9800 551
kcr@9800 552 #if ENABLE(MEDIA_SESSION)
arajkumar@10587 553 void sendMediaSessionStartOfInterruptionNotification(MediaSessionInterruptingCategory);
arajkumar@10587 554 void sendMediaSessionEndOfInterruptionNotification(MediaSessionInterruptingCategory);
arajkumar@10587 555 String mediaSessionCurrentState(MediaSession&) const;
arajkumar@10587 556 double mediaElementPlayerVolume(HTMLMediaElement&) const;
arajkumar@10587 557 enum class MediaControlEvent { PlayPause, NextTrack, PreviousTrack };
arajkumar@10587 558 void sendMediaControlEvent(MediaControlEvent);
kcr@10196 559 #endif
kcr@10196 560
kcr@10196 561 #if ENABLE(WIRELESS_PLAYBACK_TARGET)
kcr@10196 562 void setMockMediaPlaybackTargetPickerEnabled(bool);
arajkumar@10587 563 ExceptionOr<void> setMockMediaPlaybackTargetPickerState(const String& deviceName, const String& deviceState);
kcr@9800 564 #endif
kcr@9800 565
kcr@9800 566 #if ENABLE(WEB_AUDIO)
mbilla@10730 567 void setAudioContextRestrictions(AudioContext&, StringView restrictionsString);
kcr@9800 568 #endif
kcr@9800 569
kcr@9800 570 void simulateSystemSleep() const;
kcr@9800 571 void simulateSystemWake() const;
kcr@9800 572
arajkumar@10587 573 enum class PageOverlayType { View, Document };
arajkumar@10587 574 ExceptionOr<Ref<MockPageOverlay>> installMockPageOverlay(PageOverlayType);
arajkumar@10587 575 ExceptionOr<String> pageOverlayLayerTreeAsText(unsigned short flags) const;
kcr@9800 576
mbilla@10730 577 void setPageMuted(StringView);
arajkumar@10587 578 String pageMediaState();
kcr@9800 579
kcr@10196 580 void setPageDefersLoading(bool);
arajkumar@10954 581 ExceptionOr<bool> pageDefersLoading();
kcr@10196 582
kcr@9800 583 RefPtr<File> createFile(const String&);
kcr@9800 584 void queueMicroTask(int);
kcr@9800 585 bool testPreloaderSettingViewport();
kcr@9800 586
kcr@9800 587 #if ENABLE(CONTENT_FILTERING)
kcr@9800 588 MockContentFilterSettings& mockContentFilterSettings();
kcr@9800 589 #endif
kcr@9800 590
kcr@9800 591 #if ENABLE(CSS_SCROLL_SNAP)
arajkumar@10587 592 ExceptionOr<String> scrollSnapOffsets(Element&);
arajkumar@10587 593 void setPlatformMomentumScrollingPredictionEnabled(bool);
kcr@9800 594 #endif
kcr@9800 595
arajkumar@10587 596 ExceptionOr<String> pathStringWithShrinkWrappedRects(const Vector<double>& rectComponents, double radius);
ant@8798 597
arajkumar@10587 598 String getCurrentMediaControlsStatusForElement(HTMLMediaElement&);
kcr@10196 599
arajkumar@10587 600 String userVisibleString(const DOMURL&);
kcr@10196 601 void setShowAllPlugins(bool);
kcr@10196 602
arajkumar@10587 603 String resourceLoadStatisticsForOrigin(const String& origin);
kcr@10196 604 void setResourceLoadStatisticsEnabled(bool);
arajkumar@10954 605 void setUserGrantsStorageAccess(bool);
kcr@10196 606
mbilla@10730 607 #if ENABLE(STREAMS_API)
arajkumar@10587 608 bool isReadableStreamDisturbed(JSC::ExecState&, JSC::JSValue);
mbilla@10730 609 JSC::JSValue cloneArrayBuffer(JSC::ExecState&, JSC::JSValue, JSC::JSValue, JSC::JSValue);
kcr@10196 610 #endif
kcr@10196 611
arajkumar@10587 612 String composedTreeAsText(Node&);
arajkumar@10587 613
arajkumar@10587 614 bool isProcessingUserGesture();
mbilla@10730 615 double lastHandledUserGestureTimestamp();
arajkumar@10587 616
arajkumar@10954 617 void withUserGesture(RefPtr<VoidCallback>&&);
arajkumar@10954 618
arajkumar@10587 619 RefPtr<GCObservation> observeGC(JSC::JSValue);
arajkumar@10587 620
arajkumar@11139 621 enum class UserInterfaceLayoutDirection : uint8_t { LTR, RTL };
arajkumar@10587 622 void setUserInterfaceLayoutDirection(UserInterfaceLayoutDirection);
arajkumar@10587 623
arajkumar@10587 624 bool userPrefersReducedMotion() const;
arajkumar@10587 625
arajkumar@10587 626 void reportBacktrace();
arajkumar@10587 627
arajkumar@10587 628 enum class BaseWritingDirection { Natural, Ltr, Rtl };
arajkumar@10587 629 void setBaseWritingDirection(BaseWritingDirection);
arajkumar@10587 630
arajkumar@10587 631 #if ENABLE(POINTER_LOCK)
arajkumar@10587 632 bool pageHasPendingPointerLock() const;
arajkumar@10587 633 bool pageHasPointerLock() const;
arajkumar@10587 634 #endif
arajkumar@10587 635
arajkumar@10587 636 Vector<String> accessKeyModifiers() const;
arajkumar@10587 637
arajkumar@10587 638 void setQuickLookPassword(const String&);
mbilla@10730 639
mbilla@10730 640 void setAsRunningUserScripts(Document&);
mbilla@10730 641
mbilla@10730 642 #if ENABLE(WEBGL)
mbilla@10730 643 void simulateWebGLContextChanged(WebGLRenderingContext&);
mbilla@10730 644 void failNextGPUStatusCheck(WebGLRenderingContext&);
arajkumar@10587 645 #endif
arajkumar@10587 646
mbilla@10730 647 void setPageVisibility(bool isVisible);
mbilla@10730 648
mbilla@10730 649 #if ENABLE(WEB_RTC)
mbilla@10730 650 void setH264HardwareEncoderAllowed(bool allowed);
mbilla@10730 651 #endif
mbilla@10730 652
mbilla@10730 653 #if ENABLE(MEDIA_STREAM)
mbilla@10730 654 void setCameraMediaStreamTrackOrientation(MediaStreamTrack&, int orientation);
mbilla@10730 655 ExceptionOr<void> setMediaDeviceState(const String& id, const String& property, bool value);
mbilla@10730 656 unsigned long trackAudioSampleCount() const { return m_trackAudioSampleCount; }
mbilla@10730 657 unsigned long trackVideoSampleCount() const { return m_trackVideoSampleCount; }
mbilla@10730 658 void observeMediaStreamTrack(MediaStreamTrack&);
mbilla@10730 659 using TrackFramePromise = DOMPromiseDeferred<IDLInterface<ImageData>>;
mbilla@10730 660 void grabNextMediaStreamTrackFrame(TrackFramePromise&&);
mbilla@10730 661 void delayMediaStreamTrackSamples(MediaStreamTrack&, float);
mbilla@10730 662 void setMediaStreamTrackMuted(MediaStreamTrack&, bool);
mbilla@10730 663 void removeMediaStreamTrack(MediaStream&, MediaStreamTrack&);
mbilla@10730 664 void simulateMediaStreamTrackCaptureSourceFailure(MediaStreamTrack&);
arajkumar@11139 665 void setMediaStreamTrackIdentifier(MediaStreamTrack&, String&& id);
mbilla@10730 666 #endif
mbilla@10730 667
mbilla@10730 668 String audioSessionCategory() const;
arajkumar@11139 669 double preferredAudioBufferSize() const;
kcr@10196 670
arajkumar@10954 671 void clearCacheStorageMemoryRepresentation(DOMPromiseDeferred<void>&&);
arajkumar@10954 672 void cacheStorageEngineRepresentation(DOMPromiseDeferred<IDLDOMString>&&);
arajkumar@10954 673 void setResponseSizeWithPadding(FetchResponse&, uint64_t size);
arajkumar@10954 674 uint64_t responseSizeWithPadding(FetchResponse&) const;
arajkumar@10954 675
arajkumar@10954 676 void setConsoleMessageListener(RefPtr<StringCallback>&&);
arajkumar@10954 677
arajkumar@10954 678 #if ENABLE(SERVICE_WORKER)
arajkumar@10954 679 using HasRegistrationPromise = DOMPromiseDeferred<IDLBoolean>;
arajkumar@10954 680 void hasServiceWorkerRegistration(const String& clientURL, HasRegistrationPromise&&);
arajkumar@10954 681 void terminateServiceWorker(ServiceWorker&);
arajkumar@10954 682 bool hasServiceWorkerConnection();
arajkumar@10954 683 #endif
arajkumar@10954 684
arajkumar@10954 685 #if ENABLE(APPLE_PAY)
arajkumar@10954 686 MockPaymentCoordinator& mockPaymentCoordinator() const;
arajkumar@10954 687 #endif
arajkumar@10954 688
arajkumar@10954 689 String timelineDescription(AnimationTimeline&);
arajkumar@10954 690 void pauseTimeline(AnimationTimeline&);
arajkumar@10954 691 void setTimelineCurrentTime(AnimationTimeline&, double);
arajkumar@10954 692
arajkumar@10954 693 void testIncomingSyncIPCMessageWhileWaitingForSyncReply();
arajkumar@10954 694
arajkumar@11139 695 #if ENABLE(WEB_AUTHN)
arajkumar@11139 696 MockCredentialsMessenger& mockCredentialsMessenger() const;
arajkumar@11139 697 #endif
arajkumar@11139 698
arajkumar@11139 699 String systemPreviewRelType();
arajkumar@11139 700 bool isSystemPreviewLink(Element&) const;
arajkumar@11139 701 bool isSystemPreviewImage(Element&) const;
arajkumar@11139 702
arajkumar@11139 703 bool usingAppleInternalSDK() const;
arajkumar@11139 704
arajkumar@11139 705 struct NowPlayingState {
arajkumar@11139 706 String title;
arajkumar@11139 707 double duration;
arajkumar@11139 708 double elapsedTime;
arajkumar@11139 709 uint64_t uniqueIdentifier;
arajkumar@11139 710 bool hasActiveSession;
arajkumar@11139 711 bool registeredAsNowPlayingApplication;
arajkumar@11139 712 };
arajkumar@11139 713 ExceptionOr<NowPlayingState> nowPlayingState() const;
arajkumar@11139 714
arajkumar@11139 715 #if ENABLE(VIDEO)
arajkumar@11139 716 using PlaybackControlsPurpose = MediaElementSession::PlaybackControlsPurpose;
arajkumar@11139 717 RefPtr<HTMLMediaElement> bestMediaElementForShowingPlaybackControlsManager(PlaybackControlsPurpose);
arajkumar@11139 718
arajkumar@11139 719 using MediaSessionState = PlatformMediaSession::State;
arajkumar@11139 720 MediaSessionState mediaSessionState(HTMLMediaElement&);
arajkumar@11139 721 #endif
arajkumar@11139 722
arajkumar@11139 723 void setCaptureExtraNetworkLoadMetricsEnabled(bool);
arajkumar@11139 724 String ongoingLoadsDescriptions() const;
arajkumar@11139 725
arajkumar@11139 726 void reloadWithoutContentExtensions();
arajkumar@11139 727
arajkumar@11139 728 void setUseSystemAppearance(bool);
arajkumar@11139 729
arajkumar@11139 730 size_t pluginCount();
arajkumar@11139 731
arajkumar@11139 732 void notifyResourceLoadObserver();
arajkumar@11139 733
arajkumar@11208 734 void setAlwaysAllowLocalWebarchive(bool);
arajkumar@11139 735
peterz@3550 736 private:
arajkumar@10587 737 explicit Internals(Document&);
peterz@3550 738 Document* contextDocument() const;
peterz@3550 739 Frame* frame() const;
peterz@3550 740
arajkumar@10587 741 ExceptionOr<RenderedDocumentMarker*> markerAt(Node&, const String& markerType, unsigned index);
kcr@9800 742
mbilla@10730 743 // RealtimeMediaSource::Observer API
mbilla@10730 744 #if ENABLE(MEDIA_STREAM)
mbilla@10730 745 void videoSampleAvailable(MediaSample&) final;
mbilla@10730 746 void audioSamplesAvailable(const MediaTime&, const PlatformAudioData&, const AudioStreamDescription&, size_t) final { m_trackAudioSampleCount++; }
mbilla@10730 747
mbilla@10730 748 OrientationNotifier m_orientationNotifier;
mbilla@10730 749 unsigned long m_trackVideoSampleCount { 0 };
mbilla@10730 750 unsigned long m_trackAudioSampleCount { 0 };
mbilla@10730 751 RefPtr<MediaStreamTrack> m_track;
mbilla@10730 752 std::optional<TrackFramePromise> m_nextTrackFramePromise;
mbilla@10730 753 #endif
mbilla@10730 754
kcr@10196 755 std::unique_ptr<InspectorStubFrontend> m_inspectorFrontend;
arajkumar@10954 756 RefPtr<CacheStorageConnection> m_cacheStorageConnection;
arajkumar@10954 757
arajkumar@10954 758 #if ENABLE(APPLE_PAY)
arajkumar@10954 759 MockPaymentCoordinator* m_mockPaymentCoordinator { nullptr };
arajkumar@10954 760 #endif
arajkumar@11139 761
arajkumar@11139 762 #if ENABLE(WEB_AUTHN)
arajkumar@11139 763 std::unique_ptr<MockCredentialsMessenger> m_mockCredentialsMessenger;
arajkumar@11139 764 #endif
peterz@3550 765 };
peterz@3550 766
peterz@3550 767 } // namespace WebCore