| Index: tools/battor_agent/battor_agent_bin.cc
|
| diff --git a/tools/battor_agent/battor_agent_bin.cc b/tools/battor_agent/battor_agent_bin.cc
|
| index 6a70127bc47381338b85e2f3fd53cdbf3aa86186..0e9d970d1ef9827ce1584699c3044f5a5e6d8482 100644
|
| --- a/tools/battor_agent/battor_agent_bin.cc
|
| +++ b/tools/battor_agent/battor_agent_bin.cc
|
| @@ -200,6 +200,9 @@ class BattOrAgentBin : public BattOrAgent::Listener {
|
| }
|
|
|
| RecordClockSyncMarker(tokens[1]);
|
| + } else if (cmd == "Version") {
|
| + GetVersion();
|
| + PostRunNextCommand();
|
| } else if (cmd == "Exit" || std::cin.eof()) {
|
| ui_thread_message_loop_.task_runner()->PostTask(
|
| FROM_HERE, ui_thread_run_loop_.QuitClosure());
|
| @@ -215,6 +218,21 @@ class BattOrAgentBin : public BattOrAgent::Listener {
|
| base::Bind(&BattOrAgentBin::RunNextCommand, base::Unretained(this)));
|
| }
|
|
|
| + void GetVersion() {
|
| + std::cout << "WOOP WOOP";
|
| +// io_thread_.task_runner()->PostTask(
|
| +// FROM_HERE,
|
| +// base::Bind(&BattOrAgent::Version, base::Unretained(agent_.get())));
|
| + }
|
| +
|
| + void OnGetVersionComplete(const int version, BattOrError error) override {
|
| + if (error == BATTOR_ERROR_NONE)
|
| + std::cout << version << endl;
|
| + else
|
| + HandleError(error);
|
| + PostRunNextCommand();
|
| + }
|
| +
|
| void StartTracing() {
|
| io_thread_.task_runner()->PostTask(
|
| FROM_HERE,
|
|
|