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

Side by Side Diff: chrome/browser/ui/views/location_bar/icon_label_bubble_view.h

Issue 1915063003: Change ContentSettingImageView activation to key release (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2704
Patch Set: Created 4 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_UI_VIEWS_LOCATION_BAR_ICON_LABEL_BUBBLE_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_ICON_LABEL_BUBBLE_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_ICON_LABEL_BUBBLE_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_ICON_LABEL_BUBBLE_VIEW_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 // full-width view and can be used to animate the width of the view. 71 // full-width view and can be used to animate the width of the view.
72 virtual double WidthMultiplier() const; 72 virtual double WidthMultiplier() const;
73 73
74 // Returns true when animation is in progress and is shrinking. 74 // Returns true when animation is in progress and is shrinking.
75 virtual bool IsShrinking() const; 75 virtual bool IsShrinking() const;
76 76
77 // Returns the amount of horizontal space needed to draw the image and its 77 // Returns the amount of horizontal space needed to draw the image and its
78 // padding before the label. 78 // padding before the label.
79 virtual int GetImageAndPaddingWidth() const; 79 virtual int GetImageAndPaddingWidth() const;
80 80
81 // The view has been activated by a user gesture such as spacebar. Returns
82 // true if some handling was performed.
83 virtual bool OnActivate();
84
81 // views::View: 85 // views::View:
82 gfx::Size GetPreferredSize() const override; 86 gfx::Size GetPreferredSize() const override;
83 void Layout() override; 87 void Layout() override;
88 bool OnKeyReleased(const ui::KeyEvent& event) override;
84 void OnNativeThemeChanged(const ui::NativeTheme* native_theme) override; 89 void OnNativeThemeChanged(const ui::NativeTheme* native_theme) override;
85 void AddInkDropLayer(ui::Layer* ink_drop_layer) override; 90 void AddInkDropLayer(ui::Layer* ink_drop_layer) override;
86 void RemoveInkDropLayer(ui::Layer* ink_drop_layer) override; 91 void RemoveInkDropLayer(ui::Layer* ink_drop_layer) override;
87 std::unique_ptr<views::InkDropHover> CreateInkDropHover() const override; 92 std::unique_ptr<views::InkDropHover> CreateInkDropHover() const override;
88 SkColor GetInkDropBaseColor() const override; 93 SkColor GetInkDropBaseColor() const override;
89 94
90 const gfx::FontList& font_list() const { return label_->font_list(); } 95 const gfx::FontList& font_list() const { return label_->font_list(); }
91 96
92 SkColor GetParentBackgroundColor() const; 97 SkColor GetParentBackgroundColor() const;
93 98
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 // the native theme (so it responds to native theme updates). TODO(estade): 132 // the native theme (so it responds to native theme updates). TODO(estade):
128 // remove when MD is default. 133 // remove when MD is default.
129 SkColor parent_background_color_; 134 SkColor parent_background_color_;
130 135
131 bool should_show_background_; 136 bool should_show_background_;
132 137
133 DISALLOW_COPY_AND_ASSIGN(IconLabelBubbleView); 138 DISALLOW_COPY_AND_ASSIGN(IconLabelBubbleView);
134 }; 139 };
135 140
136 #endif // CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_ICON_LABEL_BUBBLE_VIEW_H_ 141 #endif // CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_ICON_LABEL_BUBBLE_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698