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

Unified Diff: ui/views/controls/button/label_button_border.cc

Issue 2637383003: Change Painter factory functions to unique_ptr (Closed)
Patch Set: msw review Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/views/controls/button/label_button_border.h ('k') | ui/views/controls/button/md_text_button.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/button/label_button_border.cc
diff --git a/ui/views/controls/button/label_button_border.cc b/ui/views/controls/button/label_button_border.cc
index bf8b584272fa6e604d50eba0732da7af4e19c82b..b1ff3a56206352f4f20119941312ef841c2ffc04 100644
--- a/ui/views/controls/button/label_button_border.cc
+++ b/ui/views/controls/button/label_button_border.cc
@@ -183,8 +183,8 @@ Painter* LabelButtonAssetBorder::GetPainter(bool focused,
void LabelButtonAssetBorder::SetPainter(bool focused,
Button::ButtonState state,
- Painter* painter) {
- painters_[focused ? 1 : 0][state].reset(painter);
+ std::unique_ptr<Painter> painter) {
+ painters_[focused ? 1 : 0][state] = std::move(painter);
}
} // namespace views
« no previous file with comments | « ui/views/controls/button/label_button_border.h ('k') | ui/views/controls/button/md_text_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698