summaryrefslogtreecommitdiffstats
path: root/chrome/browser/browser.cc
diff options
context:
space:
mode:
authorbeng@google.com <beng@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-24 18:25:11 +0000
committerbeng@google.com <beng@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-24 18:25:11 +0000
commita0e073f2fb72c20c64326ce47ba5f2149007d26d (patch)
tree4e63d1b3d11678d0d1d73e72a8bf1a1ea44fed67 /chrome/browser/browser.cc
parent9052745343f2a8a231150977cfad3afec687daf1 (diff)
downloadchromium_src-a0e073f2fb72c20c64326ce47ba5f2149007d26d.zip
chromium_src-a0e073f2fb72c20c64326ce47ba5f2149007d26d.tar.gz
chromium_src-a0e073f2fb72c20c64326ce47ba5f2149007d26d.tar.bz2
Make the window icon the app icon by default for popups and app windows unless the page specifies a favicon. This ensures that we don't show the default favicon for the window icon. (This is only appropriate for tab icons).
Also make sure popup windows opened from app windows are themselves app windows (and don't show the URL bar) B=1031854 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1293 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser.cc')
-rw-r--r--chrome/browser/browser.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc
index cfb7250..2cc725d 100644
--- a/chrome/browser/browser.cc
+++ b/chrome/browser/browser.cc
@@ -1632,6 +1632,7 @@ void Browser::OpenURLOffTheRecord(Profile* profile, const GURL& url) {
// static
std::wstring Browser::ComputePopupTitle(const GURL& url,
const std::wstring& title) {
+ DCHECK(!g_browser_process->IsUsingNewFrames());
std::wstring result(title);
FormatTitleForDisplay(&result);
return result;
@@ -1655,8 +1656,10 @@ void Browser::ConvertToTabbedBrowser() {
void Browser::BuildPopupWindow(TabContents* source,
TabContents* new_contents,
const gfx::Rect& initial_pos) {
- Browser* browser = new Browser(initial_pos, SW_SHOWNORMAL, profile_,
- BrowserType::BROWSER, std::wstring());
+ BrowserType::Type type =
+ type_ == BrowserType::APPLICATION ? type_ : BrowserType::BROWSER;
+ Browser* browser = new Browser(initial_pos, SW_SHOWNORMAL, profile_, type,
+ std::wstring());
browser->AddNewContents(source, new_contents,
NEW_FOREGROUND_TAB, gfx::Rect(), true);