summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser.cc
diff options
context:
space:
mode:
authorpinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-17 18:54:23 +0000
committerpinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-17 18:54:23 +0000
commit500c9f12f3f90e82ad0108edbfd35fc499d5b21d (patch)
tree404dbec031f19f4ff608cf6114af9846c09d3a67 /chrome/browser/browser.cc
parentbdd546bcccfecdf50fb6c9becd7fdda1a4d29428 (diff)
downloadchromium_src-500c9f12f3f90e82ad0108edbfd35fc499d5b21d.zip
chromium_src-500c9f12f3f90e82ad0108edbfd35fc499d5b21d.tar.gz
chromium_src-500c9f12f3f90e82ad0108edbfd35fc499d5b21d.tar.bz2
Unstub some more of the Browser object, including the part that sets it as the delegate of the TabContents object. That allows page-load notifications to make their way through the browser UI layer. Hook up notification to Mac tab strip to set the title as it's changed.
Review URL: http://codereview.chromium.org/20429 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9892 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser.cc')
-rw-r--r--chrome/browser/browser.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc
index 59f6267..4c87134 100644
--- a/chrome/browser/browser.cc
+++ b/chrome/browser/browser.cc
@@ -1378,7 +1378,6 @@ bool Browser::RunUnloadListenerBeforeClosing(TabContents* contents) {
return false;
}
-#if defined(OS_WIN)
///////////////////////////////////////////////////////////////////////////////
// Browser, TabStripModelObserver implementation:
@@ -1391,6 +1390,7 @@ void Browser::TabInsertedAt(TabContents* contents,
SyncHistoryWithTabs(tabstrip_model_.GetIndexOfTabContents(contents));
+#if defined(OS_WIN)
// When a tab is dropped into a tab strip we need to make sure that the
// associated Find window is moved along with it. We therefore change the
// parent of the Find window (if the parent is already correctly set this
@@ -1400,6 +1400,7 @@ void Browser::TabInsertedAt(TabContents* contents,
WebContents* web_contents = contents->AsWebContents();
if (web_contents)
web_contents->view()->ReparentFindWindow(this);
+#endif
// Make sure the loading state is updated correctly, otherwise the throbber
// won't start if the page is loading.
@@ -1413,6 +1414,8 @@ void Browser::TabInsertedAt(TabContents* contents,
Source<TabContents>(contents));
}
+#if defined(OS_WIN)
+
void Browser::TabClosingAt(TabContents* contents, int index) {
NavigationController* controller = contents->controller();
DCHECK(controller);
@@ -1799,12 +1802,16 @@ void Browser::ConvertContentsToApplication(TabContents* contents) {
browser->window()->Show();
}
+#endif // OS_WIN
+
void Browser::ContentsStateChanged(TabContents* source) {
int index = tabstrip_model_.GetIndexOfTabContents(source);
if (index != TabStripModel::kNoTab)
tabstrip_model_.UpdateTabContentsStateAt(index);
}
+#if defined(OS_WIN)
+
bool Browser::ShouldDisplayURLField() {
return !IsApplication();
}