Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1805)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/document/DocumentActivity.java

Issue 1363763002: Move duplicate code for exiting fullscreen to ChromeActivity (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rename Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/customtabs/CustomTabActivity.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/document/DocumentActivity.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/document/DocumentActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/document/DocumentActivity.java
index 8e72f5b8e75ab05f59f35b909b24a196ef065f99..258337a6fa4eaf898efe18710bccee25ea1c9bcd 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/document/DocumentActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/document/DocumentActivity.java
@@ -11,7 +11,6 @@ import android.os.Build;
import android.text.TextUtils;
import android.view.KeyEvent;
import android.view.Menu;
-import android.view.View;
import android.view.ViewGroup;
import android.view.Window;
@@ -61,7 +60,6 @@ import org.chromium.chrome.browser.util.FeatureUtilities;
import org.chromium.chrome.browser.util.IntentUtils;
import org.chromium.chrome.browser.widget.findinpage.FindToolbarManager;
import org.chromium.components.service_tab_launcher.ServiceTabLauncher;
-import org.chromium.content.browser.ContentVideoView;
import org.chromium.content_public.browser.LoadUrlParams;
import org.chromium.content_public.browser.NavigationEntry;
import org.chromium.ui.base.PageTransition;
@@ -656,16 +654,7 @@ public class DocumentActivity extends ChromeActivity {
public boolean handleBackPressed() {
if (mDocumentTab == null) return false;
- View view = ContentVideoView.getContentVideoView();
- if (view != null && view.getContext() == this) {
- ContentVideoView.getContentVideoView().exitFullscreen(false);
- return true;
- }
-
- if (getFullscreenManager().getPersistentFullscreenMode()) {
- getFullscreenManager().setPersistentFullscreenMode(false);
- return true;
- }
+ if (exitFullscreenIfShowing()) return true;
if (mDocumentTab.canGoBack()) {
mDocumentTab.goBack();
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/customtabs/CustomTabActivity.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698