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

Unified Diff: Source/core/platform/midi/MIDIAccessor.h

Issue 16288002: Web MIDI API (work in progress) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: minor compile fix Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/platform/midi/MIDIAccessorChromium.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/platform/midi/MIDIAccessor.h
diff --git a/Source/core/platform/Task.h b/Source/core/platform/midi/MIDIAccessor.h
similarity index 80%
copy from Source/core/platform/Task.h
copy to Source/core/platform/midi/MIDIAccessor.h
index b9d2e46802aebf6391df4ec3dabb580d43b2483c..49531d40c62b6cfb87457711571b2839d561be32 100644
--- a/Source/core/platform/Task.h
+++ b/Source/core/platform/midi/MIDIAccessor.h
@@ -28,30 +28,26 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef Task_h
-#define Task_h
+#ifndef MIDIAccessor_h
+#define MIDIAccessor_h
-#include "wtf/Functional.h"
-#include "public/platform/WebThread.h"
+#include <wtf/OwnPtr.h>
+#include <wtf/PassOwnPtr.h>
namespace WebCore {
-class Task : public WebKit::WebThread::Task {
+class MIDIAccessorClient {
public:
- explicit Task(const Closure& closure)
- : m_closure(closure)
- {
- }
-
- virtual void run() OVERRIDE
- {
- m_closure();
- }
-
-private:
- Closure m_closure;
+ virtual void receiveMIDIData(unsigned portIndex, const unsigned char* data, size_t length, double timeStamp);
+};
+
+class MIDIAccessor {
+public:
+ static PassOwnPtr<MIDIAccessor> create(MIDIAccessorClient* client);
+
+ virtual ~MIDIAccessor() { }
};
} // namespace WebCore
-#endif // Task_h
+#endif // MIDIAccessor_h
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/platform/midi/MIDIAccessorChromium.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698