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

Unified Diff: chrome/browser/ui/views/omnibox/omnibox_view_views_browsertest.cc

Issue 262093014: Test that OmniboxViewViews has opaque background. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge and apply review feedback Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/views/omnibox/omnibox_view_views.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/omnibox/omnibox_view_views_browsertest.cc
diff --git a/chrome/browser/ui/views/omnibox/omnibox_view_views_browsertest.cc b/chrome/browser/ui/views/omnibox/omnibox_view_views_browsertest.cc
index acb72528c2c73cc3562358dccdf152b05c6c961f..6571a76cb4d08ef92d855f2a0a98fbfd51867809 100644
--- a/chrome/browser/ui/views/omnibox/omnibox_view_views_browsertest.cc
+++ b/chrome/browser/ui/views/omnibox/omnibox_view_views_browsertest.cc
@@ -233,3 +233,11 @@ IN_PROC_BROWSER_TEST_F(OmniboxViewViewsTest, SelectAllOnTabToFocus) {
EXPECT_TRUE(ui_test_utils::IsViewFocused(browser(), VIEW_ID_OMNIBOX));
EXPECT_TRUE(omnibox_view->IsSelectAll());
}
+
+IN_PROC_BROWSER_TEST_F(OmniboxViewViewsTest, BackgroundIsOpaque) {
+ // The omnibox text should be rendered on an opaque background. Otherwise,
+ // Chrome OS is unable to use subpixel rendering: http://crbug.com/233364
Peter Kasting 2014/05/07 18:48:51 Nit: I'd just change this whole line to "we can't
Daniel Erat 2014/05/07 23:12:36 Done.
+ OmniboxView* view = browser()->window()->GetLocationBar()->GetOmniboxView();
+ EXPECT_FALSE(static_cast<OmniboxViewViews*>(view)->GetRenderText()->
Peter Kasting 2014/05/07 18:48:51 Nit: We can avoid this cast if we use something li
Daniel Erat 2014/05/07 23:12:36 this seems to be the case. i've added in some ASSE
+ background_is_transparent());
+}
« no previous file with comments | « chrome/browser/ui/views/omnibox/omnibox_view_views.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698