| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include "base/utf_string_conversions.h" | 5 #include "base/utf_string_conversions.h" |
| 6 #include "ui/views/bubble/bubble_border.h" | 6 #include "ui/views/bubble/bubble_border.h" |
| 7 #include "ui/views/bubble/bubble_delegate.h" | 7 #include "ui/views/bubble/bubble_delegate.h" |
| 8 #include "ui/views/layout/fill_layout.h" | 8 #include "ui/views/layout/fill_layout.h" |
| 9 #include "ui/views/widget/widget.h" | |
| 10 #include "views/controls/label.h" | 9 #include "views/controls/label.h" |
| 10 #include "views/widget/widget.h" |
| 11 | 11 |
| 12 namespace aura_shell { | 12 namespace aura_shell { |
| 13 namespace examples { | 13 namespace examples { |
| 14 | 14 |
| 15 struct BubbleConfig { | 15 struct BubbleConfig { |
| 16 string16 label; | 16 string16 label; |
| 17 SkColor color; | 17 SkColor color; |
| 18 views::View* anchor_view; | 18 views::View* anchor_view; |
| 19 views::BubbleBorder::ArrowLocation arrow; | 19 views::BubbleBorder::ArrowLocation arrow; |
| 20 }; | 20 }; |
| (...skipping 20 matching lines...) Expand all Loading... |
| 41 config.color = SK_ColorWHITE; | 41 config.color = SK_ColorWHITE; |
| 42 config.anchor_view = anchor_view; | 42 config.anchor_view = anchor_view; |
| 43 config.arrow = views::BubbleBorder::TOP_LEFT; | 43 config.arrow = views::BubbleBorder::TOP_LEFT; |
| 44 ExampleBubbleDelegateView* bubble = new ExampleBubbleDelegateView(config); | 44 ExampleBubbleDelegateView* bubble = new ExampleBubbleDelegateView(config); |
| 45 views::BubbleDelegateView::CreateBubble(bubble); | 45 views::BubbleDelegateView::CreateBubble(bubble); |
| 46 bubble->Show(); | 46 bubble->Show(); |
| 47 } | 47 } |
| 48 | 48 |
| 49 } // namespace examples | 49 } // namespace examples |
| 50 } // namespace aura_shell | 50 } // namespace aura_shell |
| OLD | NEW |