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

Unified Diff: chrome/browser/ui/webui/md_history_ui.cc

Issue 2077483002: MD History: Add confirmation dialog when deleting items from the toolbar (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cr_refactor_dialog
Patch Set: Address nits Created 4 years, 5 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/browser/ui/webui/history_ui.cc ('k') | chrome/test/data/webui/md_history/history_list_test.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/md_history_ui.cc
diff --git a/chrome/browser/ui/webui/md_history_ui.cc b/chrome/browser/ui/webui/md_history_ui.cc
index e2dac02ef55954f96949d2bbfd974a5a0f108756..425f197c274519811920b777168e6245c4882bca 100644
--- a/chrome/browser/ui/webui/md_history_ui.cc
+++ b/chrome/browser/ui/webui/md_history_ui.cc
@@ -11,6 +11,7 @@
#include "chrome/browser/ui/webui/browsing_history_handler.h"
#include "chrome/browser/ui/webui/foreign_session_handler.h"
#include "chrome/browser/ui/webui/history_login_handler.h"
+#include "chrome/browser/ui/webui/history_ui.h"
#include "chrome/browser/ui/webui/metrics_handler.h"
#include "chrome/browser/ui/webui/settings/people_handler.h"
#include "chrome/common/chrome_features.h"
@@ -43,6 +44,8 @@ content::WebUIDataSource* CreateMdHistoryUIHTMLSource(Profile* profile) {
IDS_CLEAR_BROWSING_DATA_TITLE);
source->AddLocalizedString("clearSearch", IDS_MD_HISTORY_CLEAR_SEARCH);
source->AddLocalizedString("delete", IDS_MD_HISTORY_DELETE);
+ source->AddLocalizedString("deleteConfirm",
+ IDS_HISTORY_DELETE_PRIOR_VISITS_CONFIRM_BUTTON);
source->AddLocalizedString("foundSearchResults",
IDS_HISTORY_FOUND_SEARCH_RESULTS);
source->AddLocalizedString("historyInterval", IDS_HISTORY_INTERVAL);
@@ -68,6 +71,8 @@ content::WebUIDataSource* CreateMdHistoryUIHTMLSource(Profile* profile) {
source->AddLocalizedString("rangePrevious", IDS_HISTORY_RANGE_PREVIOUS);
source->AddLocalizedString("removeBookmark", IDS_HISTORY_REMOVE_BOOKMARK);
source->AddLocalizedString("removeFromHistory", IDS_HISTORY_REMOVE_PAGE);
+ source->AddLocalizedString("removeSelected",
+ IDS_HISTORY_REMOVE_SELECTED_ITEMS);
source->AddLocalizedString("searchPrompt", IDS_MD_HISTORY_SEARCH_PROMPT);
source->AddLocalizedString("searchResult", IDS_HISTORY_SEARCH_RESULT);
source->AddLocalizedString("searchResults", IDS_HISTORY_SEARCH_RESULTS);
@@ -77,6 +82,9 @@ content::WebUIDataSource* CreateMdHistoryUIHTMLSource(Profile* profile) {
IDS_MD_HISTORY_SIGN_IN_PROMO_DESC);
source->AddLocalizedString("title", IDS_HISTORY_TITLE);
+ source->AddString("deleteWarning",
+ HistoryUI::GetDeleteWarningString(profile));
+
bool allow_deleting_history =
prefs->GetBoolean(prefs::kAllowDeletingBrowserHistory);
source->AddBoolean("allowDeletingHistory", allow_deleting_history);
« no previous file with comments | « chrome/browser/ui/webui/history_ui.cc ('k') | chrome/test/data/webui/md_history/history_list_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698