OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #import "ios/shared/chrome/browser/ui/toolbar/toolbar_test_util.h" |
| 6 |
| 7 #if !defined(__has_feature) || !__has_feature(objc_arc) |
| 8 #error "This file requires ARC support." |
| 9 #endif |
| 10 |
| 11 ToolbarTestWebState::ToolbarTestWebState() : loading_progress_(0){}; |
| 12 |
| 13 double ToolbarTestWebState::GetLoadingProgress() const { |
| 14 return loading_progress_; |
| 15 } |
| 16 |
| 17 void ToolbarTestWebState::set_loading_progress(double loading_progress) { |
| 18 loading_progress_ = loading_progress; |
| 19 } |
| 20 |
| 21 ToolbarTestNavigationManager::ToolbarTestNavigationManager() |
| 22 : can_go_back_(false), can_go_forward_(false) {} |
| 23 |
| 24 bool ToolbarTestNavigationManager::CanGoBack() const { |
| 25 return can_go_back_; |
| 26 } |
| 27 |
| 28 bool ToolbarTestNavigationManager::CanGoForward() const { |
| 29 return can_go_forward_; |
| 30 } |
| 31 |
| 32 void ToolbarTestNavigationManager::set_can_go_back(bool can_go_back) { |
| 33 can_go_back_ = can_go_back; |
| 34 } |
| 35 |
| 36 void ToolbarTestNavigationManager::set_can_go_forward(bool can_go_forward) { |
| 37 can_go_forward_ = can_go_forward; |
| 38 } |
OLD | NEW |