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

Side by Side Diff: chrome/browser/android/vr_shell/textures/url_bar_texture.h

Issue 2872773002: VR: Render the current URL and security level on the URL bar. (Closed)
Patch Set: Revert the inclusion of the lock icon; will re-add when moved to UI. 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/android/vr_shell/textures/url_bar_texture.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 #ifndef CHROME_BROWSER_ANDROID_VR_SHELL_TEXTURES_URL_BAR_TEXTURE_H_ 5 #ifndef CHROME_BROWSER_ANDROID_VR_SHELL_TEXTURES_URL_BAR_TEXTURE_H_
6 #define CHROME_BROWSER_ANDROID_VR_SHELL_TEXTURES_URL_BAR_TEXTURE_H_ 6 #define CHROME_BROWSER_ANDROID_VR_SHELL_TEXTURES_URL_BAR_TEXTURE_H_
7 7
8 #include "chrome/browser/android/vr_shell/textures/ui_texture.h" 8 #include "chrome/browser/android/vr_shell/textures/ui_texture.h"
9 9
10 #include "url/gurl.h" 10 #include "url/gurl.h"
11 11
12 namespace vr_shell { 12 namespace vr_shell {
13 13
14 class UrlBarTexture : public UiTexture { 14 class UrlBarTexture : public UiTexture {
15 public: 15 public:
16 UrlBarTexture(); 16 UrlBarTexture();
17 ~UrlBarTexture() override; 17 ~UrlBarTexture() override;
18 gfx::Size GetPreferredTextureSize(int width) const override; 18 gfx::Size GetPreferredTextureSize(int width) const override;
19 gfx::SizeF GetDrawnSize() const override; 19 gfx::SizeF GetDrawnSize() const override;
20 20
21 void SetHover(bool hover); 21 void SetHover(bool hover);
22 void SetURL(const GURL& gurl); 22 void SetURL(const GURL& gurl);
23 void SetSecurityLevel(int level);
23 24
24 private: 25 private:
25 void Draw(SkCanvas* canvas, const gfx::Size& texture_size) override; 26 void Draw(SkCanvas* canvas, const gfx::Size& texture_size) override;
26 float ToPixels(float meters) const; 27 float ToPixels(float meters) const;
27 28
28 gfx::SizeF size_; 29 gfx::SizeF size_;
29 bool hover_ = false; 30 bool hover_ = false;
31 int security_level_;
30 GURL gurl_; 32 GURL gurl_;
31 }; 33 };
32 34
33 } // namespace vr_shell 35 } // namespace vr_shell
34 36
35 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_TEXTURES_URL_BAR_TEXTURE_H_ 37 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_TEXTURES_URL_BAR_TEXTURE_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/android/vr_shell/textures/url_bar_texture.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698