| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/files/file_path.h" | 6 #include "base/files/file_path.h" |
| 7 #include "base/macros.h" |
| 7 #include "base/path_service.h" | 8 #include "base/path_service.h" |
| 8 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
| 9 #include "chrome/browser/chrome_notification_types.h" | 10 #include "chrome/browser/chrome_notification_types.h" |
| 10 #include "chrome/browser/ui/browser.h" | 11 #include "chrome/browser/ui/browser.h" |
| 11 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 12 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
| 12 #include "chrome/test/base/in_process_browser_test.h" | 13 #include "chrome/test/base/in_process_browser_test.h" |
| 13 #include "chrome/test/base/ui_test_utils.h" | 14 #include "chrome/test/base/ui_test_utils.h" |
| 14 #include "content/public/browser/notification_observer.h" | 15 #include "content/public/browser/notification_observer.h" |
| 15 #include "content/public/browser/notification_service.h" | 16 #include "content/public/browser/notification_service.h" |
| 16 #include "content/public/browser/notification_types.h" | 17 #include "content/public/browser/notification_types.h" |
| (...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 main_lost_focus = true; | 171 main_lost_focus = true; |
| 171 if (status == "\"popup-got-focus\"") | 172 if (status == "\"popup-got-focus\"") |
| 172 popup_got_focus = true; | 173 popup_got_focus = true; |
| 173 if (main_lost_focus && popup_got_focus) | 174 if (main_lost_focus && popup_got_focus) |
| 174 break; | 175 break; |
| 175 } | 176 } |
| 176 | 177 |
| 177 // The popup should be focused now. | 178 // The popup should be focused now. |
| 178 EXPECT_EQ(popup, browser()->tab_strip_model()->GetActiveWebContents()); | 179 EXPECT_EQ(popup, browser()->tab_strip_model()->GetActiveWebContents()); |
| 179 } | 180 } |
| OLD | NEW |