Java Code Examples for org.chromium.content.browser.ContentVideoView#exitFullscreen()
The following examples show how to use
org.chromium.content.browser.ContentVideoView#exitFullscreen() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ChromeActivity.java From delion with Apache License 2.0 | 5 votes |
/** * Exits the fullscreen mode, if any. Does nothing if no fullscreen is present. * @return Whether the fullscreen mode is currently showing. */ protected boolean exitFullscreenIfShowing() { ContentVideoView view = ContentVideoView.getContentVideoView(); if (view != null && view.getContext() == this) { view.exitFullscreen(false); return true; } if (getFullscreenManager() != null && getFullscreenManager().getPersistentFullscreenMode()) { getFullscreenManager().setPersistentFullscreenMode(false); return true; } return false; }
Example 2
Source File: ChromeActivity.java From AndroidChromium with Apache License 2.0 | 5 votes |
/** * Exits the fullscreen mode, if any. Does nothing if no fullscreen is present. * @return Whether the fullscreen mode is currently showing. */ protected boolean exitFullscreenIfShowing() { ContentVideoView view = ContentVideoView.getContentVideoView(); if (view != null && view.getContext() == this) { view.exitFullscreen(false); return true; } if (getFullscreenManager() != null && getFullscreenManager().getPersistentFullscreenMode()) { getFullscreenManager().setPersistentFullscreenMode(false); return true; } return false; }
Example 3
Source File: ChromeActivity.java From 365browser with Apache License 2.0 | 5 votes |
/** * Exits the fullscreen mode, if any. Does nothing if no fullscreen is present. * @return Whether the fullscreen mode is currently showing. */ protected boolean exitFullscreenIfShowing() { ContentVideoView view = ContentVideoView.getContentVideoView(); if (view != null && view.getContext() == this) { view.exitFullscreen(false); return true; } if (getFullscreenManager() != null && getFullscreenManager().getPersistentFullscreenMode()) { getFullscreenManager().setPersistentFullscreenMode(false); return true; } return false; }
Example 4
Source File: AwContentsClient.java From android-chromium with BSD 2-Clause "Simplified" License | 5 votes |
@Override public void onShowCustomView(View view) { WebChromeClient.CustomViewCallback cb = new WebChromeClient.CustomViewCallback() { @Override public void onCustomViewHidden() { ContentVideoView contentVideoView = ContentVideoView.getContentVideoView(); if (contentVideoView != null) contentVideoView.exitFullscreen(false); } }; AwContentsClient.this.onShowCustomView(view, cb); }
Example 5
Source File: AwContentsClient.java From android-chromium with BSD 2-Clause "Simplified" License | 5 votes |
@Override public void onShowCustomView(View view) { WebChromeClient.CustomViewCallback cb = new WebChromeClient.CustomViewCallback() { @Override public void onCustomViewHidden() { ContentVideoView contentVideoView = ContentVideoView.getContentVideoView(); if (contentVideoView != null) contentVideoView.exitFullscreen(false); } }; AwContentsClient.this.onShowCustomView(view, cb); }