blob: 934d60c4713b7390b276d2a159714d444c09d8fc [file] [log] [blame]
// Copyright 2019 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "src/cobalt/bin/system-metrics/activity_listener.h"
#include <lib/syslog/cpp/macros.h>
#include <lib/trace/event.h>
namespace cobalt {
fidl::InterfaceHandle<fuchsia::ui::activity::Listener> ActivityListener::NewHandle(
async_dispatcher_t* dispatcher) {
return binding_.NewBinding(dispatcher);
}
void ActivityListener::OnStateChanged(fuchsia::ui::activity::State state, zx_time_t transition_time,
OnStateChangedCallback callback) {
state_update_callback_(state);
callback();
}
} // namespace cobalt