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

Unified Diff: chrome/browser/ui/browser_commands.cc

Issue 187443008: Elim Browser::AppType (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase and add non trusted type test Created 6 years, 9 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/browser_browsertest.cc ('k') | chrome/browser/ui/browser_navigator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/browser_commands.cc
diff --git a/chrome/browser/ui/browser_commands.cc b/chrome/browser/ui/browser_commands.cc
index 94d132ee620cffe22210800a049917dba702d94c..cb9c3378c98a83b6cb8d2954210d4910d3f8794d 100644
--- a/chrome/browser/ui/browser_commands.cc
+++ b/chrome/browser/ui/browser_commands.cc
@@ -666,8 +666,7 @@ WebContents* DuplicateTabAt(Browser* browser, int index) {
index + 1, contents_dupe, add_types);
} else {
Browser* new_browser = NULL;
- if (browser->is_app() &&
- !browser->is_type_popup()) {
+ if (browser->is_app() && browser->type() != Browser::TYPE_TABBED) {
new_browser = new Browser(
Browser::CreateParams::CreateForApp(browser->type(),
browser->app_name(),
@@ -1259,9 +1258,11 @@ void ConvertTabToAppWindow(Browser* browser,
browser->tab_strip_model()->DetachWebContentsAt(index);
Browser* app_browser = new Browser(
- Browser::CreateParams::CreateForApp(
- Browser::TYPE_POPUP, app_name, gfx::Rect(), browser->profile(),
- browser->host_desktop_type()));
+ Browser::CreateParams::CreateForApp(Browser::TYPE_TRUSTED_POPUP,
+ app_name,
+ gfx::Rect(),
+ browser->profile(),
+ browser->host_desktop_type()));
app_browser->tab_strip_model()->AppendWebContents(contents, true);
contents->GetMutableRendererPrefs()->can_accept_load_drops = false;
« no previous file with comments | « chrome/browser/ui/browser_browsertest.cc ('k') | chrome/browser/ui/browser_navigator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698