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

Side by Side Diff: chrome/browser/net/spdyproxy/data_reduction_proxy_infobar_delegate_android.cc

Issue 1520543004: Add method for identifying different InfoBars (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nit again Created 4 years, 11 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/net/spdyproxy/data_reduction_proxy_infobar_delegate_and roid.h" 5 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_infobar_delegate_and roid.h"
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "chrome/browser/infobars/infobar_service.h" 8 #include "chrome/browser/infobars/infobar_service.h"
9 #include "components/infobars/core/infobar.h" 9 #include "components/infobars/core/infobar.h"
10 #include "components/infobars/core/infobar_delegate.h" 10 #include "components/infobars/core/infobar_delegate.h"
(...skipping 15 matching lines...) Expand all
26 new DataReductionProxyInfoBarDelegateAndroid(link_url)))); 26 new DataReductionProxyInfoBarDelegateAndroid(link_url))));
27 } 27 }
28 28
29 DataReductionProxyInfoBarDelegateAndroid:: 29 DataReductionProxyInfoBarDelegateAndroid::
30 ~DataReductionProxyInfoBarDelegateAndroid() {} 30 ~DataReductionProxyInfoBarDelegateAndroid() {}
31 31
32 DataReductionProxyInfoBarDelegateAndroid:: 32 DataReductionProxyInfoBarDelegateAndroid::
33 DataReductionProxyInfoBarDelegateAndroid(const std::string& link_url) 33 DataReductionProxyInfoBarDelegateAndroid(const std::string& link_url)
34 : ConfirmInfoBarDelegate(), link_url_(link_url) {} 34 : ConfirmInfoBarDelegate(), link_url_(link_url) {}
35 35
36 infobars::InfoBarDelegate::InfoBarIdentifier
37 DataReductionProxyInfoBarDelegateAndroid::GetIdentifier() const {
38 return DATA_REDUCTION_PROXY_INFOBAR_DELEGATE_ANDROID;
39 }
40
36 bool DataReductionProxyInfoBarDelegateAndroid::ShouldExpire( 41 bool DataReductionProxyInfoBarDelegateAndroid::ShouldExpire(
37 const NavigationDetails& details) const { 42 const NavigationDetails& details) const {
38 return false; 43 return false;
39 } 44 }
40 45
41 base::string16 DataReductionProxyInfoBarDelegateAndroid::GetMessageText() 46 base::string16 DataReductionProxyInfoBarDelegateAndroid::GetMessageText()
42 const { 47 const {
43 return base::string16(); 48 return base::string16();
44 } 49 }
45 50
46 int DataReductionProxyInfoBarDelegateAndroid::GetButtons() const { 51 int DataReductionProxyInfoBarDelegateAndroid::GetButtons() const {
47 return BUTTON_NONE; 52 return BUTTON_NONE;
48 } 53 }
49 54
50 GURL DataReductionProxyInfoBarDelegateAndroid::GetLinkURL() const { 55 GURL DataReductionProxyInfoBarDelegateAndroid::GetLinkURL() const {
51 return GURL(link_url_); 56 return GURL(link_url_);
52 } 57 }
53 58
54 bool DataReductionProxyInfoBarDelegateAndroid::LinkClicked( 59 bool DataReductionProxyInfoBarDelegateAndroid::LinkClicked(
55 WindowOpenDisposition disposition) { 60 WindowOpenDisposition disposition) {
56 ConfirmInfoBarDelegate::LinkClicked(disposition); 61 ConfirmInfoBarDelegate::LinkClicked(disposition);
57 return true; 62 return true;
58 } 63 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698