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

Side by Side Diff: ui/views/animation/button_ink_drop_delegate.h

Issue 1868363002: Replace scoped_ptr with std::unique_ptr in //ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scopedptrcc
Patch Set: scopedptrui: rebase-make_scoped_ptr 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_VIEWS_ANIMATION_BUTTON_INK_DROP_DELEGATE_H_ 5 #ifndef UI_VIEWS_ANIMATION_BUTTON_INK_DROP_DELEGATE_H_
6 #define UI_VIEWS_ANIMATION_BUTTON_INK_DROP_DELEGATE_H_ 6 #define UI_VIEWS_ANIMATION_BUTTON_INK_DROP_DELEGATE_H_
7 7
8 #include <memory>
9
8 #include "base/macros.h" 10 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "ui/events/event_handler.h" 11 #include "ui/events/event_handler.h"
11 #include "ui/gfx/geometry/point.h" 12 #include "ui/gfx/geometry/point.h"
12 #include "ui/views/animation/ink_drop_delegate.h" 13 #include "ui/views/animation/ink_drop_delegate.h"
13 #include "ui/views/views_export.h" 14 #include "ui/views/views_export.h"
14 15
15 namespace ui { 16 namespace ui {
16 class ScopedTargetHandler; 17 class ScopedTargetHandler;
17 } 18 }
18 19
19 namespace views { 20 namespace views {
(...skipping 20 matching lines...) Expand all
40 void OnAction(InkDropState state) override; 41 void OnAction(InkDropState state) override;
41 void SnapToActivated() override; 42 void SnapToActivated() override;
42 void SetHovered(bool is_hovered) override; 43 void SetHovered(bool is_hovered) override;
43 44
44 // ui::EventHandler: 45 // ui::EventHandler:
45 void OnMouseEvent(ui::MouseEvent* event) override; 46 void OnMouseEvent(ui::MouseEvent* event) override;
46 void OnGestureEvent(ui::GestureEvent* event) override; 47 void OnGestureEvent(ui::GestureEvent* event) override;
47 48
48 private: 49 private:
49 // An instance of ScopedTargetHandler allowing |this| to handle events. 50 // An instance of ScopedTargetHandler allowing |this| to handle events.
50 scoped_ptr<ui::ScopedTargetHandler> target_handler_; 51 std::unique_ptr<ui::ScopedTargetHandler> target_handler_;
51 52
52 // Parent InkDropHost (typically a View) that hosts the ink ripple animations. 53 // Parent InkDropHost (typically a View) that hosts the ink ripple animations.
53 InkDropHost* ink_drop_host_; 54 InkDropHost* ink_drop_host_;
54 55
55 // Location of the last ink drop triggering event in coordinate system of the 56 // Location of the last ink drop triggering event in coordinate system of the
56 // ctor argument |view|. 57 // ctor argument |view|.
57 gfx::Point last_ink_drop_location_; 58 gfx::Point last_ink_drop_location_;
58 59
59 // Animation controller for the ink drop ripple effect. 60 // Animation controller for the ink drop ripple effect.
60 scoped_ptr<InkDropAnimationController> ink_drop_animation_controller_; 61 std::unique_ptr<InkDropAnimationController> ink_drop_animation_controller_;
61 62
62 DISALLOW_COPY_AND_ASSIGN(ButtonInkDropDelegate); 63 DISALLOW_COPY_AND_ASSIGN(ButtonInkDropDelegate);
63 }; 64 };
64 65
65 } // namespace views 66 } // namespace views
66 67
67 #endif // UI_VIEWS_ANIMATION_BUTTON_INK_DROP_DELEGATE_H_ 68 #endif // UI_VIEWS_ANIMATION_BUTTON_INK_DROP_DELEGATE_H_
OLDNEW
« no previous file with comments | « ui/views/animation/bounds_animator_unittest.cc ('k') | ui/views/animation/flood_fill_ink_drop_animation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698