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/sessions/tab_restore_service_delegate_impl_ios.h" | 5 #include "ios/chrome/browser/sessions/tab_restore_service_delegate_impl_ios.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
59 | 59 |
60 sessions::LiveTab* TabRestoreServiceDelegateImplIOS::GetLiveTabAt( | 60 sessions::LiveTab* TabRestoreServiceDelegateImplIOS::GetLiveTabAt( |
61 int index) const { | 61 int index) const { |
62 return nullptr; | 62 return nullptr; |
63 } | 63 } |
64 | 64 |
65 sessions::LiveTab* TabRestoreServiceDelegateImplIOS::GetActiveLiveTab() const { | 65 sessions::LiveTab* TabRestoreServiceDelegateImplIOS::GetActiveLiveTab() const { |
66 return nullptr; | 66 return nullptr; |
67 } | 67 } |
68 | 68 |
69 // Not supported by iOS. | |
69 bool TabRestoreServiceDelegateImplIOS::IsTabPinned(int index) const { | 70 bool TabRestoreServiceDelegateImplIOS::IsTabPinned(int index) const { |
70 return false; | 71 return false; |
71 } | 72 } |
72 | 73 |
74 // Not supported by iOS. | |
75 const gfx::Rect TabRestoreServiceDelegateImplIOS::GetBounds() const { | |
76 return gfx::Rect(); | |
77 } | |
78 | |
79 // Not supported by iOS. | |
80 ui::WindowShowState TabRestoreServiceDelegateImplIOS::GetShowState() const { | |
81 return ui::SHOW_STATE_NORMAL; | |
82 } | |
83 | |
84 // Not supported by iOS. | |
85 std::string TabRestoreServiceDelegateImplIOS::GetWorkspace() const { | |
86 return ""; | |
sdefresne
2017/05/15 15:59:54
return std::string();
chrisha
2017/06/28 18:30:42
Done.
| |
87 } | |
88 | |
73 sessions::LiveTab* TabRestoreServiceDelegateImplIOS::AddRestoredTab( | 89 sessions::LiveTab* TabRestoreServiceDelegateImplIOS::AddRestoredTab( |
74 const std::vector<sessions::SerializedNavigationEntry>& navigations, | 90 const std::vector<sessions::SerializedNavigationEntry>& navigations, |
75 int tab_index, | 91 int tab_index, |
76 int selected_navigation, | 92 int selected_navigation, |
77 const std::string& extension_app_id, | 93 const std::string& extension_app_id, |
78 bool select, | 94 bool select, |
79 bool pin, | 95 bool pin, |
80 bool from_last_session, | 96 bool from_last_session, |
81 const sessions::PlatformSpecificTabData* tab_platform_data, | 97 const sessions::PlatformSpecificTabData* tab_platform_data, |
82 const std::string& user_agent_override) { | 98 const std::string& user_agent_override) { |
(...skipping 29 matching lines...) Expand all Loading... | |
112 Tab* tab = tab_model().currentTab; | 128 Tab* tab = tab_model().currentTab; |
113 [tab replaceHistoryWithNavigations:navigations | 129 [tab replaceHistoryWithNavigations:navigations |
114 currentIndex:selected_navigation]; | 130 currentIndex:selected_navigation]; |
115 return nullptr; | 131 return nullptr; |
116 } | 132 } |
117 | 133 |
118 void TabRestoreServiceDelegateImplIOS::CloseTab() { | 134 void TabRestoreServiceDelegateImplIOS::CloseTab() { |
119 WebStateList* web_state_list = [tab_model() webStateList]; | 135 WebStateList* web_state_list = [tab_model() webStateList]; |
120 web_state_list->CloseWebStateAt(web_state_list->active_index()); | 136 web_state_list->CloseWebStateAt(web_state_list->active_index()); |
121 } | 137 } |
OLD | NEW |