Bug 212831 - WebCore: Guard variable declarations on ENABLE(VIDEO_PRESENTATION_MODE)
Summary: WebCore: Guard variable declarations on ENABLE(VIDEO_PRESENTATION_MODE)
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jonathan Bedard
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-06-05 09:52 PDT by Jonathan Bedard
Modified: 2020-06-05 14:22 PDT (History)
16 users (show)

See Also:


Attachments
Patch (1.34 KB, patch)
2020-06-05 10:00 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Bedard 2020-06-05 09:52:12 PDT
m_isEnteringOrExitingPictureInPicture and m_isWaitingForPictureInPictureWindowFrame are only used if VIDEO_PRESENTATION_MODE is enabled, no reason to declare these variable on platforms with VIDEO_PRESENTATION_MODE disabled.
Comment 1 Radar WebKit Bug Importer 2020-06-05 09:52:35 PDT
<rdar://problem/64033028>
Comment 2 Jonathan Bedard 2020-06-05 10:00:00 PDT
Created attachment 401166 [details]
Patch
Comment 3 Tim Horton 2020-06-05 10:29:01 PDT
IMO you can land things like this as "build fixes" without review if you want.
Comment 4 Jonathan Bedard 2020-06-05 10:38:06 PDT
(In reply to Tim Horton from comment #3)
> IMO you can land things like this as "build fixes" without review if you
> want.

There aren't many this trivial, I'm trying separate these into small enough changes that roll-outs for breaking other builds won't be too painful.
Comment 5 EWS 2020-06-05 10:56:02 PDT
Committed r262633: <https://trac.webkit.org/changeset/262633>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 401166 [details].
Comment 6 Peng Liu 2020-06-05 11:00:18 PDT
Comment on attachment 401166 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=401166&action=review

> Source/WebCore/html/HTMLVideoElement.h:136
>      bool m_isChangingPresentationMode { false };

And this variable as well :-)
Comment 7 Jonathan Bedard 2020-06-05 14:07:38 PDT
Comment on attachment 401166 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=401166&action=review

>> Source/WebCore/html/HTMLVideoElement.h:136
>>      bool m_isChangingPresentationMode { false };
> 
> And this variable as well :-)

Actually, m_isChangingPresentationMode is used in webkitDisplayingFullscreen, which isn't guarded by ENABLE(VIDEO_PRESENTATION_MODE).
Comment 8 Peng Liu 2020-06-05 14:22:00 PDT
Comment on attachment 401166 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=401166&action=review

>>> Source/WebCore/html/HTMLVideoElement.h:136
>>>      bool m_isChangingPresentationMode { false };
>> 
>> And this variable as well :-)
> 
> Actually, m_isChangingPresentationMode is used in webkitDisplayingFullscreen, which isn't guarded by ENABLE(VIDEO_PRESENTATION_MODE).

Oh right!