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

Side by Side Diff: chrome/browser/android/vr_shell/ui_scene_manager.cc

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, 5 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 unified diff | Download patch
OLDNEW
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"
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after
736 } 736 }
737 737
738 void UiSceneManager::OnExitPromptPrimaryButtonClicked() { 738 void UiSceneManager::OnExitPromptPrimaryButtonClicked() {
739 CloseExitPrompt(); 739 CloseExitPrompt();
740 } 740 }
741 741
742 void UiSceneManager::OnExitPromptSecondaryButtonClicked() { 742 void UiSceneManager::OnExitPromptSecondaryButtonClicked() {
743 OnUnsupportedMode(UiUnsupportedMode::kUnhandledPageInfo); 743 OnUnsupportedMode(UiUnsupportedMode::kUnhandledPageInfo);
744 } 744 }
745 745
746 void UiSceneManager::SetURL(const GURL& gurl) { 746 void UiSceneManager::SetToolbarState(const ToolbarState& state) {
747 url_bar_->SetURL(gurl); 747 url_bar_->SetToolbarState(state);
748 transient_url_bar_->SetURL(gurl); 748 transient_url_bar_->SetToolbarState(state);
749 }
750
751 void UiSceneManager::SetSecurityInfo(security_state::SecurityLevel level,
752 bool malware) {
753 url_bar_->SetSecurityInfo(level, malware);
754 transient_url_bar_->SetSecurityInfo(level, malware);
755 } 749 }
756 750
757 void UiSceneManager::SetLoading(bool loading) { 751 void UiSceneManager::SetLoading(bool loading) {
758 loading_indicator_->SetLoading(loading); 752 loading_indicator_->SetLoading(loading);
759 } 753 }
760 754
761 void UiSceneManager::SetLoadProgress(float progress) { 755 void UiSceneManager::SetLoadProgress(float progress) {
762 loading_indicator_->SetLoadProgress(progress); 756 loading_indicator_->SetLoadProgress(progress);
763 } 757 }
764 758
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
797 if (fullscreen_) 791 if (fullscreen_)
798 return ColorScheme::kModeFullscreen; 792 return ColorScheme::kModeFullscreen;
799 return ColorScheme::kModeNormal; 793 return ColorScheme::kModeNormal;
800 } 794 }
801 795
802 const ColorScheme& UiSceneManager::color_scheme() const { 796 const ColorScheme& UiSceneManager::color_scheme() const {
803 return ColorScheme::GetColorScheme(mode()); 797 return ColorScheme::GetColorScheme(mode());
804 } 798 }
805 799
806 } // namespace vr_shell 800 } // namespace vr_shell
OLDNEW
« no previous file with comments | « chrome/browser/android/vr_shell/ui_scene_manager.h ('k') | chrome/browser/android/vr_shell/vr_gl_thread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698