Skip to content

Commit

Permalink
Remove unnecessary headers included from Page.h
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=260472
rdar://114202982

Reviewed by Chris Dumez.

This should reduce compile times a little bit and have no other effect.

* Source/WebCore/Modules/screen-wake-lock/WakeLock.cpp:
* Source/WebCore/dom/Document.cpp:
* Source/WebCore/page/Page.cpp:
* Source/WebCore/page/Page.h:
(WebCore::Page::scheduledRunLoopPairs):
* Source/WebCore/page/ScreenOrientation.cpp:
* Source/WebCore/workers/WorkerMessagingProxy.cpp:
* Source/WebCore/workers/service/context/ServiceWorkerThreadProxy.cpp:
* Source/WebCore/workers/shared/context/SharedWorkerThreadProxy.cpp:
* Source/WebKitLegacy/mac/WebView/WebView.mm:

Canonical link: https://commits.webkit.org/267103@main
  • Loading branch information
achristensen07 committed Aug 21, 2023
1 parent 9a057d2 commit 31e2971
Show file tree
Hide file tree
Showing 9 changed files with 27 additions and 25 deletions.
1 change: 1 addition & 0 deletions Source/WebCore/Modules/screen-wake-lock/WakeLock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
#include "PermissionController.h"
#include "PermissionQuerySource.h"
#include "PermissionState.h"
#include "VisibilityState.h"
#include "WakeLockManager.h"
#include "WakeLockSentinel.h"

Expand Down
1 change: 1 addition & 0 deletions Source/WebCore/dom/Document.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,7 @@
#include "ValidationMessageClient.h"
#include "ViolationReportType.h"
#include "VisibilityChangeClient.h"
#include "VisibilityState.h"
#include "VisitedLinkState.h"
#include "VisualViewport.h"
#include "WakeLockManager.h"
Expand Down
2 changes: 2 additions & 0 deletions Source/WebCore/page/Page.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
#include "EventLoop.h"
#include "EventNames.h"
#include "ExtensionStyleSheets.h"
#include "FilterRenderingMode.h"
#include "FocusController.h"
#include "FontCache.h"
#include "FrameLoader.h"
Expand Down Expand Up @@ -165,6 +166,7 @@
#include "UserScript.h"
#include "UserStyleSheet.h"
#include "ValidationMessageClient.h"
#include "VisibilityState.h"
#include "VisitedLinkState.h"
#include "VisitedLinkStore.h"
#include "VoidCallback.h"
Expand Down
43 changes: 18 additions & 25 deletions Source/WebCore/page/Page.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,8 @@

#include "ActivityState.h"
#include "AnimationFrameRate.h"
#include "BadgeClient.h"
#include "Color.h"
#include "ContentSecurityPolicy.h"
#include "DisabledAdaptations.h"
#include "Document.h"
#include "EventTrackingRegions.h"
#include "FilterRenderingMode.h"
#include "FindOptions.h"
#include "FrameLoaderTypes.h"
#include "IntRectHash.h"
Expand All @@ -47,12 +42,10 @@
#include "RegistrableDomain.h"
#include "ScrollTypes.h"
#include "ShouldRelaxThirdPartyCookieBlocking.h"
#include "SpeechRecognitionConnection.h"
#include "Supplementable.h"
#include "Timer.h"
#include "UserInterfaceLayoutDirection.h"
#include "ViewportArguments.h"
#include "VisibilityState.h"
#include <memory>
#include <pal/SessionID.h>
#include <wtf/Assertions.h>
Expand All @@ -69,22 +62,10 @@
#include <wtf/WeakPtr.h>
#include <wtf/text/WTFString.h>

#if PLATFORM(COCOA)
#include <wtf/SchedulePair.h>
#endif

#if ENABLE(APPLICATION_MANIFEST)
#include "ApplicationManifest.h"
#endif

#if ENABLE(WIRELESS_PLAYBACK_TARGET)
#include "MediaPlaybackTargetContext.h"
#endif

#if ENABLE(DEVICE_ORIENTATION) && PLATFORM(IOS_FAMILY)
#include "DeviceOrientationUpdateProvider.h"
#endif

namespace JSC {
class Debugger;
}
Expand All @@ -94,7 +75,10 @@ class HysteresisActivity;
}

namespace WTF {
class SchedulePair;
class TextStream;
struct SchedulePairHash;
using SchedulePairHashSet = HashSet<RefPtr<SchedulePair>, SchedulePairHash>;
}

