chore: implement WebContentsDelegate::GetFullscreenState (#38355)

chore: implement WebContentsDelegate::GetFullscreenState

Refs https://chromium-review.googlesource.com/c/chromium/src/+/4255184

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
This commit is contained in:
trop[bot]
2023-05-18 16:54:38 -04:00
committed by GitHub
parent c9bea8b712
commit eb8eb6fae2
2 changed files with 8 additions and 0 deletions

View File

@@ -3847,6 +3847,12 @@ bool WebContents::IsFullscreenForTabOrPending(
return is_html_fullscreen() || (in_transition && is_html_transition);
}
content::FullscreenState WebContents::GetFullscreenState(
const content::WebContents* source) const {
return exclusive_access_manager_->fullscreen_controller()->GetFullscreenState(
source);
}
bool WebContents::TakeFocus(content::WebContents* source, bool reverse) {
if (source && source->GetOutermostWebContents() == source) {
// If this is the outermost web contents and the user has tabbed or

View File

@@ -690,6 +690,8 @@ class WebContents : public ExclusiveAccessContext,
bool IsExclusiveAccessBubbleDisplayed() const override;
bool IsFullscreenForTabOrPending(const content::WebContents* source) override;
content::FullscreenState GetFullscreenState(
const content::WebContents* web_contents) const override;
bool TakeFocus(content::WebContents* source, bool reverse) override;
content::PictureInPictureResult EnterPictureInPicture(
content::WebContents* web_contents) override;