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

Side by Side Diff: Source/modules/webmidi/MIDIAccessor.h

Issue 1227783004: Fix virtual/override/final usage in Source/modules/. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 5 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 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 26 matching lines...) Expand all
37 #include "wtf/PassOwnPtr.h" 37 #include "wtf/PassOwnPtr.h"
38 38
39 namespace blink { 39 namespace blink {
40 40
41 class MIDIAccessorClient; 41 class MIDIAccessorClient;
42 42
43 class MIDIAccessor final : public WebMIDIAccessorClient { 43 class MIDIAccessor final : public WebMIDIAccessorClient {
44 public: 44 public:
45 static PassOwnPtr<MIDIAccessor> create(MIDIAccessorClient*); 45 static PassOwnPtr<MIDIAccessor> create(MIDIAccessorClient*);
46 46
47 virtual ~MIDIAccessor() { } 47 ~MIDIAccessor() override { }
48 48
49 void startSession(); 49 void startSession();
50 void sendMIDIData(unsigned portIndex, const unsigned char* data, size_t leng th, double timeStamp); 50 void sendMIDIData(unsigned portIndex, const unsigned char* data, size_t leng th, double timeStamp);
51 // MIDIAccessInitializer and MIDIAccess are both MIDIAccessClient. 51 // MIDIAccessInitializer and MIDIAccess are both MIDIAccessClient.
52 // MIDIAccessInitializer is the first client and MIDIAccess takes over it 52 // MIDIAccessInitializer is the first client and MIDIAccess takes over it
53 // once the initialization successfully finishes. 53 // once the initialization successfully finishes.
54 void setClient(MIDIAccessorClient* client) { m_client = client; } 54 void setClient(MIDIAccessorClient* client) { m_client = client; }
55 55
56 // WebMIDIAccessorClient 56 // WebMIDIAccessorClient
57 virtual void didAddInputPort(const WebString& id, const WebString& manufactu rer, const WebString& name, const WebString& version, MIDIPortState) override; 57 void didAddInputPort(const WebString& id, const WebString& manufacturer, con st WebString& name, const WebString& version, MIDIPortState) override;
58 virtual void didAddOutputPort(const WebString& id, const WebString& manufact urer, const WebString& name, const WebString& version, MIDIPortState) override; 58 void didAddOutputPort(const WebString& id, const WebString& manufacturer, co nst WebString& name, const WebString& version, MIDIPortState) override;
59 virtual void didSetInputPortState(unsigned portIndex, MIDIPortState) overrid e; 59 void didSetInputPortState(unsigned portIndex, MIDIPortState) override;
60 virtual void didSetOutputPortState(unsigned portIndex, MIDIPortState) overri de; 60 void didSetOutputPortState(unsigned portIndex, MIDIPortState) override;
61 virtual void didStartSession(bool success, const WebString& error, const Web String& message) override; 61 void didStartSession(bool success, const WebString& error, const WebString& message) override;
62 virtual void didReceiveMIDIData(unsigned portIndex, const unsigned char* dat a, size_t length, double timeStamp) override; 62 void didReceiveMIDIData(unsigned portIndex, const unsigned char* data, size_ t length, double timeStamp) override;
63 63
64 private: 64 private:
65 explicit MIDIAccessor(MIDIAccessorClient*); 65 explicit MIDIAccessor(MIDIAccessorClient*);
66 66
67 MIDIAccessorClient* m_client; 67 MIDIAccessorClient* m_client;
68 OwnPtr<WebMIDIAccessor> m_accessor; 68 OwnPtr<WebMIDIAccessor> m_accessor;
69 }; 69 };
70 70
71 } // namespace blink 71 } // namespace blink
72 72
73 #endif // MIDIAccessor_h 73 #endif // MIDIAccessor_h
OLDNEW
« no previous file with comments | « Source/modules/webmidi/MIDIAccessInitializer.h ('k') | Source/modules/webmidi/MIDIConnectionEvent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698