| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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_VIEWS_COREWM_TOOLTIP_AURA_H_ | 5 #ifndef UI_VIEWS_COREWM_TOOLTIP_AURA_H_ |
| 6 #define UI_VIEWS_COREWM_TOOLTIP_AURA_H_ | 6 #define UI_VIEWS_COREWM_TOOLTIP_AURA_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/views/corewm/tooltip.h" | 11 #include "ui/views/corewm/tooltip.h" |
| 11 #include "ui/views/widget/widget_observer.h" | 12 #include "ui/views/widget/widget_observer.h" |
| 12 | 13 |
| 13 namespace gfx { | 14 namespace gfx { |
| 14 class FontList; | 15 class FontList; |
| 15 class Size; | 16 class Size; |
| 16 } // namespace gfx | 17 } // namespace gfx |
| 17 | 18 |
| 18 namespace views { | 19 namespace views { |
| 19 | 20 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 44 const base::string16& tooltip_text, | 45 const base::string16& tooltip_text, |
| 45 const gfx::Point& location) override; | 46 const gfx::Point& location) override; |
| 46 void Show() override; | 47 void Show() override; |
| 47 void Hide() override; | 48 void Hide() override; |
| 48 bool IsVisible() override; | 49 bool IsVisible() override; |
| 49 | 50 |
| 50 // WidgetObserver: | 51 // WidgetObserver: |
| 51 void OnWidgetDestroying(Widget* widget) override; | 52 void OnWidgetDestroying(Widget* widget) override; |
| 52 | 53 |
| 53 // The view showing the tooltip. | 54 // The view showing the tooltip. |
| 54 scoped_ptr<TooltipView> tooltip_view_; | 55 std::unique_ptr<TooltipView> tooltip_view_; |
| 55 | 56 |
| 56 // The widget containing the tooltip. May be NULL. | 57 // The widget containing the tooltip. May be NULL. |
| 57 Widget* widget_; | 58 Widget* widget_; |
| 58 | 59 |
| 59 // The window we're showing the tooltip for. Never NULL and valid while | 60 // The window we're showing the tooltip for. Never NULL and valid while |
| 60 // showing. | 61 // showing. |
| 61 aura::Window* tooltip_window_; | 62 aura::Window* tooltip_window_; |
| 62 | 63 |
| 63 DISALLOW_COPY_AND_ASSIGN(TooltipAura); | 64 DISALLOW_COPY_AND_ASSIGN(TooltipAura); |
| 64 }; | 65 }; |
| 65 | 66 |
| 66 } // namespace corewm | 67 } // namespace corewm |
| 67 } // namespace views | 68 } // namespace views |
| 68 | 69 |
| 69 #endif // UI_VIEWS_COREWM_TOOLTIP_AURA_H_ | 70 #endif // UI_VIEWS_COREWM_TOOLTIP_AURA_H_ |
| OLD | NEW |