OLD | NEW |
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 Loading... |
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 Loading... |
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 Loading... |
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 } |
OLD | NEW |