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

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

Issue 7670041: Add --use-more-webui runtime flag to toggle WebUI replacements for native dialogs. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Merge with trunk. Created 9 years, 3 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 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/browser.h" 5 #include "chrome/browser/ui/browser.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #include <shellapi.h> 9 #include <shellapi.h>
10 #endif // OS_WIN 10 #endif // OS_WIN
(...skipping 3096 matching lines...) Expand 10 before | Expand all | Expand 10 after
3107 BookmarkModel* model = profile()->GetBookmarkModel(); 3107 BookmarkModel* model = profile()->GetBookmarkModel();
3108 return (model && model->IsLoaded()) && 3108 return (model && model->IsLoaded()) &&
3109 tab_count() > 1 && 3109 tab_count() > 1 &&
3110 profile()->GetPrefs()->GetBoolean(prefs::kEditBookmarksEnabled); 3110 profile()->GetPrefs()->GetBoolean(prefs::kEditBookmarksEnabled);
3111 } 3111 }
3112 3112
3113 void Browser::BookmarkAllTabs() { 3113 void Browser::BookmarkAllTabs() {
3114 BookmarkModel* model = profile()->GetBookmarkModel(); 3114 BookmarkModel* model = profile()->GetBookmarkModel();
3115 DCHECK(model && model->IsLoaded()); 3115 DCHECK(model && model->IsLoaded());
3116 3116
3117 BookmarkEditor::EditDetails details; 3117 BookmarkEditor::EditDetails details =
3118 details.type = BookmarkEditor::EditDetails::NEW_FOLDER; 3118 BookmarkEditor::EditDetails::AddFolder(model->GetParentForNewNodes());
3119 bookmark_utils::GetURLsForOpenTabs(this, &(details.urls)); 3119 bookmark_utils::GetURLsForOpenTabs(this, &(details.urls));
3120 DCHECK(!details.urls.empty()); 3120 DCHECK(!details.urls.empty());
3121 3121
3122 BookmarkEditor::Show(window()->GetNativeHandle(), profile_, 3122 BookmarkEditor::Show(window()->GetNativeHandle(), profile_, details,
3123 model->GetParentForNewNodes(), details,
3124 BookmarkEditor::SHOW_TREE); 3123 BookmarkEditor::SHOW_TREE);
3125 } 3124 }
3126 3125
3127 bool Browser::CanCloseTab() const { 3126 bool Browser::CanCloseTab() const {
3128 TabCloseableStateWatcher* watcher = 3127 TabCloseableStateWatcher* watcher =
3129 g_browser_process->tab_closeable_state_watcher(); 3128 g_browser_process->tab_closeable_state_watcher();
3130 return !watcher || watcher->CanCloseTab(this); 3129 return !watcher || watcher->CanCloseTab(this);
3131 } 3130 }
3132 3131
3133 void Browser::ToggleUseVerticalTabs() { 3132 void Browser::ToggleUseVerticalTabs() {
(...skipping 2118 matching lines...) Expand 10 before | Expand all | Expand 10 after
5252 profile()->GetOriginalProfile()->GetProfileSyncService(); 5251 profile()->GetOriginalProfile()->GetProfileSyncService();
5253 if (service->HasSyncSetupCompleted()) 5252 if (service->HasSyncSetupCompleted())
5254 ShowOptionsTab(chrome::kSyncSetupSubPage); 5253 ShowOptionsTab(chrome::kSyncSetupSubPage);
5255 else 5254 else
5256 service->ShowLoginDialog(); 5255 service->ShowLoginDialog();
5257 } 5256 }
5258 5257
5259 void Browser::ToggleSpeechInput() { 5258 void Browser::ToggleSpeechInput() {
5260 GetSelectedTabContentsWrapper()->render_view_host()->ToggleSpeechInput(); 5259 GetSelectedTabContentsWrapper()->render_view_host()->ToggleSpeechInput();
5261 } 5260 }
OLDNEW
« no previous file with comments | « chrome/browser/sync/test/integration/bookmarks_helper.cc ('k') | chrome/browser/ui/browser_dialogs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698