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

Unified Diff: chrome/browser/android/vr_shell/textures/url_bar_texture.cc

Issue 2878543002: Refactor VR Shell Input. Locks input to click/scroll targets. (Closed)
Patch Set: Address comments Created 3 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
Index: chrome/browser/android/vr_shell/textures/url_bar_texture.cc
diff --git a/chrome/browser/android/vr_shell/textures/url_bar_texture.cc b/chrome/browser/android/vr_shell/textures/url_bar_texture.cc
index e1ca6cdded8dd237445e47b9de6caa59807acfd6..6671aa14ce0e4d259df04f1595766e908de17104 100644
--- a/chrome/browser/android/vr_shell/textures/url_bar_texture.cc
+++ b/chrome/browser/android/vr_shell/textures/url_bar_texture.cc
@@ -63,10 +63,6 @@ UrlBarTexture::UrlBarTexture() : security_level_(SecurityLevel::DANGEROUS) {}
UrlBarTexture::~UrlBarTexture() = default;
-void UrlBarTexture::SetHover(bool hover) {
- hover_ = hover;
-}
-
void UrlBarTexture::SetURL(const GURL& gurl) {
gurl_ = gurl;
}
@@ -98,7 +94,8 @@ void UrlBarTexture::Draw(SkCanvas* canvas, const gfx::Size& texture_size) {
SkVector left_corners[4] = {rounded_corner, {0, 0}, {0, 0}, rounded_corner};
round_rect.setRectRadii({0, 0, kHeight, kHeight}, left_corners);
SkPaint paint;
- paint.setColor(hover_ ? kBackgroundHover : kBackground);
+ paint.setColor((GetDrawFlags() & FLAG_HOVER) ? kBackgroundHover
+ : kBackground);
canvas->drawRRect(round_rect, paint);
// URL area.
« no previous file with comments | « chrome/browser/android/vr_shell/textures/url_bar_texture.h ('k') | chrome/browser/android/vr_shell/ui_elements/close_button.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698