OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_INSTRUCTIONS_GTK_H_ | |
6 #define CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_INSTRUCTIONS_GTK_H_ | |
7 | |
8 #include "base/basictypes.h" | |
9 #include "base/compiler_specific.h" | |
10 #include "content/public/browser/notification_observer.h" | |
11 #include "content/public/browser/notification_registrar.h" | |
12 #include "ui/base/gtk/gtk_signal.h" | |
13 | |
14 typedef struct _GtkWidget GtkWidget; | |
15 class BookmarkBarInstructionsDelegate; | |
16 class GtkThemeService; | |
17 class Profile; | |
18 | |
19 class BookmarkBarInstructionsGtk : public content::NotificationObserver { | |
20 public: | |
21 BookmarkBarInstructionsGtk(BookmarkBarInstructionsDelegate* delegate, | |
22 Profile* profile); | |
23 | |
24 // Get the native widget. | |
25 GtkWidget* widget() const { return instructions_hbox_; } | |
26 | |
27 private: | |
28 // Overridden from content::NotificationObserver: | |
29 virtual void Observe(int type, | |
30 const content::NotificationSource& source, | |
31 const content::NotificationDetails& details) OVERRIDE; | |
32 | |
33 CHROMEGTK_CALLBACK_0(BookmarkBarInstructionsGtk, void, OnButtonClick); | |
34 | |
35 // Sets the correct color for |instructions_label_| and |instructions_link_|. | |
36 void UpdateColors(); | |
37 | |
38 BookmarkBarInstructionsDelegate* delegate_; | |
39 | |
40 Profile* profile_; | |
41 | |
42 GtkThemeService* theme_service_; | |
43 | |
44 // HBox that holds the the label and link of bookmark bar import promotion. | |
45 GtkWidget* instructions_hbox_; | |
46 GtkWidget* instructions_label_; | |
47 GtkWidget* instructions_link_; | |
48 | |
49 content::NotificationRegistrar registrar_; | |
50 | |
51 DISALLOW_COPY_AND_ASSIGN(BookmarkBarInstructionsGtk); | |
52 }; | |
53 | |
54 #endif // CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_INSTRUCTIONS_GTK_H_ | |
OLD | NEW |