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

Side by Side Diff: chrome/common/extensions/permissions/chrome_api_permissions.cc

Issue 14607023: Add support for persistent file access in apps. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 7 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/chrome_api_permissions.h" 5 #include "chrome/common/extensions/permissions/chrome_api_permissions.h"
6 6
7 #include "chrome/common/extensions/permissions/api_permission.h" 7 #include "chrome/common/extensions/permissions/api_permission.h"
8 #include "chrome/common/extensions/permissions/api_permission_set.h" 8 #include "chrome/common/extensions/permissions/api_permission_set.h"
9 #include "chrome/common/extensions/permissions/bluetooth_device_permission.h" 9 #include "chrome/common/extensions/permissions/bluetooth_device_permission.h"
10 #include "chrome/common/extensions/permissions/media_galleries_permission.h" 10 #include "chrome/common/extensions/permissions/media_galleries_permission.h"
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 PermissionMessage::kAudioCapture }, 221 PermissionMessage::kAudioCapture },
222 { APIPermission::kVideoCapture, "videoCapture", 222 { APIPermission::kVideoCapture, "videoCapture",
223 APIPermissionInfo::kFlagNone, 223 APIPermissionInfo::kFlagNone,
224 IDS_EXTENSION_PROMPT_WARNING_VIDEO_CAPTURE, 224 IDS_EXTENSION_PROMPT_WARNING_VIDEO_CAPTURE,
225 PermissionMessage::kVideoCapture }, 225 PermissionMessage::kVideoCapture },
226 // The permission string for "fileSystem" is only shown when "write" is 226 // The permission string for "fileSystem" is only shown when "write" is
227 // present. Read-only access is only granted after the user has been shown 227 // present. Read-only access is only granted after the user has been shown
228 // a file chooser dialog and selected a file. Selecting the file is 228 // a file chooser dialog and selected a file. Selecting the file is
229 // considered consent to read it. 229 // considered consent to read it.
230 { APIPermission::kFileSystem, "fileSystem" }, 230 { APIPermission::kFileSystem, "fileSystem" },
231 { APIPermission::kFileSystemRetainFiles, "fileSystem.retainFiles" },
231 { APIPermission::kFileSystemWrite, "fileSystem.write", 232 { APIPermission::kFileSystemWrite, "fileSystem.write",
232 APIPermissionInfo::kFlagNone, 233 APIPermissionInfo::kFlagNone,
233 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_WRITE, 234 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_WRITE,
234 PermissionMessage::kFileSystemWrite }, 235 PermissionMessage::kFileSystemWrite },
235 // Because warning messages for the "mediaGalleries" permission vary based 236 // Because warning messages for the "mediaGalleries" permission vary based
236 // on the permissions parameters, no message ID or message text is 237 // on the permissions parameters, no message ID or message text is
237 // specified here. 238 // specified here.
238 // The message ID and text used will be determined at run-time in the 239 // The message ID and text used will be determined at run-time in the
239 // |MediaGalleriesPermission| class. 240 // |MediaGalleriesPermission| class.
240 { APIPermission::kMediaGalleries, "mediaGalleries", 241 { APIPermission::kMediaGalleries, "mediaGalleries",
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 // Register aliases. 284 // Register aliases.
284 std::vector<PermissionsInfo::AliasInfo> aliases; 285 std::vector<PermissionsInfo::AliasInfo> aliases;
285 aliases.push_back(PermissionsInfo::AliasInfo( 286 aliases.push_back(PermissionsInfo::AliasInfo(
286 "unlimitedStorage", kOldUnlimitedStoragePermission)); 287 "unlimitedStorage", kOldUnlimitedStoragePermission));
287 aliases.push_back(PermissionsInfo::AliasInfo( 288 aliases.push_back(PermissionsInfo::AliasInfo(
288 "tabs", kWindowsPermission)); 289 "tabs", kWindowsPermission));
289 return aliases; 290 return aliases;
290 } 291 }
291 292
292 } // namespace extensions 293 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/common/extensions/permissions/api_permission.h ('k') | chrome/common/extensions/permissions/permission_set_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698