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: third_party/WebKit/Source/modules/filesystem/DOMFileSystem.h

Issue 2040563002: Remove FileError interface (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@fe-dep
Patch Set: handleEvent -> invoke and other review nits Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 static DOMFileSystem* create(ExecutionContext*, const String& name, FileSyst emType, const KURL& rootURL); 57 static DOMFileSystem* create(ExecutionContext*, const String& name, FileSyst emType, const KURL& rootURL);
58 58
59 // Creates a new isolated file system for the given filesystemId. 59 // Creates a new isolated file system for the given filesystemId.
60 static DOMFileSystem* createIsolatedFileSystem(ExecutionContext*, const Stri ng& filesystemId); 60 static DOMFileSystem* createIsolatedFileSystem(ExecutionContext*, const Stri ng& filesystemId);
61 61
62 DirectoryEntry* root() const; 62 DirectoryEntry* root() const;
63 63
64 // DOMFileSystemBase overrides. 64 // DOMFileSystemBase overrides.
65 void addPendingCallbacks() override; 65 void addPendingCallbacks() override;
66 void removePendingCallbacks() override; 66 void removePendingCallbacks() override;
67 void reportError(ErrorCallback*, FileError*) override; 67 void reportError(ErrorCallbackBase*, FileError::ErrorCode) override;
68 68
69 static void reportError(ExecutionContext*, ErrorCallback*, FileError*); 69 static void reportError(ExecutionContext*, ErrorCallbackBase*, FileError::Er rorCode);
70 70
71 // ActiveScriptWrappable overrides. 71 // ActiveScriptWrappable overrides.
72 bool hasPendingActivity() const final; 72 bool hasPendingActivity() const final;
73 73
74 void createWriter(const FileEntry*, FileWriterCallback*, ErrorCallback*); 74 void createWriter(const FileEntry*, FileWriterCallback*, ErrorCallbackBase*) ;
75 void createFile(const FileEntry*, BlobCallback*, ErrorCallback*); 75 void createFile(const FileEntry*, BlobCallback*, ErrorCallbackBase*);
76 76
77 // Schedule a callback. This should not cross threads (should be called on t he same context thread). 77 // Schedule a callback. This should not cross threads (should be called on t he same context thread).
78 static void scheduleCallback(ExecutionContext* executionContext, std::unique _ptr<ExecutionContextTask> task) 78 static void scheduleCallback(ExecutionContext* executionContext, std::unique _ptr<ExecutionContextTask> task)
79 { 79 {
80 DCHECK(executionContext->isContextThread()); 80 DCHECK(executionContext->isContextThread());
81 executionContext->postTask(BLINK_FROM_HERE, std::move(task), taskNameFor Instrumentation()); 81 executionContext->postTask(BLINK_FROM_HERE, std::move(task), taskNameFor Instrumentation());
82 } 82 }
83 83
84 DECLARE_VIRTUAL_TRACE(); 84 DECLARE_VIRTUAL_TRACE();
85 85
86 private: 86 private:
87 DOMFileSystem(ExecutionContext*, const String& name, FileSystemType, const K URL& rootURL); 87 DOMFileSystem(ExecutionContext*, const String& name, FileSystemType, const K URL& rootURL);
88 88
89 static String taskNameForInstrumentation() 89 static String taskNameForInstrumentation()
90 { 90 {
91 return "FileSystem"; 91 return "FileSystem";
92 } 92 }
93 93
94 int m_numberOfPendingCallbacks; 94 int m_numberOfPendingCallbacks;
95 Member<DirectoryEntry> m_rootEntry; 95 Member<DirectoryEntry> m_rootEntry;
96 }; 96 };
97 97
98 } // namespace blink 98 } // namespace blink
99 99
100 #endif // DOMFileSystem_h 100 #endif // DOMFileSystem_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698