| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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_UI_ELEMENTS_URL_BAR_H_ | 5 #ifndef CHROME_BROWSER_ANDROID_VR_SHELL_UI_ELEMENTS_URL_BAR_H_ |
| 6 #define CHROME_BROWSER_ANDROID_VR_SHELL_UI_ELEMENTS_URL_BAR_H_ | 6 #define CHROME_BROWSER_ANDROID_VR_SHELL_UI_ELEMENTS_URL_BAR_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| 11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "base/time/time.h" | 12 #include "base/time/time.h" |
| 13 #include "chrome/browser/android/vr_shell/ui_elements/textured_element.h" | 13 #include "chrome/browser/android/vr_shell/ui_elements/textured_element.h" |
| 14 #include "chrome/browser/android/vr_shell/ui_unsupported_mode.h" | 14 #include "chrome/browser/android/vr_shell/ui_unsupported_mode.h" |
| 15 #include "components/security_state/core/security_state.h" | 15 #include "components/security_state/core/security_state.h" |
| 16 #include "url/gurl.h" | 16 #include "url/gurl.h" |
| 17 | 17 |
| 18 namespace vr_shell { | 18 namespace vr_shell { |
| 19 | 19 |
| 20 class UrlBarTexture; | 20 class UrlBarTexture; |
| 21 struct ToolbarState; | 21 struct ToolbarState; |
| 22 | 22 |
| 23 class UrlBar : public TexturedElement { | 23 class UrlBar : public TexturedElement { |
| 24 public: | 24 public: |
| 25 UrlBar(int preferred_width, | 25 UrlBar(int id, |
| 26 int preferred_width, |
| 26 const base::Callback<void()>& back_button_callback, | 27 const base::Callback<void()>& back_button_callback, |
| 27 const base::Callback<void()>& security_icon_callback, | 28 const base::Callback<void()>& security_icon_callback, |
| 28 const base::Callback<void(UiUnsupportedMode)>& failure_callback); | 29 const base::Callback<void(UiUnsupportedMode)>& failure_callback); |
| 29 ~UrlBar() override; | 30 ~UrlBar() override; |
| 30 | 31 |
| 31 void OnHoverEnter(const gfx::PointF& position) override; | 32 void OnHoverEnter(const gfx::PointF& position) override; |
| 32 void OnHoverLeave() override; | 33 void OnHoverLeave() override; |
| 33 void OnMove(const gfx::PointF& position) override; | 34 void OnMove(const gfx::PointF& position) override; |
| 34 void OnButtonDown(const gfx::PointF& position) override; | 35 void OnButtonDown(const gfx::PointF& position) override; |
| 35 void OnButtonUp(const gfx::PointF& position) override; | 36 void OnButtonUp(const gfx::PointF& position) override; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 55 bool security_region_down_ = false; | 56 bool security_region_down_ = false; |
| 56 base::TimeTicks last_begin_frame_time_; | 57 base::TimeTicks last_begin_frame_time_; |
| 57 base::TimeTicks last_update_time_; | 58 base::TimeTicks last_update_time_; |
| 58 | 59 |
| 59 DISALLOW_COPY_AND_ASSIGN(UrlBar); | 60 DISALLOW_COPY_AND_ASSIGN(UrlBar); |
| 60 }; | 61 }; |
| 61 | 62 |
| 62 } // namespace vr_shell | 63 } // namespace vr_shell |
| 63 | 64 |
| 64 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_UI_ELEMENTS_URL_BAR_H_ | 65 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_UI_ELEMENTS_URL_BAR_H_ |
| OLD | NEW |