OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "base/memory/scoped_ptr.h" | 6 #include "base/memory/scoped_ptr.h" |
7 #include "chrome/browser/ui/autofill/autofill_popup_controller_impl.h" | 7 #include "chrome/browser/ui/autofill/autofill_popup_controller_impl.h" |
8 #include "chrome/browser/ui/autofill/autofill_popup_view.h" | 8 #include "chrome/browser/ui/autofill/autofill_popup_view.h" |
9 #include "chrome/browser/ui/browser.h" | 9 #include "chrome/browser/ui/browser.h" |
10 #include "chrome/browser/ui/browser_window.h" | 10 #include "chrome/browser/ui/browser_window.h" |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 } | 90 } |
91 | 91 |
92 protected: | 92 protected: |
93 content::WebContents* web_contents_; | 93 content::WebContents* web_contents_; |
94 | 94 |
95 scoped_ptr<TestAutofillExternalDelegate> autofill_external_delegate_; | 95 scoped_ptr<TestAutofillExternalDelegate> autofill_external_delegate_; |
96 }; | 96 }; |
97 | 97 |
98 // Autofill UI isn't currently hidden on window move on Mac. | 98 // Autofill UI isn't currently hidden on window move on Mac. |
99 // http://crbug.com/180566 | 99 // http://crbug.com/180566 |
100 // This tests causes an assert on the Linux Precise (dbg) builder. | 100 #if !defined(OS_MACOSX) |
101 // http://crbug.com/180883 | |
102 #if !defined(OS_MACOSX) && !defined(OS_LINUX) | |
103 IN_PROC_BROWSER_TEST_F(AutofillPopupControllerBrowserTest, | 101 IN_PROC_BROWSER_TEST_F(AutofillPopupControllerBrowserTest, |
104 HidePopupOnWindowConfiguration) { | 102 HidePopupOnWindowConfiguration) { |
105 autofill::GenerateTestAutofillPopup(autofill_external_delegate_.get()); | 103 autofill::GenerateTestAutofillPopup(autofill_external_delegate_.get()); |
106 | 104 |
107 EXPECT_FALSE(autofill_external_delegate_->popup_hidden()); | 105 EXPECT_FALSE(autofill_external_delegate_->popup_hidden()); |
108 | 106 |
109 // Resize the window, which should cause the popup to hide. | 107 // Resize the window, which should cause the popup to hide. |
110 gfx::Rect new_bounds = browser()->window()->GetBounds() - gfx::Vector2d(1, 1); | 108 gfx::Rect new_bounds = browser()->window()->GetBounds() - gfx::Vector2d(1, 1); |
111 browser()->window()->SetBounds(new_bounds); | 109 browser()->window()->SetBounds(new_bounds); |
112 | 110 |
113 autofill_external_delegate_->WaitForPopupHidden(); | 111 autofill_external_delegate_->WaitForPopupHidden(); |
114 EXPECT_TRUE(autofill_external_delegate_->popup_hidden()); | 112 EXPECT_TRUE(autofill_external_delegate_->popup_hidden()); |
115 } | 113 } |
116 #endif // !defined(OS_MACOSX) && !defined(OS_LINUX) | 114 #endif // !defined(OS_MACOSX) |
OLD | NEW |