| 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 #include "chrome/browser/ui/libgtkui/unity_service.h" | 5 #include "chrome/browser/ui/libgtkui/unity_service.h" |
| 6 | 6 |
| 7 #include <dlfcn.h> | 7 #include <dlfcn.h> |
| 8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| 11 #include <string> | 11 #include <string> |
| 12 | 12 |
| 13 #include "base/environment.h" | 13 #include "base/environment.h" |
| 14 #include "base/nix/xdg_util.h" | 14 #include "base/nix/xdg_util.h" |
| 15 #include "chrome/browser/ui/libgtkui/gtk2_util.h" | 15 #include "chrome/browser/ui/libgtkui/gtk_util.h" |
| 16 | 16 |
| 17 // Unity data typedefs. | 17 // Unity data typedefs. |
| 18 typedef struct _UnityInspector UnityInspector; | 18 typedef struct _UnityInspector UnityInspector; |
| 19 typedef UnityInspector* (*unity_inspector_get_default_func)(void); | 19 typedef UnityInspector* (*unity_inspector_get_default_func)(void); |
| 20 typedef gboolean (*unity_inspector_get_unity_running_func) | 20 typedef gboolean (*unity_inspector_get_unity_running_func) |
| 21 (UnityInspector* self); | 21 (UnityInspector* self); |
| 22 | 22 |
| 23 typedef struct _UnityLauncherEntry UnityLauncherEntry; | 23 typedef struct _UnityLauncherEntry UnityLauncherEntry; |
| 24 typedef UnityLauncherEntry* (*unity_launcher_entry_get_for_desktop_id_func) | 24 typedef UnityLauncherEntry* (*unity_launcher_entry_get_for_desktop_id_func) |
| 25 (const gchar* desktop_id); | 25 (const gchar* desktop_id); |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 void SetProgressFraction(float percentage) { | 137 void SetProgressFraction(float percentage) { |
| 138 EnsureMethodsLoaded(); | 138 EnsureMethodsLoaded(); |
| 139 if (chrome_entry && entry_set_progress && entry_set_progress_visible) { | 139 if (chrome_entry && entry_set_progress && entry_set_progress_visible) { |
| 140 entry_set_progress(chrome_entry, percentage); | 140 entry_set_progress(chrome_entry, percentage); |
| 141 entry_set_progress_visible(chrome_entry, | 141 entry_set_progress_visible(chrome_entry, |
| 142 percentage > 0.0 && percentage < 1.0); | 142 percentage > 0.0 && percentage < 1.0); |
| 143 } | 143 } |
| 144 } | 144 } |
| 145 | 145 |
| 146 } // namespace unity | 146 } // namespace unity |
| OLD | NEW |