OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "chrome/browser/sensor/sensor_permission_infobar_delegate_android.h" |
| 6 |
| 7 #include "chrome/browser/android/android_theme_resources.h" |
| 8 #include "chrome/grit/generated_resources.h" |
| 9 |
| 10 SensorPermissionInfoBarDelegateAndroid::SensorPermissionInfoBarDelegateAndroid( |
| 11 const GURL& requesting_frame, |
| 12 bool user_gesture, |
| 13 Profile* profile, |
| 14 const PermissionSetCallback& callback) |
| 15 : PermissionInfoBarDelegate(requesting_frame, |
| 16 content::PermissionType::SENSORS, |
| 17 CONTENT_SETTINGS_TYPE_SENSORS, |
| 18 user_gesture, |
| 19 profile, |
| 20 callback) {} |
| 21 |
| 22 SensorPermissionInfoBarDelegateAndroid:: |
| 23 ~SensorPermissionInfoBarDelegateAndroid() {} |
| 24 |
| 25 infobars::InfoBarDelegate::InfoBarIdentifier |
| 26 SensorPermissionInfoBarDelegateAndroid::GetIdentifier() const { |
| 27 return SENSORS_PERMISSION_INFOBAR_DELEGATE_ANDROID; |
| 28 } |
| 29 |
| 30 int SensorPermissionInfoBarDelegateAndroid::GetIconId() const { |
| 31 // TODO (riju): |
| 32 // return IDR_ANDROID_INFOBAR_SENSORS; |
| 33 // as of now reuse MIDI's icon |
| 34 return IDR_ANDROID_INFOBAR_MIDI; |
| 35 // return 1; |
| 36 } |
| 37 |
| 38 int SensorPermissionInfoBarDelegateAndroid::GetMessageResourceId() const { |
| 39 // TODO (riju): |
| 40 return IDS_SENSORS_INFOBAR_QUESTION; |
| 41 } |
OLD | NEW |