mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
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:
@@ -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
|
||||
|
||||
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user