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

Side by Side Diff: chrome/browser/android/vr_shell/vr_shell.h

Issue 2572013003: Remove unnecessary threading concerns from VrMetricsHelper. (Closed)
Patch Set: Created 4 years 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
« no previous file with comments | « no previous file | chrome/browser/android/vr_shell/vr_shell.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 CHROME_BROWSER_ANDROID_VR_SHELL_VR_SHELL_H_ 5 #ifndef CHROME_BROWSER_ANDROID_VR_SHELL_VR_SHELL_H_
6 #define CHROME_BROWSER_ANDROID_VR_SHELL_VR_SHELL_H_ 6 #define CHROME_BROWSER_ANDROID_VR_SHELL_VR_SHELL_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 void SetShowingOverscrollGlow(bool showing_glow); 138 void SetShowingOverscrollGlow(bool showing_glow);
139 139
140 // content::WebContentsObserver implementation. All called on UI thread. 140 // content::WebContentsObserver implementation. All called on UI thread.
141 void RenderViewHostChanged(content::RenderViewHost* old_host, 141 void RenderViewHostChanged(content::RenderViewHost* old_host,
142 content::RenderViewHost* new_host) override; 142 content::RenderViewHost* new_host) override;
143 void MainFrameWasResized(bool width_changed) override; 143 void MainFrameWasResized(bool width_changed) override;
144 void WebContentsDestroyed() override; 144 void WebContentsDestroyed() override;
145 145
146 std::unique_ptr<UiInterface> html_interface_; 146 std::unique_ptr<UiInterface> html_interface_;
147 147
148 content::WebContents* main_contents_;
148 std::unique_ptr<VrCompositor> content_compositor_; 149 std::unique_ptr<VrCompositor> content_compositor_;
149 content::WebContents* main_contents_; 150 content::WebContents* ui_contents_;
150 std::unique_ptr<VrCompositor> ui_compositor_; 151 std::unique_ptr<VrCompositor> ui_compositor_;
151 content::WebContents* ui_contents_; 152
152 std::unique_ptr<VrWebContentsObserver> vr_web_contents_observer_; 153 std::unique_ptr<VrWebContentsObserver> vr_web_contents_observer_;
153 154
154 VrShellDelegate* delegate_ = nullptr; 155 VrShellDelegate* delegate_ = nullptr;
155 base::android::ScopedJavaGlobalRef<jobject> j_vr_shell_; 156 base::android::ScopedJavaGlobalRef<jobject> j_vr_shell_;
156 157
157 std::unique_ptr<VrInputManager> content_input_manager_; 158 std::unique_ptr<VrInputManager> content_input_manager_;
158 std::unique_ptr<VrInputManager> ui_input_manager_; 159 std::unique_ptr<VrInputManager> ui_input_manager_;
159 160 std::unique_ptr<VrMetricsHelper> metrics_helper_;
160 scoped_refptr<VrMetricsHelper> metrics_helper_;
161 161
162 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; 162 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_;
163 std::unique_ptr<base::Thread> gl_thread_; 163 std::unique_ptr<base::Thread> gl_thread_;
164 164
165 base::WeakPtrFactory<VrShell> weak_ptr_factory_; 165 base::WeakPtrFactory<VrShell> weak_ptr_factory_;
166 166
167 DISALLOW_COPY_AND_ASSIGN(VrShell); 167 DISALLOW_COPY_AND_ASSIGN(VrShell);
168 }; 168 };
169 169
170 bool RegisterVrShell(JNIEnv* env); 170 bool RegisterVrShell(JNIEnv* env);
171 171
172 } // namespace vr_shell 172 } // namespace vr_shell
173 173
174 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_VR_SHELL_H_ 174 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_VR_SHELL_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/android/vr_shell/vr_shell.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698