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

Side by Side Diff: chrome/browser/media/protected_media_identifier_infobar_delegate_android.cc

Issue 2415863002: Use PermissionType instead of ContentSettingsType in Android permission infobars (Closed)
Patch Set: Merge branch 'master' into use_permission_type_for_infobar Created 4 years, 2 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/media/protected_media_identifier_infobar_delegate_andro id.h" 5 #include "chrome/browser/media/protected_media_identifier_infobar_delegate_andro id.h"
6 6
7 #include "chrome/browser/android/android_theme_resources.h" 7 #include "chrome/browser/android/android_theme_resources.h"
8 #include "chrome/browser/infobars/infobar_service.h" 8 #include "chrome/browser/infobars/infobar_service.h"
9 #include "chrome/common/url_constants.h" 9 #include "chrome/common/url_constants.h"
10 #include "chrome/grit/generated_resources.h" 10 #include "chrome/grit/generated_resources.h"
(...skipping 16 matching lines...) Expand all
27 27
28 ProtectedMediaIdentifierInfoBarDelegateAndroid:: 28 ProtectedMediaIdentifierInfoBarDelegateAndroid::
29 ProtectedMediaIdentifierInfoBarDelegateAndroid( 29 ProtectedMediaIdentifierInfoBarDelegateAndroid(
30 const GURL& requesting_frame, 30 const GURL& requesting_frame,
31 bool user_gesture, 31 bool user_gesture,
32 Profile* profile, 32 Profile* profile,
33 const PermissionSetCallback& callback) 33 const PermissionSetCallback& callback)
34 : PermissionInfoBarDelegate( 34 : PermissionInfoBarDelegate(
35 requesting_frame, 35 requesting_frame,
36 content::PermissionType::PROTECTED_MEDIA_IDENTIFIER, 36 content::PermissionType::PROTECTED_MEDIA_IDENTIFIER,
37 CONTENT_SETTINGS_TYPE_PROTECTED_MEDIA_IDENTIFIER,
38 user_gesture, 37 user_gesture,
39 profile, 38 profile,
40 callback) {} 39 callback) {}
41 40
42 ProtectedMediaIdentifierInfoBarDelegateAndroid:: 41 ProtectedMediaIdentifierInfoBarDelegateAndroid::
43 ~ProtectedMediaIdentifierInfoBarDelegateAndroid() {} 42 ~ProtectedMediaIdentifierInfoBarDelegateAndroid() {}
44 43
45 infobars::InfoBarDelegate::InfoBarIdentifier 44 infobars::InfoBarDelegate::InfoBarIdentifier
46 ProtectedMediaIdentifierInfoBarDelegateAndroid::GetIdentifier() const { 45 ProtectedMediaIdentifierInfoBarDelegateAndroid::GetIdentifier() const {
47 return PROTECTED_MEDIA_IDENTIFIER_INFOBAR_DELEGATE_ANDROID; 46 return PROTECTED_MEDIA_IDENTIFIER_INFOBAR_DELEGATE_ANDROID;
48 } 47 }
49 48
50 int ProtectedMediaIdentifierInfoBarDelegateAndroid::GetIconId() const { 49 int ProtectedMediaIdentifierInfoBarDelegateAndroid::GetIconId() const {
51 return IDR_ANDROID_INFOBAR_PROTECTED_MEDIA_IDENTIFIER; 50 return IDR_ANDROID_INFOBAR_PROTECTED_MEDIA_IDENTIFIER;
52 } 51 }
53 52
54 base::string16 ProtectedMediaIdentifierInfoBarDelegateAndroid::GetLinkText() 53 base::string16 ProtectedMediaIdentifierInfoBarDelegateAndroid::GetLinkText()
55 const { 54 const {
56 return l10n_util::GetStringUTF16(IDS_LEARN_MORE); 55 return l10n_util::GetStringUTF16(IDS_LEARN_MORE);
57 } 56 }
58 57
59 GURL ProtectedMediaIdentifierInfoBarDelegateAndroid::GetLinkURL() const { 58 GURL ProtectedMediaIdentifierInfoBarDelegateAndroid::GetLinkURL() const {
60 return GURL(chrome::kEnhancedPlaybackNotificationLearnMoreURL); 59 return GURL(chrome::kEnhancedPlaybackNotificationLearnMoreURL);
61 } 60 }
62 61
63 int ProtectedMediaIdentifierInfoBarDelegateAndroid::GetMessageResourceId() 62 int ProtectedMediaIdentifierInfoBarDelegateAndroid::GetMessageResourceId()
64 const { 63 const {
65 return IDS_PROTECTED_MEDIA_IDENTIFIER_INFOBAR_QUESTION; 64 return IDS_PROTECTED_MEDIA_IDENTIFIER_INFOBAR_QUESTION;
66 } 65 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698