summaryrefslogtreecommitdiffstats
path: root/ui/views/painter.cc
diff options
context:
space:
mode:
authortfarina <tfarina@chromium.org>2015-01-08 13:34:25 -0800
committerCommit bot <commit-bot@chromium.org>2015-01-08 21:35:20 +0000
commitc999097cef4e2ae05ed554bbc4b85d64928c992d (patch)
tree4fdfa22e33cb74e04156d0341f32b0c37942bc8e /ui/views/painter.cc
parent8de079a1603cb64121e9c11b0a8556ce39df02e1 (diff)
downloadchromium_src-c999097cef4e2ae05ed554bbc4b85d64928c992d.zip
chromium_src-c999097cef4e2ae05ed554bbc4b85d64928c992d.tar.gz
chromium_src-c999097cef4e2ae05ed554bbc4b85d64928c992d.tar.bz2
ui/views: Cleanup usage of scoped_ptr.
* Return nullptr whenever possible. * Use make_scoped_ptr() when possible (less typing/noise). Entries found with the following command line: $ git grep -E '(=|\breturn)\s*scoped_ptr<.*?>([^)]+)' ui/views BUG=None R=sky@chromium.org Review URL: https://codereview.chromium.org/809903005 Cr-Commit-Position: refs/heads/master@{#310603}
Diffstat (limited to 'ui/views/painter.cc')
-rw-r--r--ui/views/painter.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/ui/views/painter.cc b/ui/views/painter.cc
index 56dedb1..42db547 100644
--- a/ui/views/painter.cc
+++ b/ui/views/painter.cc
@@ -272,20 +272,20 @@ Painter* Painter::CreateImageGridPainter(const int image_ids[]) {
// static
scoped_ptr<Painter> Painter::CreateDashedFocusPainter() {
- return scoped_ptr<Painter>(new DashedFocusPainter(gfx::Insets())).Pass();
+ return make_scoped_ptr(new DashedFocusPainter(gfx::Insets()));
}
// static
scoped_ptr<Painter> Painter::CreateDashedFocusPainterWithInsets(
const gfx::Insets& insets) {
- return scoped_ptr<Painter>(new DashedFocusPainter(insets)).Pass();
+ return make_scoped_ptr(new DashedFocusPainter(insets));
}
// static
scoped_ptr<Painter> Painter::CreateSolidFocusPainter(
SkColor color,
const gfx::Insets& insets) {
- return scoped_ptr<Painter>(new SolidFocusPainter(color, insets)).Pass();
+ return make_scoped_ptr(new SolidFocusPainter(color, insets));
}
// HorizontalPainter ----------------------------------------------------------