| // Copyright 2023 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. |
| library fuchsia.hardware.display; |
| |
| using zx; |
| |
| /// Provider for display coordinators. |
| /// |
| /// The driver supports two simultaneous clients - a main client and a virtcon |
| /// client. In some cases, the provider service may provide access to only one or |
| /// the other; if the client tries to open the other then `ZX_ERR_NOT_SUPPORTED` will |
| /// be returned. |
| @discoverable |
| closed protocol Provider { |
| /// Opens a Virtcon client connection to the display coordinator. |
| /// |
| /// On success, `coordinator` will be bound to the display |
| /// coordinator, as the Virtcon client. |
| /// |
| /// Returns `ZX_ERR_ALREADY_BOUND` if the display coordinator already has a |
| /// connected Virtcon client. |
| @selector("OpenVirtconController") |
| strict OpenCoordinatorForVirtcon(resource struct { |
| coordinator server_end:Coordinator; |
| }) -> (struct { |
| s zx.Status; |
| }); |
| |
| /// Opens a main client connection to the display coordinator. |
| /// |
| /// On success, `coordinator` will be bound to the display |
| /// coordinator, as the main client. |
| /// |
| /// Returns `ZX_ERR_ALREADY_BOUND` if the display coordinator already has a |
| /// connected main client. |
| @selector("OpenController") |
| strict OpenCoordinatorForPrimary(resource struct { |
| coordinator server_end:Coordinator; |
| }) -> (struct { |
| s zx.Status; |
| }); |
| }; |