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

Unified Diff: components/test_runner/mock_web_midi_accessor.h

Issue 1852603002: Replacing most of web_task.h with base::Closure + base::WeakPtrFactory. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move-mocks-to-test-runner
Patch Set: Rebasing... Created 4 years, 8 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
Index: components/test_runner/mock_web_midi_accessor.h
diff --git a/components/test_runner/mock_web_midi_accessor.h b/components/test_runner/mock_web_midi_accessor.h
index 661329aa609e6a66a689dde355d3730d5dd7cac3..8728291e84032ae3b0684ca38c90bdc464008d30 100644
--- a/components/test_runner/mock_web_midi_accessor.h
+++ b/components/test_runner/mock_web_midi_accessor.h
@@ -8,7 +8,7 @@
#include <stddef.h>
#include "base/macros.h"
-#include "components/test_runner/web_task.h"
+#include "base/memory/weak_ptr.h"
#include "third_party/WebKit/public/platform/modules/webmidi/WebMIDIAccessor.h"
namespace blink {
@@ -32,14 +32,14 @@ class MockWebMIDIAccessor : public blink::WebMIDIAccessor {
size_t length,
double timestamp) override;
- // WebTask related methods
- WebTaskList* mutable_task_list() { return &task_list_; }
-
private:
+ void ReportStartedSession(bool success);
+
blink::WebMIDIAccessorClient* client_;
- WebTaskList task_list_;
TestInterfaces* interfaces_;
+ base::WeakPtrFactory<MockWebMIDIAccessor> weak_factory_;
+
DISALLOW_COPY_AND_ASSIGN(MockWebMIDIAccessor);
};
« no previous file with comments | « components/test_runner/mock_web_media_stream_center.cc ('k') | components/test_runner/mock_web_midi_accessor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698