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

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

Issue 50703013: fileSystemProvider: First cut at implementing fileSystemProvider API (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
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/bluetooth_permission.h" 7 #include "chrome/common/extensions/permissions/bluetooth_permission.h"
8 #include "chrome/common/extensions/permissions/media_galleries_permission.h" 8 #include "chrome/common/extensions/permissions/media_galleries_permission.h"
9 #include "chrome/common/extensions/permissions/socket_permission.h" 9 #include "chrome/common/extensions/permissions/socket_permission.h"
10 #include "chrome/common/extensions/permissions/usb_device_permission.h" 10 #include "chrome/common/extensions/permissions/usb_device_permission.h"
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 // The permission string for "fileSystem" is only shown when "write" or 292 // The permission string for "fileSystem" is only shown when "write" or
293 // "directory" is present. Read-only access is only granted after the user 293 // "directory" is present. Read-only access is only granted after the user
294 // has been shown a file or directory chooser dialog and selected a file or 294 // has been shown a file or directory chooser dialog and selected a file or
295 // directory . Selecting the file or directory is considered consent to 295 // directory . Selecting the file or directory is considered consent to
296 // read it. 296 // read it.
297 { APIPermission::kFileSystem, "fileSystem" }, 297 { APIPermission::kFileSystem, "fileSystem" },
298 { APIPermission::kFileSystemDirectory, "fileSystem.directory", 298 { APIPermission::kFileSystemDirectory, "fileSystem.directory",
299 APIPermissionInfo::kFlagNone, 299 APIPermissionInfo::kFlagNone,
300 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_DIRECTORY, 300 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_DIRECTORY,
301 PermissionMessage::kFileSystemDirectory }, 301 PermissionMessage::kFileSystemDirectory },
302 { APIPermission::kFileSystemProvider, "fileSystemProvider" },
302 { APIPermission::kFileSystemRetainEntries, "fileSystem.retainEntries" }, 303 { APIPermission::kFileSystemRetainEntries, "fileSystem.retainEntries" },
303 { APIPermission::kFileSystemWrite, "fileSystem.write", 304 { APIPermission::kFileSystemWrite, "fileSystem.write",
304 APIPermissionInfo::kFlagNone, 305 APIPermissionInfo::kFlagNone,
305 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_WRITE, 306 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_WRITE,
306 PermissionMessage::kFileSystemWrite }, 307 PermissionMessage::kFileSystemWrite },
307 { APIPermission::kFileSystemWriteDirectory, "fileSystem.writeDirectory", 308 { APIPermission::kFileSystemWriteDirectory, "fileSystem.writeDirectory",
308 APIPermissionInfo::kFlagNone, 309 APIPermissionInfo::kFlagNone,
309 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_WRITE_DIRECTORY, 310 IDS_EXTENSION_PROMPT_WARNING_FILE_SYSTEM_WRITE_DIRECTORY,
310 PermissionMessage::kFileSystemWriteDirectory }, 311 PermissionMessage::kFileSystemWriteDirectory },
311 // Because warning messages for the "mediaGalleries" permission vary based 312 // Because warning messages for the "mediaGalleries" permission vary based
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 // Register aliases. 365 // Register aliases.
365 std::vector<PermissionsProvider::AliasInfo> aliases; 366 std::vector<PermissionsProvider::AliasInfo> aliases;
366 aliases.push_back(PermissionsProvider::AliasInfo( 367 aliases.push_back(PermissionsProvider::AliasInfo(
367 "unlimitedStorage", kOldUnlimitedStoragePermission)); 368 "unlimitedStorage", kOldUnlimitedStoragePermission));
368 aliases.push_back(PermissionsProvider::AliasInfo( 369 aliases.push_back(PermissionsProvider::AliasInfo(
369 "tabs", kWindowsPermission)); 370 "tabs", kWindowsPermission));
370 return aliases; 371 return aliases;
371 } 372 }
372 373
373 } // namespace extensions 374 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698