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

Unified Diff: chrome/browser/android/vr_shell/vr_shell.h

Issue 2960903002: VR: Use ToolbarModel to drive VR URL bar state. (Closed)
Patch Set: Update toolbar build file to include vector icons for Android. Created 3 years, 6 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 | « chrome/browser/android/vr_shell/vr_gl_thread.cc ('k') | chrome/browser/android/vr_shell/vr_shell.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/vr_shell/vr_shell.h
diff --git a/chrome/browser/android/vr_shell/vr_shell.h b/chrome/browser/android/vr_shell/vr_shell.h
index 26d1c4994b413418d8b92f057c52933164187a95..ebda2b3c9d6e361d1d72958314113371d6c197c3 100644
--- a/chrome/browser/android/vr_shell/vr_shell.h
+++ b/chrome/browser/android/vr_shell/vr_shell.h
@@ -17,6 +17,7 @@
#include "chrome/browser/android/vr_shell/ui_interface.h"
#include "chrome/browser/android/vr_shell/ui_unsupported_mode.h"
#include "chrome/browser/android/vr_shell/vr_controller_model.h"
+#include "chrome/browser/ui/toolbar/chrome_toolbar_model_delegate.h"
#include "content/public/browser/web_contents_observer.h"
#include "device/vr/android/gvr/cardboard_gamepad_data_provider.h"
#include "device/vr/android/gvr/gvr_delegate.h"
@@ -39,6 +40,7 @@ class WindowAndroid;
namespace vr_shell {
class AndroidUiGestureTarget;
+class ToolbarHelper;
class UiInterface;
class VrCompositor;
class VrGLThread;
@@ -62,7 +64,8 @@ class VrMetricsHelper;
// must only be used on the UI thread.
class VrShell : public device::GvrDelegate,
device::GvrGamepadDataProvider,
- device::CardboardGamepadDataProvider {
+ device::CardboardGamepadDataProvider,
+ public ChromeToolbarModelDelegate {
public:
VrShell(JNIEnv* env,
jobject obj,
@@ -175,6 +178,9 @@ class VrShell : public device::GvrDelegate,
void RegisterCardboardGamepadDataFetcher(
device::CardboardGamepadDataFetcher*) override;
+ // ChromeToolbarModelDelegate implementation.
+ content::WebContents* GetActiveWebContents() const override;
+
private:
~VrShell() override;
void WaitForGlThread();
@@ -221,9 +227,11 @@ class VrShell : public device::GvrDelegate,
scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_;
std::unique_ptr<VrGLThread> gl_thread_;
bool thread_started_ = false;
- UiInterface* ui_;
bool reprojected_rendering_;
+ UiInterface* ui_;
+ std::unique_ptr<ToolbarHelper> toolbar_;
+
jobject content_surface_ = nullptr;
bool taken_surface_ = false;
base::CancelableClosure poll_capturing_media_task_;
« no previous file with comments | « chrome/browser/android/vr_shell/vr_gl_thread.cc ('k') | chrome/browser/android/vr_shell/vr_shell.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698