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

Side by Side Diff: webkit/glue/plugins/pepper_error_util.cc

Issue 4164015: Switch to the new PPAPI repository. This removes the DEPS entry that refers t... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 10 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "webkit/glue/plugins/pepper_error_util.h" 5 #include "webkit/glue/plugins/pepper_error_util.h"
6 6
7 #include "third_party/ppapi/c/pp_errors.h" 7 #include "ppapi/c/pp_errors.h"
8 8
9 namespace pepper { 9 namespace pepper {
10 10
11 int PlatformFileErrorToPepperError(base::PlatformFileError error_code) { 11 int PlatformFileErrorToPepperError(base::PlatformFileError error_code) {
12 switch (error_code) { 12 switch (error_code) {
13 case base::PLATFORM_FILE_OK: 13 case base::PLATFORM_FILE_OK:
14 return PP_OK; 14 return PP_OK;
15 case base::PLATFORM_FILE_ERROR_EXISTS: 15 case base::PLATFORM_FILE_ERROR_EXISTS:
16 return PP_ERROR_FILEEXISTS; 16 return PP_ERROR_FILEEXISTS;
17 case base::PLATFORM_FILE_ERROR_NOT_FOUND: 17 case base::PLATFORM_FILE_ERROR_NOT_FOUND:
18 return PP_ERROR_FILENOTFOUND; 18 return PP_ERROR_FILENOTFOUND;
19 case base::PLATFORM_FILE_ERROR_ACCESS_DENIED: 19 case base::PLATFORM_FILE_ERROR_ACCESS_DENIED:
20 case base::PLATFORM_FILE_ERROR_SECURITY: 20 case base::PLATFORM_FILE_ERROR_SECURITY:
21 return PP_ERROR_NOACCESS; 21 return PP_ERROR_NOACCESS;
22 case base::PLATFORM_FILE_ERROR_NO_MEMORY: 22 case base::PLATFORM_FILE_ERROR_NO_MEMORY:
23 return PP_ERROR_NOMEMORY; 23 return PP_ERROR_NOMEMORY;
24 case base::PLATFORM_FILE_ERROR_NO_SPACE: 24 case base::PLATFORM_FILE_ERROR_NO_SPACE:
25 return PP_ERROR_NOSPACE; 25 return PP_ERROR_NOSPACE;
26 case base::PLATFORM_FILE_ERROR_NOT_A_DIRECTORY: 26 case base::PLATFORM_FILE_ERROR_NOT_A_DIRECTORY:
27 return PP_ERROR_FAILED; 27 return PP_ERROR_FAILED;
28 default: 28 default:
29 return PP_ERROR_FAILED; 29 return PP_ERROR_FAILED;
30 } 30 }
31 } 31 }
32 32
33 } // namespace pepper 33 } // namespace pepper
OLDNEW
« no previous file with comments | « webkit/glue/plugins/pepper_directory_reader.cc ('k') | webkit/glue/plugins/pepper_event_conversion.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698