Commit 722058c2 authored by Jae Hoon Kim's avatar Jae Hoon Kim Committed by Commit Bot

Use system_api constants and fixed TODOs

The fix of multiple cycles of progress is at chromium:1926650.

Bug: chromium:1026443
Test: ./out/Default/unit_tests --gtest_filter=DlcserviceClientTest.*
Change-Id: I280d8c81041342feeb2a4701b689cae4922a5497
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1930470
Commit-Queue: Jae Hoon Kim <kimjae@chromium.org>
Auto-Submit: Jae Hoon Kim <kimjae@chromium.org>
Reviewed-by: default avatarSteven Bennetts <stevenjb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#718267}
parent 9256783c
......@@ -37,8 +37,6 @@ namespace chromeos {
namespace {
const char kOnInstallStatus[] = "OnInstallStatus";
DlcserviceClient* g_instance = nullptr;
class DlcserviceErrorResponseHandler {
......@@ -181,11 +179,8 @@ class DlcserviceClientImpl : public DlcserviceClient {
dlcservice_proxy_ = bus->GetObjectProxy(
dlcservice::kDlcServiceServiceName,
dbus::ObjectPath(dlcservice::kDlcServiceServicePath));
// TODO(kimjae): Use from cros_system_api the const once sync'ed for
// kOnInstallStatus as dlcservice::kOnInstallStatus and delete the
// definition of kOnInstallStatus.
dlcservice_proxy_->ConnectToSignal(
dlcservice::kDlcServiceInterface, kOnInstallStatus,
dlcservice::kDlcServiceInterface, dlcservice::kOnInstallStatusSignal,
base::BindRepeating(&DlcserviceClientImpl::OnInstallStatus,
weak_ptr_factory_.GetWeakPtr()),
base::BindOnce(&DlcserviceClientImpl::OnInstallStatusConnected,
......@@ -239,10 +234,6 @@ class DlcserviceClientImpl : public DlcserviceClient {
SendCompleted(install_status);
break;
case dlcservice::Status::RUNNING: {
// TODO(kimjae): Currently, update_engine delegate's two actions.
// Specifically the Download action and Post Install Runner action,
// which means that progress will go from 0 -> 1 two complete cycles.
// This can be easily handled either here or inside dlcservice daemon.
SendProgress(install_status);
// Need to return here since we don't want to try starting another
// pending install from the queue (would waste time checking).
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment