OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef BLIMP_CLIENT_CORE_BLIMP_CLIENT_CONTEXT_IMPL_H_ | 5 #ifndef BLIMP_CLIENT_CORE_BLIMP_CLIENT_CONTEXT_IMPL_H_ |
6 #define BLIMP_CLIENT_CORE_BLIMP_CLIENT_CONTEXT_IMPL_H_ | 6 #define BLIMP_CLIENT_CORE_BLIMP_CLIENT_CONTEXT_IMPL_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
| 10 #include <unordered_map> |
10 | 11 |
11 #include "base/macros.h" | 12 #include "base/macros.h" |
12 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
13 #include "base/memory/weak_ptr.h" | 14 #include "base/memory/weak_ptr.h" |
14 #include "base/single_thread_task_runner.h" | 15 #include "base/single_thread_task_runner.h" |
15 #include "base/threading/thread.h" | 16 #include "base/threading/thread.h" |
16 #include "blimp/client/core/compositor/blob_image_serialization_processor.h" | 17 #include "blimp/client/core/compositor/blob_image_serialization_processor.h" |
17 #include "blimp/client/core/session/client_network_components.h" | 18 #include "blimp/client/core/session/client_network_components.h" |
18 #include "blimp/client/core/session/connection_status.h" | 19 #include "blimp/client/core/session/connection_status.h" |
19 #include "blimp/client/core/session/identity_source.h" | 20 #include "blimp/client/core/session/identity_source.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 std::unique_ptr<CompositorDependencies> compositor_dependencies); | 56 std::unique_ptr<CompositorDependencies> compositor_dependencies); |
56 ~BlimpClientContextImpl() override; | 57 ~BlimpClientContextImpl() override; |
57 | 58 |
58 // BlimpClientContext implementation. | 59 // BlimpClientContext implementation. |
59 void SetDelegate(BlimpClientContextDelegate* delegate) override; | 60 void SetDelegate(BlimpClientContextDelegate* delegate) override; |
60 std::unique_ptr<BlimpContents> CreateBlimpContents( | 61 std::unique_ptr<BlimpContents> CreateBlimpContents( |
61 gfx::NativeWindow window) override; | 62 gfx::NativeWindow window) override; |
62 void Connect() override; | 63 void Connect() override; |
63 void ConnectWithAssignment(const Assignment& assignment) override; | 64 void ConnectWithAssignment(const Assignment& assignment) override; |
64 | 65 |
| 66 // Creates a data object containing data about Blimp to be used for feedback. |
| 67 std::unordered_map<std::string, std::string> CreateFeedbackData(); |
| 68 |
65 protected: | 69 protected: |
66 // Returns the URL to use for connections to the assigner. Used to construct | 70 // Returns the URL to use for connections to the assigner. Used to construct |
67 // the AssignmentSource. | 71 // the AssignmentSource. |
68 virtual GURL GetAssignerURL(); | 72 virtual GURL GetAssignerURL(); |
69 | 73 |
70 // BlimpSettingsDelegate implementation. | 74 // BlimpSettingsDelegate implementation. |
71 IdentitySource* GetIdentitySource() override; | 75 IdentitySource* GetIdentitySource() override; |
72 ConnectionStatus* GetConnectionStatus() override; | 76 ConnectionStatus* GetConnectionStatus() override; |
73 | 77 |
74 private: | 78 private: |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 | 140 |
137 base::WeakPtrFactory<BlimpClientContextImpl> weak_factory_; | 141 base::WeakPtrFactory<BlimpClientContextImpl> weak_factory_; |
138 | 142 |
139 DISALLOW_COPY_AND_ASSIGN(BlimpClientContextImpl); | 143 DISALLOW_COPY_AND_ASSIGN(BlimpClientContextImpl); |
140 }; | 144 }; |
141 | 145 |
142 } // namespace client | 146 } // namespace client |
143 } // namespace blimp | 147 } // namespace blimp |
144 | 148 |
145 #endif // BLIMP_CLIENT_CORE_BLIMP_CLIENT_CONTEXT_IMPL_H_ | 149 #endif // BLIMP_CLIENT_CORE_BLIMP_CLIENT_CONTEXT_IMPL_H_ |
OLD | NEW |