OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/ui/sync/tab_contents_wrapper_synced_tab_delegate.h" | 5 #include "chrome/browser/ui/sync/tab_contents_wrapper_synced_tab_delegate.h" |
6 | 6 |
7 #include "content/browser/tab_contents/navigation_controller.h" | 7 #include "content/browser/tab_contents/navigation_controller.h" |
8 #include "content/browser/tab_contents/tab_contents.h" | 8 #include "content/browser/tab_contents/tab_contents.h" |
9 #include "chrome/browser/extensions/extension_tab_helper.h" | 9 #include "chrome/browser/extensions/extension_tab_helper.h" |
10 #include "chrome/browser/sessions/restore_tab_helper.h" | 10 #include "chrome/browser/sessions/restore_tab_helper.h" |
(...skipping 28 matching lines...) Expand all Loading... |
39 tab_contents_wrapper_->extension_tab_helper()->extension_app()); | 39 tab_contents_wrapper_->extension_tab_helper()->extension_app()); |
40 } | 40 } |
41 | 41 |
42 const std::string& TabContentsWrapperSyncedTabDelegate::GetExtensionAppId() | 42 const std::string& TabContentsWrapperSyncedTabDelegate::GetExtensionAppId() |
43 const { | 43 const { |
44 DCHECK(HasExtensionAppId()); | 44 DCHECK(HasExtensionAppId()); |
45 return tab_contents_wrapper_->extension_tab_helper()->extension_app()->id(); | 45 return tab_contents_wrapper_->extension_tab_helper()->extension_app()->id(); |
46 } | 46 } |
47 | 47 |
48 int TabContentsWrapperSyncedTabDelegate::GetCurrentEntryIndex() const { | 48 int TabContentsWrapperSyncedTabDelegate::GetCurrentEntryIndex() const { |
49 return tab_contents_wrapper_->controller().GetCurrentEntryIndex(); | 49 return tab_contents_wrapper_->tab_contents()->controller(). |
| 50 GetCurrentEntryIndex(); |
50 } | 51 } |
51 | 52 |
52 int TabContentsWrapperSyncedTabDelegate::GetEntryCount() const { | 53 int TabContentsWrapperSyncedTabDelegate::GetEntryCount() const { |
53 return tab_contents_wrapper_->controller().entry_count(); | 54 return tab_contents_wrapper_->tab_contents()->controller().entry_count(); |
54 } | 55 } |
55 | 56 |
56 int TabContentsWrapperSyncedTabDelegate::GetPendingEntryIndex() const { | 57 int TabContentsWrapperSyncedTabDelegate::GetPendingEntryIndex() const { |
57 return tab_contents_wrapper_->controller().pending_entry_index(); | 58 return tab_contents_wrapper_->tab_contents()->controller(). |
| 59 pending_entry_index(); |
58 } | 60 } |
59 | 61 |
60 NavigationEntry* TabContentsWrapperSyncedTabDelegate::GetPendingEntry() const { | 62 NavigationEntry* TabContentsWrapperSyncedTabDelegate::GetPendingEntry() const { |
61 return tab_contents_wrapper_->controller().pending_entry(); | 63 return tab_contents_wrapper_->tab_contents()->controller().pending_entry(); |
62 } | 64 } |
63 | 65 |
64 NavigationEntry* TabContentsWrapperSyncedTabDelegate::GetEntryAtIndex(int i) | 66 NavigationEntry* TabContentsWrapperSyncedTabDelegate::GetEntryAtIndex(int i) |
65 const { | 67 const { |
66 return tab_contents_wrapper_->controller().GetEntryAtIndex(i); | 68 return tab_contents_wrapper_->tab_contents()->controller().GetEntryAtIndex(i); |
67 } | 69 } |
68 | 70 |
69 NavigationEntry* TabContentsWrapperSyncedTabDelegate::GetActiveEntry() const { | 71 NavigationEntry* TabContentsWrapperSyncedTabDelegate::GetActiveEntry() const { |
70 return tab_contents_wrapper_->controller().GetActiveEntry(); | 72 return tab_contents_wrapper_->tab_contents()->controller().GetActiveEntry(); |
71 } | 73 } |
OLD | NEW |