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

Side by Side Diff: chrome/browser/ui/page_info/page_info_infobar_delegate.cc

Issue 2849713003: Move all Page Info strings into page_info_strings.grdp (Closed)
Patch Set: Fix moar. Created 3 years, 7 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/page_info/page_info.cc ('k') | chrome/browser/ui/page_info/page_info_ui.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chrome/browser/ui/page_info/page_info_infobar_delegate.h" 5 #include "chrome/browser/ui/page_info/page_info_infobar_delegate.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "build/build_config.h" 9 #include "build/build_config.h"
10 #include "chrome/app/vector_icons/vector_icons.h" 10 #include "chrome/app/vector_icons/vector_icons.h"
11 #include "chrome/browser/infobars/infobar_service.h" 11 #include "chrome/browser/infobars/infobar_service.h"
12 #include "chrome/grit/generated_resources.h"
13 #include "chrome/grit/theme_resources.h" 12 #include "chrome/grit/theme_resources.h"
14 #include "components/infobars/core/infobar.h" 13 #include "components/infobars/core/infobar.h"
14 #include "components/strings/grit/components_strings.h"
15 #include "content/public/browser/web_contents.h" 15 #include "content/public/browser/web_contents.h"
16 #include "ui/base/l10n/l10n_util.h" 16 #include "ui/base/l10n/l10n_util.h"
17 17
18 // static 18 // static
19 void PageInfoInfoBarDelegate::Create(InfoBarService* infobar_service) { 19 void PageInfoInfoBarDelegate::Create(InfoBarService* infobar_service) {
20 infobar_service->AddInfoBar(infobar_service->CreateConfirmInfoBar( 20 infobar_service->AddInfoBar(infobar_service->CreateConfirmInfoBar(
21 std::unique_ptr<ConfirmInfoBarDelegate>(new PageInfoInfoBarDelegate()))); 21 std::unique_ptr<ConfirmInfoBarDelegate>(new PageInfoInfoBarDelegate())));
22 } 22 }
23 23
24 PageInfoInfoBarDelegate::PageInfoInfoBarDelegate() : ConfirmInfoBarDelegate() {} 24 PageInfoInfoBarDelegate::PageInfoInfoBarDelegate() : ConfirmInfoBarDelegate() {}
(...skipping 27 matching lines...) Expand all
52 DCHECK_EQ(BUTTON_OK, button); 52 DCHECK_EQ(BUTTON_OK, button);
53 return l10n_util::GetStringUTF16(IDS_PAGE_INFO_INFOBAR_BUTTON); 53 return l10n_util::GetStringUTF16(IDS_PAGE_INFO_INFOBAR_BUTTON);
54 } 54 }
55 55
56 bool PageInfoInfoBarDelegate::Accept() { 56 bool PageInfoInfoBarDelegate::Accept() {
57 content::WebContents* web_contents = 57 content::WebContents* web_contents =
58 InfoBarService::WebContentsFromInfoBar(infobar()); 58 InfoBarService::WebContentsFromInfoBar(infobar());
59 web_contents->GetController().Reload(content::ReloadType::NORMAL, true); 59 web_contents->GetController().Reload(content::ReloadType::NORMAL, true);
60 return true; 60 return true;
61 } 61 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/page_info/page_info.cc ('k') | chrome/browser/ui/page_info/page_info_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698