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 CHROME_BROWSER_UI_LIBGTK2UI_APP_INDICATOR_ICON_H_ | 5 #ifndef CHROME_BROWSER_UI_LIBGTKUI_APP_INDICATOR_ICON_H_ |
6 #define CHROME_BROWSER_UI_LIBGTK2UI_APP_INDICATOR_ICON_H_ | 6 #define CHROME_BROWSER_UI_LIBGTKUI_APP_INDICATOR_ICON_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
13 #include "base/nix/xdg_util.h" | 13 #include "base/nix/xdg_util.h" |
14 #include "chrome/browser/ui/libgtk2ui/gtk2_signal.h" | 14 #include "chrome/browser/ui/libgtkui/gtk2_signal.h" |
15 #include "ui/views/linux_ui/status_icon_linux.h" | 15 #include "ui/views/linux_ui/status_icon_linux.h" |
16 | 16 |
17 typedef struct _AppIndicator AppIndicator; | 17 typedef struct _AppIndicator AppIndicator; |
18 typedef struct _GtkWidget GtkWidget; | 18 typedef struct _GtkWidget GtkWidget; |
19 | 19 |
20 class SkBitmap; | 20 class SkBitmap; |
21 | 21 |
22 namespace gfx { | 22 namespace gfx { |
23 class ImageSkia; | 23 class ImageSkia; |
24 } | 24 } |
25 | 25 |
26 namespace ui { | 26 namespace ui { |
27 class MenuModel; | 27 class MenuModel; |
28 } | 28 } |
29 | 29 |
30 namespace libgtk2ui { | 30 namespace libgtkui { |
31 class AppIndicatorIconMenu; | 31 class AppIndicatorIconMenu; |
32 | 32 |
33 // Status icon implementation which uses libappindicator. | 33 // Status icon implementation which uses libappindicator. |
34 class AppIndicatorIcon : public views::StatusIconLinux { | 34 class AppIndicatorIcon : public views::StatusIconLinux { |
35 public: | 35 public: |
36 // The id uniquely identifies the new status icon from other chrome status | 36 // The id uniquely identifies the new status icon from other chrome status |
37 // icons. | 37 // icons. |
38 AppIndicatorIcon(std::string id, | 38 AppIndicatorIcon(std::string id, |
39 const gfx::ImageSkia& image, | 39 const gfx::ImageSkia& image, |
40 const base::string16& tool_tip); | 40 const base::string16& tool_tip); |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 ui::MenuModel* menu_model_; | 98 ui::MenuModel* menu_model_; |
99 | 99 |
100 base::FilePath temp_dir_; | 100 base::FilePath temp_dir_; |
101 int icon_change_count_; | 101 int icon_change_count_; |
102 | 102 |
103 base::WeakPtrFactory<AppIndicatorIcon> weak_factory_; | 103 base::WeakPtrFactory<AppIndicatorIcon> weak_factory_; |
104 | 104 |
105 DISALLOW_COPY_AND_ASSIGN(AppIndicatorIcon); | 105 DISALLOW_COPY_AND_ASSIGN(AppIndicatorIcon); |
106 }; | 106 }; |
107 | 107 |
108 } // namespace libgtk2ui | 108 } // namespace libgtkui |
109 | 109 |
110 #endif // CHROME_BROWSER_UI_LIBGTK2UI_APP_INDICATOR_ICON_H_ | 110 #endif // CHROME_BROWSER_UI_LIBGTKUI_APP_INDICATOR_ICON_H_ |
OLD | NEW |