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

Side by Side Diff: chrome/test/base/test_browser_window.cc

Issue 2248873002: Convert WindowOpenDisposition to an enum class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 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
« no previous file with comments | « chrome/test/base/in_process_browser_test.cc ('k') | chrome/test/base/tracing_browsertest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/test/base/test_browser_window.h" 5 #include "chrome/test/base/test_browser_window.h"
6 6
7 #include "base/memory/ptr_util.h" 7 #include "base/memory/ptr_util.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 #include "chrome/browser/ui/browser_list.h" 9 #include "chrome/browser/ui/browser_list.h"
10 #include "chrome/browser/ui/browser_list_observer.h" 10 #include "chrome/browser/ui/browser_list_observer.h"
(...skipping 16 matching lines...) Expand all
27 27
28 28
29 // TestBrowserWindow::TestLocationBar ----------------------------------------- 29 // TestBrowserWindow::TestLocationBar -----------------------------------------
30 30
31 GURL TestBrowserWindow::TestLocationBar::GetDestinationURL() const { 31 GURL TestBrowserWindow::TestLocationBar::GetDestinationURL() const {
32 return GURL(); 32 return GURL();
33 } 33 }
34 34
35 WindowOpenDisposition 35 WindowOpenDisposition
36 TestBrowserWindow::TestLocationBar::GetWindowOpenDisposition() const { 36 TestBrowserWindow::TestLocationBar::GetWindowOpenDisposition() const {
37 return CURRENT_TAB; 37 return WindowOpenDisposition::CURRENT_TAB;
38 } 38 }
39 39
40 ui::PageTransition 40 ui::PageTransition
41 TestBrowserWindow::TestLocationBar::GetPageTransition() const { 41 TestBrowserWindow::TestLocationBar::GetPageTransition() const {
42 return ui::PAGE_TRANSITION_LINK; 42 return ui::PAGE_TRANSITION_LINK;
43 } 43 }
44 44
45 bool TestBrowserWindow::TestLocationBar::ShowPageActionPopup( 45 bool TestBrowserWindow::TestLocationBar::ShowPageActionPopup(
46 const extensions::Extension* extension, bool grant_active_tab) { 46 const extensions::Extension* extension, bool grant_active_tab) {
47 return false; 47 return false;
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 bool TestBrowserWindow::IsDownloadShelfVisible() const { 163 bool TestBrowserWindow::IsDownloadShelfVisible() const {
164 return false; 164 return false;
165 } 165 }
166 166
167 DownloadShelf* TestBrowserWindow::GetDownloadShelf() { 167 DownloadShelf* TestBrowserWindow::GetDownloadShelf() {
168 return &download_shelf_; 168 return &download_shelf_;
169 } 169 }
170 170
171 WindowOpenDisposition TestBrowserWindow::GetDispositionForPopupBounds( 171 WindowOpenDisposition TestBrowserWindow::GetDispositionForPopupBounds(
172 const gfx::Rect& bounds) { 172 const gfx::Rect& bounds) {
173 return NEW_POPUP; 173 return WindowOpenDisposition::NEW_POPUP;
174 } 174 }
175 175
176 FindBar* TestBrowserWindow::CreateFindBar() { 176 FindBar* TestBrowserWindow::CreateFindBar() {
177 return NULL; 177 return NULL;
178 } 178 }
179 179
180 web_modal::WebContentsModalDialogHost* 180 web_modal::WebContentsModalDialogHost*
181 TestBrowserWindow::GetWebContentsModalDialogHost() { 181 TestBrowserWindow::GetWebContentsModalDialogHost() {
182 return NULL; 182 return NULL;
183 } 183 }
(...skipping 26 matching lines...) Expand all
210 } 210 }
211 211
212 TestBrowserWindowOwner::~TestBrowserWindowOwner() { 212 TestBrowserWindowOwner::~TestBrowserWindowOwner() {
213 BrowserList::RemoveObserver(this); 213 BrowserList::RemoveObserver(this);
214 } 214 }
215 215
216 void TestBrowserWindowOwner::OnBrowserRemoved(Browser* browser) { 216 void TestBrowserWindowOwner::OnBrowserRemoved(Browser* browser) {
217 if (browser->window() == window_.get()) 217 if (browser->window() == window_.get())
218 delete this; 218 delete this;
219 } 219 }
OLDNEW
« no previous file with comments | « chrome/test/base/in_process_browser_test.cc ('k') | chrome/test/base/tracing_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698