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

Side by Side Diff: chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java

Issue 2542203002: [Android History] Add Android history manager UI and bridge (Closed)
Patch Set: Rebase, drop changes to time.* Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.chrome.browser; 5 package org.chromium.chrome.browser;
6 6
7 import android.annotation.SuppressLint; 7 import android.annotation.SuppressLint;
8 import android.annotation.TargetApi; 8 import android.annotation.TargetApi;
9 import android.app.Activity; 9 import android.app.Activity;
10 import android.app.SearchManager; 10 import android.app.SearchManager;
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 import org.chromium.chrome.browser.device.DeviceClassManager; 72 import org.chromium.chrome.browser.device.DeviceClassManager;
73 import org.chromium.chrome.browser.dom_distiller.DistilledPagePrefsView; 73 import org.chromium.chrome.browser.dom_distiller.DistilledPagePrefsView;
74 import org.chromium.chrome.browser.dom_distiller.ReaderModeManager; 74 import org.chromium.chrome.browser.dom_distiller.ReaderModeManager;
75 import org.chromium.chrome.browser.download.DownloadManagerService; 75 import org.chromium.chrome.browser.download.DownloadManagerService;
76 import org.chromium.chrome.browser.download.DownloadUtils; 76 import org.chromium.chrome.browser.download.DownloadUtils;
77 import org.chromium.chrome.browser.fullscreen.ChromeFullscreenManager; 77 import org.chromium.chrome.browser.fullscreen.ChromeFullscreenManager;
78 import org.chromium.chrome.browser.gsa.ContextReporter; 78 import org.chromium.chrome.browser.gsa.ContextReporter;
79 import org.chromium.chrome.browser.gsa.GSAAccountChangeListener; 79 import org.chromium.chrome.browser.gsa.GSAAccountChangeListener;
80 import org.chromium.chrome.browser.gsa.GSAState; 80 import org.chromium.chrome.browser.gsa.GSAState;
81 import org.chromium.chrome.browser.help.HelpAndFeedback; 81 import org.chromium.chrome.browser.help.HelpAndFeedback;
82 import org.chromium.chrome.browser.history.HistoryManagerUtils;
82 import org.chromium.chrome.browser.infobar.InfoBarContainer; 83 import org.chromium.chrome.browser.infobar.InfoBarContainer;
83 import org.chromium.chrome.browser.init.AsyncInitializationActivity; 84 import org.chromium.chrome.browser.init.AsyncInitializationActivity;
84 import org.chromium.chrome.browser.metrics.LaunchMetrics; 85 import org.chromium.chrome.browser.metrics.LaunchMetrics;
85 import org.chromium.chrome.browser.metrics.StartupMetrics; 86 import org.chromium.chrome.browser.metrics.StartupMetrics;
86 import org.chromium.chrome.browser.metrics.UmaSessionStats; 87 import org.chromium.chrome.browser.metrics.UmaSessionStats;
87 import org.chromium.chrome.browser.metrics.UmaUtils; 88 import org.chromium.chrome.browser.metrics.UmaUtils;
88 import org.chromium.chrome.browser.multiwindow.MultiWindowUtils; 89 import org.chromium.chrome.browser.multiwindow.MultiWindowUtils;
89 import org.chromium.chrome.browser.net.spdyproxy.DataReductionProxySettings; 90 import org.chromium.chrome.browser.net.spdyproxy.DataReductionProxySettings;
90 import org.chromium.chrome.browser.nfc.BeamController; 91 import org.chromium.chrome.browser.nfc.BeamController;
91 import org.chromium.chrome.browser.nfc.BeamProvider; 92 import org.chromium.chrome.browser.nfc.BeamProvider;
(...skipping 1583 matching lines...) Expand 10 before | Expand all | Expand 10 after
1675 currentTab.stopLoading(); 1676 currentTab.stopLoading();
1676 RecordUserAction.record("MobileMenuStop"); 1677 RecordUserAction.record("MobileMenuStop");
1677 } else { 1678 } else {
1678 currentTab.reload(); 1679 currentTab.reload();
1679 RecordUserAction.record("MobileMenuReload"); 1680 RecordUserAction.record("MobileMenuReload");
1680 } 1681 }
1681 } else if (id == R.id.info_menu_id) { 1682 } else if (id == R.id.info_menu_id) {
1682 WebsiteSettingsPopup.show( 1683 WebsiteSettingsPopup.show(
1683 this, currentTab, null, WebsiteSettingsPopup.OPENED_FROM_MEN U); 1684 this, currentTab, null, WebsiteSettingsPopup.OPENED_FROM_MEN U);
1684 } else if (id == R.id.open_history_menu_id) { 1685 } else if (id == R.id.open_history_menu_id) {
1685 currentTab.loadUrl( 1686 if (!HistoryManagerUtils.showHistoryManager(this)) {
1686 new LoadUrlParams(UrlConstants.HISTORY_URL, PageTransition.A UTO_TOPLEVEL)); 1687 currentTab.loadUrl(
1688 new LoadUrlParams(UrlConstants.HISTORY_URL, PageTransiti on.AUTO_TOPLEVEL));
1689 }
1687 RecordUserAction.record("MobileMenuHistory"); 1690 RecordUserAction.record("MobileMenuHistory");
1688 StartupMetrics.getInstance().recordOpenedHistory(); 1691 StartupMetrics.getInstance().recordOpenedHistory();
1689 } else if (id == R.id.share_menu_id || id == R.id.direct_share_menu_id) { 1692 } else if (id == R.id.share_menu_id || id == R.id.direct_share_menu_id) {
1690 onShareMenuItemSelected(id == R.id.direct_share_menu_id, 1693 onShareMenuItemSelected(id == R.id.direct_share_menu_id,
1691 getCurrentTabModel().isIncognito()); 1694 getCurrentTabModel().isIncognito());
1692 } else if (id == R.id.print_id) { 1695 } else if (id == R.id.print_id) {
1693 PrintingController printingController = PrintingControllerImpl.getIn stance(); 1696 PrintingController printingController = PrintingControllerImpl.getIn stance();
1694 if (printingController != null && !printingController.isBusy() 1697 if (printingController != null && !printingController.isBusy()
1695 && PrefServiceBridge.getInstance().isPrintingEnabled()) { 1698 && PrefServiceBridge.getInstance().isPrintingEnabled()) {
1696 printingController.startPrint(new TabPrinter(currentTab), 1699 printingController.startPrint(new TabPrinter(currentTab),
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
1930 "Android.MultiWindowMode.IsTabletScreenWidthBelow600", 1933 "Android.MultiWindowMode.IsTabletScreenWidthBelow600",
1931 mScreenWidthDp < DeviceFormFactor.MINIMUM_TABLET_WIDTH_DP); 1934 mScreenWidthDp < DeviceFormFactor.MINIMUM_TABLET_WIDTH_DP);
1932 1935
1933 if (mScreenWidthDp < DeviceFormFactor.MINIMUM_TABLET_WIDTH_DP) { 1936 if (mScreenWidthDp < DeviceFormFactor.MINIMUM_TABLET_WIDTH_DP) {
1934 RecordHistogram.recordLinearCountHistogram( 1937 RecordHistogram.recordLinearCountHistogram(
1935 "Android.MultiWindowMode.TabletScreenWidth", mScreenWidthDp, 1, 1938 "Android.MultiWindowMode.TabletScreenWidth", mScreenWidthDp, 1,
1936 DeviceFormFactor.MINIMUM_TABLET_WIDTH_DP, 50); 1939 DeviceFormFactor.MINIMUM_TABLET_WIDTH_DP, 50);
1937 } 1940 }
1938 } 1941 }
1939 } 1942 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698