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

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

Issue 5648004: Add the "virtual" keyword on method overrides that are missing it. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Missing file Created 10 years 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
« no previous file with comments | « webkit/glue/plugins/pepper_file_ref.h ('k') | webkit/glue/plugins/pepper_file_system.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_file_ref.h" 5 #include "webkit/glue/plugins/pepper_file_ref.h"
6 6
7 #include "base/string_util.h" 7 #include "base/string_util.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "ppapi/c/pp_errors.h" 9 #include "ppapi/c/pp_errors.h"
10 #include "webkit/glue/plugins/pepper_common.h" 10 #include "webkit/glue/plugins/pepper_common.h"
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 } 258 }
259 259
260 FileRef::~FileRef() { 260 FileRef::~FileRef() {
261 } 261 }
262 262
263 // static 263 // static
264 const PPB_FileRef_Dev* FileRef::GetInterface() { 264 const PPB_FileRef_Dev* FileRef::GetInterface() {
265 return &ppb_fileref; 265 return &ppb_fileref;
266 } 266 }
267 267
268 FileRef* FileRef::AsFileRef() {
269 return this;
270 }
271
268 std::string FileRef::GetName() const { 272 std::string FileRef::GetName() const {
269 if (GetFileSystemType() == PP_FILESYSTEMTYPE_EXTERNAL) { 273 if (GetFileSystemType() == PP_FILESYSTEMTYPE_EXTERNAL) {
270 FilePath::StringType path = system_path_.value(); 274 FilePath::StringType path = system_path_.value();
271 size_t pos = path.rfind(FilePath::kSeparators[0]); 275 size_t pos = path.rfind(FilePath::kSeparators[0]);
272 DCHECK(pos != FilePath::StringType::npos); 276 DCHECK(pos != FilePath::StringType::npos);
273 #if defined(OS_WIN) 277 #if defined(OS_WIN)
274 return WideToUTF8(path.substr(pos + 1)); 278 return WideToUTF8(path.substr(pos + 1));
275 #elif defined(OS_POSIX) 279 #elif defined(OS_POSIX)
276 return path.substr(pos + 1); 280 return path.substr(pos + 1);
277 #else 281 #else
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
334 #elif defined(OS_POSIX) 338 #elif defined(OS_POSIX)
335 virtual_path_.substr(1) 339 virtual_path_.substr(1)
336 #else 340 #else
337 #error "Unsupported platform." 341 #error "Unsupported platform."
338 #endif 342 #endif
339 ); 343 );
340 return file_system_->root_path().Append(virtual_file_path); 344 return file_system_->root_path().Append(virtual_file_path);
341 } 345 }
342 346
343 } // namespace pepper 347 } // namespace pepper
OLDNEW
« no previous file with comments | « webkit/glue/plugins/pepper_file_ref.h ('k') | webkit/glue/plugins/pepper_file_system.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698