OLD | NEW |
1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium OS 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 "update_engine/dbus_service.h" | 5 #include "update_engine/dbus_service.h" |
6 #include <string> | 6 #include <string> |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "update_engine/marshal.glibmarshal.h" | 8 #include "update_engine/marshal.glibmarshal.h" |
9 | 9 |
10 using std::string; | 10 using std::string; |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 gchar* omaha_url, | 52 gchar* omaha_url, |
53 GError **error) { | 53 GError **error) { |
54 const string update_app_version = app_version ? app_version : ""; | 54 const string update_app_version = app_version ? app_version : ""; |
55 const string update_omaha_url = omaha_url ? omaha_url : ""; | 55 const string update_omaha_url = omaha_url ? omaha_url : ""; |
56 LOG(INFO) << "Attempt update: app_version=\"" << update_app_version << "\" " | 56 LOG(INFO) << "Attempt update: app_version=\"" << update_app_version << "\" " |
57 << "omaha_url=\"" << update_omaha_url << "\""; | 57 << "omaha_url=\"" << update_omaha_url << "\""; |
58 self->update_attempter_->CheckForUpdate(app_version, omaha_url); | 58 self->update_attempter_->CheckForUpdate(app_version, omaha_url); |
59 return TRUE; | 59 return TRUE; |
60 } | 60 } |
61 | 61 |
62 gboolean update_engine_service_check_for_update(UpdateEngineService* self, | |
63 GError **error) { | |
64 self->update_attempter_->CheckForUpdate("", ""); | |
65 return TRUE; | |
66 } | |
67 | |
68 gboolean update_engine_service_get_status(UpdateEngineService* self, | 62 gboolean update_engine_service_get_status(UpdateEngineService* self, |
69 int64_t* last_checked_time, | 63 int64_t* last_checked_time, |
70 double* progress, | 64 double* progress, |
71 gchar** current_operation, | 65 gchar** current_operation, |
72 gchar** new_version, | 66 gchar** new_version, |
73 int64_t* new_size, | 67 int64_t* new_size, |
74 GError **error) { | 68 GError **error) { |
75 string current_op; | 69 string current_op; |
76 string new_version_str; | 70 string new_version_str; |
77 | 71 |
(...skipping 27 matching lines...) Expand all Loading... |
105 g_signal_emit(self, | 99 g_signal_emit(self, |
106 status_update_signal, | 100 status_update_signal, |
107 0, | 101 0, |
108 last_checked_time, | 102 last_checked_time, |
109 progress, | 103 progress, |
110 current_operation, | 104 current_operation, |
111 new_version, | 105 new_version, |
112 new_size); | 106 new_size); |
113 return TRUE; | 107 return TRUE; |
114 } | 108 } |
OLD | NEW |