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

Side by Side Diff: chrome/browser/ui/cocoa/location_bar/bubble_decoration.h

Issue 2102853002: [Mac][Material Design] Adjust (i) and lock Omnibox icons. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 5 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/ui/cocoa/location_bar/bubble_decoration.mm » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_COCOA_LOCATION_BAR_BUBBLE_DECORATION_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_LOCATION_BAR_BUBBLE_DECORATION_H_
6 #define CHROME_BROWSER_UI_COCOA_LOCATION_BAR_BUBBLE_DECORATION_H_ 6 #define CHROME_BROWSER_UI_COCOA_LOCATION_BAR_BUBBLE_DECORATION_H_
7 7
8 #import <Cocoa/Cocoa.h> 8 #import <Cocoa/Cocoa.h>
9 9
10 #include "base/gtest_prod_util.h" 10 #include "base/gtest_prod_util.h"
(...skipping 10 matching lines...) Expand all
21 BubbleDecoration(); 21 BubbleDecoration();
22 ~BubbleDecoration() override; 22 ~BubbleDecoration() override;
23 23
24 // Setup the drawing parameters. 24 // Setup the drawing parameters.
25 NSImage* GetImage(); 25 NSImage* GetImage();
26 virtual NSColor* GetBackgroundBorderColor() = 0; 26 virtual NSColor* GetBackgroundBorderColor() = 0;
27 void SetImage(NSImage* image); 27 void SetImage(NSImage* image);
28 void SetLabel(NSString* label); 28 void SetLabel(NSString* label);
29 void SetTextColor(NSColor* text_color); 29 void SetTextColor(NSColor* text_color);
30 void SetFont(NSFont* font); 30 void SetFont(NSFont* font);
31 void SetBaselineOffset(CGFloat offset); 31 void SetRetinaBaselineOffset(CGFloat offset);
32 virtual ui::NinePartImageIds GetBubbleImageIds() = 0; 32 virtual ui::NinePartImageIds GetBubbleImageIds() = 0;
33 33
34 // Implement |LocationBarDecoration|. 34 // Implement |LocationBarDecoration|.
35 CGFloat GetWidthForSpace(CGFloat width) override; 35 CGFloat GetWidthForSpace(CGFloat width) override;
36 void DrawInFrame(NSRect frame, NSView* control_view) override; 36 void DrawInFrame(NSRect frame, NSView* control_view) override;
37 void DrawWithBackgroundInFrame(NSRect background_frame, 37 void DrawWithBackgroundInFrame(NSRect background_frame,
38 NSRect frame, 38 NSRect frame,
39 NSView* control_view) override; 39 NSView* control_view) override;
40 NSFont* GetFont() const override; 40 NSFont* GetFont() const override;
41 41
(...skipping 13 matching lines...) Expand all
55 55
56 // Image drawn in the left side of the bubble. 56 // Image drawn in the left side of the bubble.
57 base::scoped_nsobject<NSImage> image_; 57 base::scoped_nsobject<NSImage> image_;
58 58
59 // Label to draw to right of image. Can be |nil|. 59 // Label to draw to right of image. Can be |nil|.
60 base::scoped_nsobject<NSString> label_; 60 base::scoped_nsobject<NSString> label_;
61 61
62 // Contains attribute for drawing |label_|. 62 // Contains attribute for drawing |label_|.
63 base::scoped_nsobject<NSMutableDictionary> attributes_; 63 base::scoped_nsobject<NSMutableDictionary> attributes_;
64 64
65 // Contains any baseline adjustment for the text. 65 // Contains any Retina-only baseline adjustment for |label_|.
66 CGFloat baseline_offset_; 66 CGFloat retina_baseline_offset_;
67 67
68 DISALLOW_COPY_AND_ASSIGN(BubbleDecoration); 68 DISALLOW_COPY_AND_ASSIGN(BubbleDecoration);
69 }; 69 };
70 70
71 #endif // CHROME_BROWSER_UI_COCOA_LOCATION_BAR_BUBBLE_DECORATION_H_ 71 #endif // CHROME_BROWSER_UI_COCOA_LOCATION_BAR_BUBBLE_DECORATION_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/location_bar/bubble_decoration.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698