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 #include "chrome/browser/android/vr_shell/ui_scene_manager.h" | 5 #include "chrome/browser/android/vr_shell/ui_scene_manager.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
9 #include "chrome/browser/android/vr_shell/textures/close_button_texture.h" | 9 #include "chrome/browser/android/vr_shell/textures/close_button_texture.h" |
10 #include "chrome/browser/android/vr_shell/textures/ui_texture.h" | 10 #include "chrome/browser/android/vr_shell/textures/ui_texture.h" |
11 #include "chrome/browser/android/vr_shell/ui_elements/audio_capture_indicator.h" | 11 #include "chrome/browser/android/vr_shell/ui_elements/audio_capture_indicator.h" |
12 #include "chrome/browser/android/vr_shell/ui_elements/button.h" | 12 #include "chrome/browser/android/vr_shell/ui_elements/button.h" |
13 #include "chrome/browser/android/vr_shell/ui_elements/exit_warning.h" | 13 #include "chrome/browser/android/vr_shell/ui_elements/exit_warning.h" |
14 #include "chrome/browser/android/vr_shell/ui_elements/loading_indicator.h" | 14 #include "chrome/browser/android/vr_shell/ui_elements/loading_indicator.h" |
15 #include "chrome/browser/android/vr_shell/ui_elements/permanent_security_warning
.h" | 15 #include "chrome/browser/android/vr_shell/ui_elements/permanent_security_warning
.h" |
16 #include "chrome/browser/android/vr_shell/ui_elements/screen_capture_indicator.h
" | 16 #include "chrome/browser/android/vr_shell/ui_elements/screen_capture_indicator.h
" |
17 #include "chrome/browser/android/vr_shell/ui_elements/screen_dimmer.h" | 17 #include "chrome/browser/android/vr_shell/ui_elements/screen_dimmer.h" |
18 #include "chrome/browser/android/vr_shell/ui_elements/transient_security_warning
.h" | 18 #include "chrome/browser/android/vr_shell/ui_elements/transient_security_warning
.h" |
19 #include "chrome/browser/android/vr_shell/ui_elements/ui_element.h" | 19 #include "chrome/browser/android/vr_shell/ui_elements/ui_element.h" |
20 #include "chrome/browser/android/vr_shell/ui_elements/ui_element_debug_id.h" | 20 #include "chrome/browser/android/vr_shell/ui_elements/ui_element_debug_id.h" |
21 #include "chrome/browser/android/vr_shell/ui_elements/url_bar.h" | 21 #include "chrome/browser/android/vr_shell/ui_elements/url_bar.h" |
22 #include "chrome/browser/android/vr_shell/ui_elements/video_capture_indicator.h" | 22 #include "chrome/browser/android/vr_shell/ui_elements/video_capture_indicator.h" |
23 #include "chrome/browser/android/vr_shell/ui_scene.h" | 23 #include "chrome/browser/android/vr_shell/ui_scene.h" |
24 #include "chrome/browser/android/vr_shell/vr_browser_interface.h" | 24 #include "chrome/browser/android/vr_shell/vr_browser_interface.h" |
25 #include "chrome/browser/android/vr_shell/vr_shell.h" | |
26 | 25 |
27 namespace vr_shell { | 26 namespace vr_shell { |
28 | 27 |
29 namespace { | 28 namespace { |
30 | 29 |
31 static constexpr int kWarningTimeoutSeconds = 30; | 30 static constexpr int kWarningTimeoutSeconds = 30; |
32 static constexpr float kWarningDistance = 0.7; | 31 static constexpr float kWarningDistance = 0.7; |
33 static constexpr float kWarningAngleRadians = 16.3 * M_PI / 180.0; | 32 static constexpr float kWarningAngleRadians = 16.3 * M_PI / 180.0; |
34 static constexpr float kPermanentWarningHeight = 0.070f; | 33 static constexpr float kPermanentWarningHeight = 0.070f; |
35 static constexpr float kPermanentWarningWidth = 0.224f; | 34 static constexpr float kPermanentWarningWidth = 0.224f; |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
478 if (fullscreen_) | 477 if (fullscreen_) |
479 return ColorScheme::kModeFullscreen; | 478 return ColorScheme::kModeFullscreen; |
480 return ColorScheme::kModeNormal; | 479 return ColorScheme::kModeNormal; |
481 } | 480 } |
482 | 481 |
483 const ColorScheme& UiSceneManager::color_scheme() const { | 482 const ColorScheme& UiSceneManager::color_scheme() const { |
484 return ColorScheme::GetColorScheme(mode()); | 483 return ColorScheme::GetColorScheme(mode()); |
485 } | 484 } |
486 | 485 |
487 } // namespace vr_shell | 486 } // namespace vr_shell |
OLD | NEW |