| OLD | NEW |
| 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/common/extensions/permissions/bluetooth_permission.h" | 5 #include "chrome/common/extensions/permissions/bluetooth_permission.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 return true; | 43 return true; |
| 44 } | 44 } |
| 45 | 45 |
| 46 PermissionMessages BluetoothPermission::GetMessages() const { | 46 PermissionMessages BluetoothPermission::GetMessages() const { |
| 47 DCHECK(HasMessages()); | 47 DCHECK(HasMessages()); |
| 48 PermissionMessages result; | 48 PermissionMessages result; |
| 49 | 49 |
| 50 result.push_back(PermissionMessage( | 50 result.push_back(PermissionMessage( |
| 51 PermissionMessage::kBluetooth, | 51 PermissionMessage::kBluetooth, |
| 52 l10n_util::GetStringUTF16( | 52 l10n_util::GetStringUTF16( |
| 53 IDS_EXTENSION_PROMPT_WARNING_BLUETOOTH))); | 53 IDS_EXTENSION_PROMPT_WARNING_BLUETOOTH), |
| 54 string16())); |
| 54 | 55 |
| 55 if (!data_set_.empty()) { | 56 if (!data_set_.empty()) { |
| 56 result.push_back(PermissionMessage( | 57 result.push_back(PermissionMessage( |
| 57 PermissionMessage::kBluetoothDevices, | 58 PermissionMessage::kBluetoothDevices, |
| 58 l10n_util::GetStringUTF16( | 59 l10n_util::GetStringUTF16( |
| 59 IDS_EXTENSION_PROMPT_WARNING_BLUETOOTH_DEVICES))); | 60 IDS_EXTENSION_PROMPT_WARNING_BLUETOOTH_DEVICES), |
| 61 string16())); |
| 60 } | 62 } |
| 61 | 63 |
| 62 return result; | 64 return result; |
| 63 } | 65 } |
| 64 | 66 |
| 65 } // namespace extensions | 67 } // namespace extensions |
| OLD | NEW |