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

Side by Side Diff: chrome/browser/ui/sync/tab_contents_wrapper_synced_tab_delegate.cc

Issue 8892011: Clean up TCW, make it solely a hub for 1:1 observer/helper objects. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 | Annotate | Revision Log
OLDNEW
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
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 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/prefs/prefs_tab_helper.cc ('k') | chrome/browser/ui/tab_contents/core_tab_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698