ash_interfaces.cc 781 B

123456789101112131415161718192021222324252627
  1. // Copyright 2019 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #include "ash/public/ash_interfaces.h"
  5. #include <utility>
  6. #include "ash/display/cros_display_config.h"
  7. #include "ash/shell.h"
  8. #include "ash/tray_action/tray_action.h"
  9. namespace ash {
  10. void BindCrosDisplayConfigController(
  11. mojo::PendingReceiver<crosapi::mojom::CrosDisplayConfigController>
  12. receiver) {
  13. if (Shell::HasInstance())
  14. Shell::Get()->cros_display_config()->BindReceiver(std::move(receiver));
  15. }
  16. void BindTrayAction(mojo::PendingReceiver<mojom::TrayAction> receiver) {
  17. if (Shell::HasInstance())
  18. Shell::Get()->tray_action()->BindReceiver(std::move(receiver));
  19. }
  20. } // namespace ash