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

Side by Side Diff: ui/native_theme/native_theme_mac.h

Issue 1831883002: Use sk_sp-based shader creation APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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 | « ui/native_theme/native_theme_base.cc ('k') | ui/native_theme/native_theme_mac.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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 UI_NATIVE_THEME_NATIVE_THEME_MAC_H_ 5 #ifndef UI_NATIVE_THEME_NATIVE_THEME_MAC_H_
6 #define UI_NATIVE_THEME_NATIVE_THEME_MAC_H_ 6 #define UI_NATIVE_THEME_NATIVE_THEME_MAC_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "ui/native_theme/native_theme_base.h" 9 #include "ui/native_theme/native_theme_base.h"
10 #include "ui/native_theme/native_theme_export.h" 10 #include "ui/native_theme/native_theme_export.h"
(...skipping 15 matching lines...) Expand all
26 SkCanvas* canvas, 26 SkCanvas* canvas,
27 const gfx::Size& size, 27 const gfx::Size& size,
28 const MenuBackgroundExtraParams& menu_background) const override; 28 const MenuBackgroundExtraParams& menu_background) const override;
29 void PaintMenuItemBackground( 29 void PaintMenuItemBackground(
30 SkCanvas* canvas, 30 SkCanvas* canvas,
31 State state, 31 State state,
32 const gfx::Rect& rect, 32 const gfx::Rect& rect,
33 const MenuItemExtraParams& menu_item) const override; 33 const MenuItemExtraParams& menu_item) const override;
34 34
35 // Creates a shader appropriate for painting the background of a button. 35 // Creates a shader appropriate for painting the background of a button.
36 static skia::RefPtr<SkShader> GetButtonBackgroundShader( 36 static sk_sp<SkShader> GetButtonBackgroundShader(State state, int height);
37 State state,
38 int height);
39 37
40 private: 38 private:
41 NativeThemeMac(); 39 NativeThemeMac();
42 ~NativeThemeMac() override; 40 ~NativeThemeMac() override;
43 41
44 DISALLOW_COPY_AND_ASSIGN(NativeThemeMac); 42 DISALLOW_COPY_AND_ASSIGN(NativeThemeMac);
45 }; 43 };
46 44
47 } // namespace ui 45 } // namespace ui
48 46
49 #endif // UI_NATIVE_THEME_NATIVE_THEME_MAC_H_ 47 #endif // UI_NATIVE_THEME_NATIVE_THEME_MAC_H_
OLDNEW
« no previous file with comments | « ui/native_theme/native_theme_base.cc ('k') | ui/native_theme/native_theme_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698