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

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

Issue 7206016: Convert most remaining resources to use the API/thunk system. The significant (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 6 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) 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 #ifndef WEBKIT_PLUGINS_PPAPI_PPB_DIRECTORY_READER_IMPL_H_ 5 #ifndef WEBKIT_PLUGINS_PPAPI_PPB_DIRECTORY_READER_IMPL_H_
6 #define WEBKIT_PLUGINS_PPAPI_PPB_DIRECTORY_READER_IMPL_H_ 6 #define WEBKIT_PLUGINS_PPAPI_PPB_DIRECTORY_READER_IMPL_H_
7 7
8 #include <queue> 8 #include <queue>
9 9
10 #include "base/file_util_proxy.h" 10 #include "base/file_util_proxy.h"
(...skipping 11 matching lines...) Expand all
22 22
23 class PPB_DirectoryReader_Impl 23 class PPB_DirectoryReader_Impl
24 : public Resource, 24 : public Resource,
25 public ::ppapi::thunk::PPB_DirectoryReader_API { 25 public ::ppapi::thunk::PPB_DirectoryReader_API {
26 public: 26 public:
27 explicit PPB_DirectoryReader_Impl(PPB_FileRef_Impl* directory_ref); 27 explicit PPB_DirectoryReader_Impl(PPB_FileRef_Impl* directory_ref);
28 virtual ~PPB_DirectoryReader_Impl(); 28 virtual ~PPB_DirectoryReader_Impl();
29 29
30 static PP_Resource Create(PP_Resource directory_ref); 30 static PP_Resource Create(PP_Resource directory_ref);
31 31
32 // Resource overrides.
33 virtual PPB_DirectoryReader_Impl* AsPPB_DirectoryReader_Impl() OVERRIDE;
34
35 // ResourceObjectBase overrides. 32 // ResourceObjectBase overrides.
36 virtual ::ppapi::thunk::PPB_DirectoryReader_API* AsPPB_DirectoryReader_API() 33 virtual ::ppapi::thunk::PPB_DirectoryReader_API* AsPPB_DirectoryReader_API()
37 OVERRIDE; 34 OVERRIDE;
38 35
39 // PPB_DirectoryReader_API implementation. 36 // PPB_DirectoryReader_API implementation.
40 virtual int32_t GetNextEntry(PP_DirectoryEntry_Dev* entry, 37 virtual int32_t GetNextEntry(PP_DirectoryEntry_Dev* entry,
41 PP_CompletionCallback callback) OVERRIDE; 38 PP_CompletionCallback callback) OVERRIDE;
42 39
43 void AddNewEntries(const std::vector<base::FileUtilProxy::Entry>& entries, 40 void AddNewEntries(const std::vector<base::FileUtilProxy::Entry>& entries,
44 bool has_more); 41 bool has_more);
45 42
46 private: 43 private:
47 bool FillUpEntry(); 44 bool FillUpEntry();
48 45
49 scoped_refptr<PPB_FileRef_Impl> directory_ref_; 46 scoped_refptr<PPB_FileRef_Impl> directory_ref_;
50 std::queue<base::FileUtilProxy::Entry> entries_; 47 std::queue<base::FileUtilProxy::Entry> entries_;
51 bool has_more_; 48 bool has_more_;
52 PP_DirectoryEntry_Dev* entry_; 49 PP_DirectoryEntry_Dev* entry_;
53 }; 50 };
54 51
55 } // namespace ppapi 52 } // namespace ppapi
56 } // namespace webkit 53 } // namespace webkit
57 54
58 #endif // WEBKIT_PLUGINS_PPAPI_PPB_DIRECTORY_READER_IMPL_H_ 55 #endif // WEBKIT_PLUGINS_PPAPI_PPB_DIRECTORY_READER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698