| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_ |
| 7 | 7 |
| 8 #include "ui/views/bubble/bubble_delegate.h" | 8 #include "ui/views/bubble/bubble_delegate.h" |
| 9 #include "ui/views/controls/button/button.h" | |
| 10 #include "ui/views/controls/link_listener.h" | 9 #include "ui/views/controls/link_listener.h" |
| 11 | 10 |
| 12 class Browser; | 11 class Browser; |
| 13 class Profile; | |
| 14 | 12 |
| 15 class FirstRunBubble : public views::BubbleDelegateView, | 13 class FirstRunBubble : public views::BubbleDelegateView, |
| 16 public views::LinkListener { | 14 public views::LinkListener { |
| 17 public: | 15 public: |
| 18 // |browser| is the opening browser and is NULL in unittests. | 16 // |browser| is the opening browser and is NULL in unittests. |
| 19 static FirstRunBubble* ShowBubble(Browser* browser, | 17 static FirstRunBubble* ShowBubble(Browser* browser, views::View* anchor_view); |
| 20 Profile* profile, | |
| 21 views::View* anchor_view); | |
| 22 | 18 |
| 23 // views::BubbleDelegateView overrides: | 19 // views::BubbleDelegateView overrides: |
| 24 virtual gfx::Rect GetAnchorRect() OVERRIDE; | 20 virtual gfx::Rect GetAnchorRect() OVERRIDE; |
| 25 | 21 |
| 26 protected: | 22 protected: |
| 27 // views::BubbleDelegateView overrides: | 23 // views::BubbleDelegateView overrides: |
| 28 virtual void Init() OVERRIDE; | 24 virtual void Init() OVERRIDE; |
| 29 | 25 |
| 30 private: | 26 private: |
| 31 FirstRunBubble(Browser* browser, Profile* profile, views::View* anchor_view); | 27 FirstRunBubble(Browser* browser, views::View* anchor_view); |
| 32 virtual ~FirstRunBubble(); | 28 virtual ~FirstRunBubble(); |
| 33 | 29 |
| 34 // views::LinkListener overrides: | 30 // views::LinkListener overrides: |
| 35 virtual void LinkClicked(views::Link* source, int event_flags) OVERRIDE; | 31 virtual void LinkClicked(views::Link* source, int event_flags) OVERRIDE; |
| 36 | 32 |
| 37 Browser* browser_; | 33 Browser* browser_; |
| 38 Profile* profile_; | |
| 39 | 34 |
| 40 DISALLOW_COPY_AND_ASSIGN(FirstRunBubble); | 35 DISALLOW_COPY_AND_ASSIGN(FirstRunBubble); |
| 41 }; | 36 }; |
| 42 | 37 |
| 43 #endif // CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_ | 38 #endif // CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_ |
| OLD | NEW |