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

Unified Diff: content/shell/renderer/layout_test/blink_test_runner.h

Issue 1351393002: Make getBluetoothManualChooserEvents() asynchronous. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: Go back to the callback interface. Created 5 years, 3 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 | « content/shell/common/shell_messages.h ('k') | content/shell/renderer/layout_test/blink_test_runner.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/renderer/layout_test/blink_test_runner.h
diff --git a/content/shell/renderer/layout_test/blink_test_runner.h b/content/shell/renderer/layout_test/blink_test_runner.h
index a4b07ceaf9fb09b145319674ae18c5143086218d..6739bedac2059a731b49264dea7b2f3fe1c3978c 100644
--- a/content/shell/renderer/layout_test/blink_test_runner.h
+++ b/content/shell/renderer/layout_test/blink_test_runner.h
@@ -5,8 +5,10 @@
#ifndef CONTENT_SHELL_RENDERER_LAYOUT_TEST_BLINK_TEST_RUNNER_H_
#define CONTENT_SHELL_RENDERER_LAYOUT_TEST_BLINK_TEST_RUNNER_H_
+#include <deque>
#include <vector>
+#include "base/callback.h"
#include "base/files/file_path.h"
#include "base/memory/scoped_ptr.h"
#include "components/test_runner/test_preferences.h"
@@ -97,7 +99,9 @@ class BlinkTestRunner : public RenderViewObserver,
void SetDeviceColorProfile(const std::string& name) override;
void SetBluetoothMockDataSet(const std::string& name) override;
void SetBluetoothManualChooser() override;
- std::vector<std::string> GetBluetoothManualChooserEvents() override;
+ void GetBluetoothManualChooserEvents(
+ const base::Callback<void(const std::vector<std::string>&)>& callback)
+ override;
void SendBluetoothManualChooserEvent(const std::string& event,
const std::string& argument) override;
void SetGeofencingMockProvider(bool service_available) override;
@@ -158,6 +162,8 @@ class BlinkTestRunner : public RenderViewObserver,
void OnReset();
void OnNotifyDone();
void OnTryLeakDetection();
+ void OnReplyBluetoothManualChooserEvents(
+ const std::vector<std::string>& events);
// After finishing the test, retrieves the audio, text, and pixel dumps from
// the TestRunner library and sends them to the browser process.
@@ -177,6 +183,9 @@ class BlinkTestRunner : public RenderViewObserver,
std::vector<std::vector<PageState> > session_histories_;
std::vector<unsigned> current_entry_indexes_;
+ std::deque<base::Callback<void(const std::vector<std::string>&)>>
+ get_bluetooth_events_callbacks_;
+
bool is_main_window_;
bool focus_on_next_commit_;
« no previous file with comments | « content/shell/common/shell_messages.h ('k') | content/shell/renderer/layout_test/blink_test_runner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698