namespace WebCore {
Expand All @@ -111,13 +95,15 @@ class ApplicationCacheStorage;
class AttachmentElementClient;
class AuthenticatorCoordinator;
class BackForwardController;
class BadgeClient;
class BroadcastChannelRegistry;
class CacheStorageProvider;
class Chrome;
class ContextMenuController;
class CookieJar;
class DOMRectList;
class DatabaseProvider;
class DeviceOrientationUpdateProvider;
class DiagnosticLoggingClient;
class DragCaretController;
class DragController;
Expand Down Expand Up @@ -168,6 +154,7 @@ class Settings;
class SocketProvider;
class SpeechRecognitionProvider;
class SpeechSynthesisClient;
class SpeechRecognitionConnection;
class StorageNamespace;
class StorageNamespaceProvider;
class StorageProvider;
Expand All @@ -192,13 +179,19 @@ struct TextRecognitionResult;
using PlatformDisplayID = uint32_t;
using SharedStringHash = uint32_t;

enum class ActivityState : uint16_t;
enum class CanWrap : bool;
enum class DidWrap : bool;
enum class DisabledAdaptations : uint8_t;
enum class EventTrackingRegionsEventType : uint8_t;
enum class FilterRenderingMode : uint8_t;
enum class RouteSharingPolicy : uint8_t;
enum class ShouldTreatAsContinuingLoad : uint8_t;
enum class MediaPlaybackTargetContextMockState : uint8_t;
enum class MediaProducerMediaState : uint32_t;
enum class MediaProducerMediaCaptureKind : uint8_t;
enum class MediaProducerMutedState : uint8_t;
enum class VisibilityState : bool;

using MediaProducerMediaStateFlags = OptionSet<MediaProducerMediaState>;
using MediaProducerMutedStateFlags = OptionSet<MediaProducerMutedState>;
Expand Down Expand Up @@ -409,7 +402,7 @@ class Page : public Supplementable<Page>, public CanMakeWeakPtr<Page> {
WEBCORE_EXPORT String synchronousScrollingReasonsAsText();
WEBCORE_EXPORT Ref<DOMRectList> nonFastScrollableRectsForTesting();

WEBCORE_EXPORT Ref<DOMRectList> touchEventRectsForEventForTesting(EventTrackingRegions::EventType);
WEBCORE_EXPORT Ref<DOMRectList> touchEventRectsForEventForTesting(EventTrackingRegionsEventType);
WEBCORE_EXPORT Ref<DOMRectList> passiveTouchEventListenerRectsForTesting();

WEBCORE_EXPORT void settingsDidChange();
Expand Down Expand Up @@ -456,11 +449,11 @@ class Page : public Supplementable<Page>, public CanMakeWeakPtr<Page> {

#if PLATFORM(COCOA)
void platformInitialize();
WEBCORE_EXPORT void addSchedulePair(Ref<SchedulePair>&&);
WEBCORE_EXPORT void removeSchedulePair(Ref<SchedulePair>&&);
SchedulePairHashSet* scheduledRunLoopPairs() { return m_scheduledRunLoopPairs.get(); }
WEBCORE_EXPORT void addSchedulePair(Ref<WTF::SchedulePair>&&);
WEBCORE_EXPORT void removeSchedulePair(Ref<WTF::SchedulePair>&&);
WTF::SchedulePairHashSet* scheduledRunLoopPairs() { return m_scheduledRunLoopPairs.get(); }

std::unique_ptr<SchedulePairHashSet> m_scheduledRunLoopPairs;
std::unique_ptr<WTF::SchedulePairHashSet> m_scheduledRunLoopPairs;
#endif

WEBCORE_EXPORT const VisibleSelection& selection() const;
Expand Down Expand Up @@ -890,7 +883,7 @@ class Page : public Supplementable<Page>, public CanMakeWeakPtr<Page> {
void showPlaybackTargetPicker(PlaybackTargetClientContextIdentifier, const IntPoint&, bool, RouteSharingPolicy, const String&);
void playbackTargetPickerClientStateDidChange(PlaybackTargetClientContextIdentifier, MediaProducerMediaStateFlags);
WEBCORE_EXPORT void setMockMediaPlaybackTargetPickerEnabled(bool);
WEBCORE_EXPORT void setMockMediaPlaybackTargetPickerState(const String&, MediaPlaybackTargetContext::MockState);
WEBCORE_EXPORT void setMockMediaPlaybackTargetPickerState(const String&, MediaPlaybackTargetContextMockState);
WEBCORE_EXPORT void mockMediaPlaybackTargetPickerDismissPopup();

WEBCORE_EXPORT void setPlaybackTarget(PlaybackTargetClientContextIdentifier, Ref<MediaPlaybackTarget>&&);
Expand Down
1 change: 1 addition & 0 deletions Source/WebCore/page/ScreenOrientation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
#include "JSDOMPromiseDeferred.h"
#include "LocalDOMWindow.h"
#include "Page.h"
#include "VisibilityState.h"
#include <wtf/IsoMallocInlines.h>

namespace WebCore {
Expand Down
1 change: 1 addition & 0 deletions Source/WebCore/workers/WorkerMessagingProxy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
#include "config.h"
#include "WorkerMessagingProxy.h"

#include "BadgeClient.h"
#include "CacheStorageProvider.h"
#include "Chrome.h"
#include "ContentSecurityPolicy.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

#if ENABLE(SERVICE_WORKER)

#include "BadgeClient.h"
#include "CacheStorageProvider.h"
#include "DocumentLoader.h"
#include "EventLoop.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "config.h"
#include "SharedWorkerThreadProxy.h"

#include "BadgeClient.h"
#include "CacheStorageProvider.h"
#include "Chrome.h"
#include "ErrorEvent.h"
Expand Down
1 change: 1 addition & 0 deletions Source/WebKitLegacy/mac/WebView/WebView.mm
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,7 @@
#import <WebCore/UserScript.h>
#import <WebCore/UserStyleSheet.h>
#import <WebCore/ValidationBubble.h>
#import <WebCore/VisibilityState.h>
#import <WebCore/WebCoreJITOperations.h>
#import <WebCore/WebCoreObjCExtras.h>
#import <WebCore/WebCoreView.h>
Expand Down

0 comments on commit 31e2971

Please sign in to comment.