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

Side by Side Diff: webkit/plugins/ppapi/plugin_delegate.h

Issue 10541113: Notify CloseFile from Pepper to FileSystem. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Reflect review comments. Created 8 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ 5 #ifndef WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_
6 #define WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ 6 #define WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
406 bool final_result) = 0; 406 bool final_result) = 0;
407 407
408 // Notifies that the index of the currently selected item has been updated. 408 // Notifies that the index of the currently selected item has been updated.
409 virtual void SelectedFindResultChanged(int identifier, int index) = 0; 409 virtual void SelectedFindResultChanged(int identifier, int index) = 0;
410 410
411 // Runs a file chooser. 411 // Runs a file chooser.
412 virtual bool RunFileChooser( 412 virtual bool RunFileChooser(
413 const WebKit::WebFileChooserParams& params, 413 const WebKit::WebFileChooserParams& params,
414 WebKit::WebFileChooserCompletion* chooser_completion) = 0; 414 WebKit::WebFileChooserCompletion* chooser_completion) = 0;
415 415
416 // Sends an async IPC to open a file. 416 // Sends an async IPC to open a local file.
417 typedef base::Callback<void (base::PlatformFileError, base::PassPlatformFile)> 417 typedef base::Callback<void (base::PlatformFileError, base::PassPlatformFile)>
418 AsyncOpenFileCallback; 418 AsyncOpenFileCallback;
419 virtual bool AsyncOpenFile(const FilePath& path, 419 virtual bool AsyncOpenFile(const FilePath& path,
420 int flags, 420 int flags,
421 const AsyncOpenFileCallback& callback) = 0; 421 const AsyncOpenFileCallback& callback) = 0;
422
423 // Sends an async IPC to open a file through filesystem API.
424 // When a file is successfully opened, |callback| is invoked with
425 // PLATFORM_FILE_OK, the opened file handle, and a callback function for
426 // notifying that the file is closed. When the users of this function
427 // finished using the file, it must close the file handle and then must call
yzshen1 2012/07/03 17:26:31 nit: it -> they.
kinaba 2012/07/04 04:26:22 Done.
428 // the supplied callback function.
429 typedef base::Callback<void (base::PlatformFileError)>
430 NotifyCloseFileCallback;
431 typedef base::Callback<
432 void (base::PlatformFileError,
433 base::PassPlatformFile,
434 const NotifyCloseFileCallback&)> AsyncOpenFileSystemURLCallback;
422 virtual bool AsyncOpenFileSystemURL( 435 virtual bool AsyncOpenFileSystemURL(
423 const GURL& path, 436 const GURL& path,
424 int flags, 437 int flags,
425 const AsyncOpenFileCallback& callback) = 0; 438 const AsyncOpenFileSystemURLCallback& callback) = 0;
426 439
427 virtual bool OpenFileSystem( 440 virtual bool OpenFileSystem(
428 const GURL& url, 441 const GURL& url,
429 fileapi::FileSystemType type, 442 fileapi::FileSystemType type,
430 long long size, 443 long long size,
431 fileapi::FileSystemCallbackDispatcher* dispatcher) = 0; 444 fileapi::FileSystemCallbackDispatcher* dispatcher) = 0;
432 virtual bool MakeDirectory( 445 virtual bool MakeDirectory(
433 const GURL& path, 446 const GURL& path,
434 bool recursive, 447 bool recursive,
435 fileapi::FileSystemCallbackDispatcher* dispatcher) = 0; 448 fileapi::FileSystemCallbackDispatcher* dispatcher) = 0;
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
648 virtual webkit_glue::ClipboardClient* CreateClipboardClient() const = 0; 661 virtual webkit_glue::ClipboardClient* CreateClipboardClient() const = 0;
649 662
650 // Returns a Device ID 663 // Returns a Device ID
651 virtual std::string GetDeviceID() = 0; 664 virtual std::string GetDeviceID() = 0;
652 }; 665 };
653 666
654 } // namespace ppapi 667 } // namespace ppapi
655 } // namespace webkit 668 } // namespace webkit
656 669
657 #endif // WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ 670 #endif // WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698