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

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

Issue 25039002: Always aligns text at vertically center (Textfield, Label). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Synced. Created 7 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ui/views/location_bar/content_setting_image_view.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 (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_CONTENT_SETTING_IMAGE_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_CONTENT_SETTING_IMAGE_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_CONTENT_SETTING_IMAGE_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_CONTENT_SETTING_IMAGE_VIEW_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "chrome/common/content_settings_types.h" 9 #include "chrome/common/content_settings_types.h"
10 #include "ui/gfx/animation/animation_delegate.h" 10 #include "ui/gfx/animation/animation_delegate.h"
(...skipping 21 matching lines...) Expand all
32 // The ContentSettingImageView displays an icon and optional text label for 32 // The ContentSettingImageView displays an icon and optional text label for
33 // various content settings affordances in the location bar (i.e. plugin 33 // various content settings affordances in the location bar (i.e. plugin
34 // blocking, geolocation). 34 // blocking, geolocation).
35 class ContentSettingImageView : public gfx::AnimationDelegate, 35 class ContentSettingImageView : public gfx::AnimationDelegate,
36 public views::View, 36 public views::View,
37 public views::WidgetObserver { 37 public views::WidgetObserver {
38 public: 38 public:
39 ContentSettingImageView(ContentSettingsType content_type, 39 ContentSettingImageView(ContentSettingsType content_type,
40 LocationBarView* parent, 40 LocationBarView* parent,
41 const gfx::FontList& font_list, 41 const gfx::FontList& font_list,
42 int font_y_offset,
43 SkColor text_color, 42 SkColor text_color,
44 SkColor parent_background_color); 43 SkColor parent_background_color);
45 virtual ~ContentSettingImageView(); 44 virtual ~ContentSettingImageView();
46 45
47 // Updates the decoration from the shown WebContents. 46 // Updates the decoration from the shown WebContents.
48 void UpdatePreLayout(content::WebContents* web_contents); 47 void UpdatePreLayout(content::WebContents* web_contents);
49 48
50 // Performs any updates which depend on the image having already been laid out 49 // Performs any updates which depend on the image having already been laid out
51 // by the owning LocationBarView. 50 // by the owning LocationBarView.
52 void UpdatePostLayout(content::WebContents* web_contents); 51 void UpdatePostLayout(content::WebContents* web_contents);
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 views::Label* text_label_; 97 views::Label* text_label_;
99 gfx::SlideAnimation slide_animator_; 98 gfx::SlideAnimation slide_animator_;
100 bool pause_animation_; 99 bool pause_animation_;
101 double pause_animation_state_; 100 double pause_animation_state_;
102 views::Widget* bubble_widget_; 101 views::Widget* bubble_widget_;
103 102
104 DISALLOW_COPY_AND_ASSIGN(ContentSettingImageView); 103 DISALLOW_COPY_AND_ASSIGN(ContentSettingImageView);
105 }; 104 };
106 105
107 #endif // CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_CONTENT_SETTING_IMAGE_VIEW_H_ 106 #endif // CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_CONTENT_SETTING_IMAGE_VIEW_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/location_bar/content_setting_image_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698