OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 "ios/chrome/browser/ui/toolbar/test_toolbar_model_ios.h" | 5 #include "ios/chrome/browser/ui/toolbar/test_toolbar_model_ios.h" |
6 | 6 |
7 #include "components/toolbar/toolbar_model_impl.h" | 7 #include "components/toolbar/toolbar_model_impl.h" |
8 #import "ios/chrome/browser/tabs/tab.h" | 8 #import "ios/chrome/browser/tabs/tab.h" |
9 | 9 |
| 10 #if !defined(__has_feature) || !__has_feature(objc_arc) |
| 11 #error "This file requires ARC support." |
| 12 #endif |
| 13 |
10 TestToolbarModelIOS::TestToolbarModelIOS() | 14 TestToolbarModelIOS::TestToolbarModelIOS() |
11 : ToolbarModelIOS(), | 15 : ToolbarModelIOS(), |
12 is_loading_(FALSE), | 16 is_loading_(false), |
13 load_progress_fraction_(0.0), | 17 load_progress_fraction_(0.0), |
14 can_go_back_(FALSE), | 18 can_go_back_(false), |
15 can_go_forward_(FALSE), | 19 can_go_forward_(false), |
16 is_current_tab_native_page_(FALSE), | 20 is_current_tab_native_page_(false), |
17 is_current_tab_bookmarked_(FALSE) { | 21 is_current_tab_bookmarked_(false) { |
18 test_toolbar_model_.reset(new TestToolbarModel()); | 22 test_toolbar_model_.reset(new TestToolbarModel()); |
19 } | 23 } |
20 | 24 |
21 TestToolbarModelIOS::~TestToolbarModelIOS() {} | 25 TestToolbarModelIOS::~TestToolbarModelIOS() {} |
22 | 26 |
23 ToolbarModel* TestToolbarModelIOS::GetToolbarModel() { | 27 ToolbarModel* TestToolbarModelIOS::GetToolbarModel() { |
24 return test_toolbar_model_.get(); | 28 return test_toolbar_model_.get(); |
25 } | 29 } |
26 | 30 |
27 bool TestToolbarModelIOS::IsLoading() { | 31 bool TestToolbarModelIOS::IsLoading() { |
(...skipping 21 matching lines...) Expand all Loading... |
49 } | 53 } |
50 | 54 |
51 bool TestToolbarModelIOS::IsCurrentTabBookmarkedByUser() { | 55 bool TestToolbarModelIOS::IsCurrentTabBookmarkedByUser() { |
52 return is_current_tab_bookmarked_; | 56 return is_current_tab_bookmarked_; |
53 } | 57 } |
54 | 58 |
55 bool TestToolbarModelIOS::ShouldDisplayHintText() { | 59 bool TestToolbarModelIOS::ShouldDisplayHintText() { |
56 return false; | 60 return false; |
57 } | 61 } |
58 | 62 |
OLD | NEW |