Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(417)

Side by Side Diff: third_party/wayland-protocols/include/protocol/secure-output-unstable-v1-server-protocol.h

Issue 1804973003: third_party: Add secure_output_protocol target to wayland-protocols. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 /*
2 * Copyright 2016 The Chromium Authors.
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
10 *
11 * The above copyright notice and this permission notice (including the next
12 * paragraph) shall be included in all copies or substantial portions of the
13 * Software.
14 *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 * DEALINGS IN THE SOFTWARE.
22 */
23
24 #ifndef SECURE_OUTPUT_UNSTABLE_V1_SERVER_PROTOCOL_H
25 #define SECURE_OUTPUT_UNSTABLE_V1_SERVER_PROTOCOL_H
26
27 #ifdef __cplusplus
28 extern "C" {
29 #endif
30
31 #include <stdint.h>
32 #include <stddef.h>
33 #include "wayland-server.h"
34
35 struct wl_client;
36 struct wl_resource;
37
38 struct wl_surface;
39 struct zwp_secure_output_v1;
40 struct zwp_security_v1;
41
42 extern const struct wl_interface zwp_secure_output_v1_interface;
43 extern const struct wl_interface zwp_security_v1_interface;
44
45 #ifndef ZWP_SECURE_OUTPUT_V1_ERROR_ENUM
46 #define ZWP_SECURE_OUTPUT_V1_ERROR_ENUM
47 enum zwp_secure_output_v1_error {
48 ZWP_SECURE_OUTPUT_V1_ERROR_SECURITY_EXISTS = 0,
49 };
50 #endif /* ZWP_SECURE_OUTPUT_V1_ERROR_ENUM */
51
52 /**
53 * zwp_secure_output_v1 - secure output
54 * @destroy: unbind from the secure output interface
55 * @get_security: extend surface interface for security
56 *
57 * The global interface exposing secure output capabilities is used to
58 * instantiate an interface extension for a wl_surface object. This
59 * extended interface will then allow surfaces to be marked as as only
60 * visible on secure outputs.
61 */
62 struct zwp_secure_output_v1_interface {
63 /**
64 * destroy - unbind from the secure output interface
65 *
66 * Informs the server that the client will not be using this
67 * protocol object anymore. This does not affect any other objects,
68 * security objects included.
69 */
70 void (*destroy)(struct wl_client *client,
71 struct wl_resource *resource);
72 /**
73 * get_security - extend surface interface for security
74 * @id: the new security interface id
75 * @surface: the surface
76 *
77 * Instantiate an interface extension for the given wl_surface to
78 * provide surface security. If the given wl_surface already has a
79 * security object associated, the security_exists protocol error
80 * is raised.
81 */
82 void (*get_security)(struct wl_client *client,
83 struct wl_resource *resource,
84 uint32_t id,
85 struct wl_resource *surface);
86 };
87
88
89 /**
90 * zwp_security_v1 - security interface to a wl_surface
91 * @destroy: remove security from the surface
92 * @only_visible_on_secure_output: set the only visible on secure output
93 * state
94 *
95 * An additional interface to a wl_surface object, which allows the
96 * client to specify that a surface should not appear in screenshots or be
97 * visible on non-secure outputs.
98 *
99 * If the wl_surface associated with the security object is destroyed, the
100 * security object becomes inert.
101 *
102 * If the security object is destroyed, the security state is removed from
103 * the wl_surface. The change will be applied on the next
104 * wl_surface.commit.
105 */
106 struct zwp_security_v1_interface {
107 /**
108 * destroy - remove security from the surface
109 *
110 * The associated wl_surface's security state is removed. The
111 * change is applied on the next wl_surface.commit.
112 */
113 void (*destroy)(struct wl_client *client,
114 struct wl_resource *resource);
115 /**
116 * only_visible_on_secure_output - set the only visible on secure
117 * output state
118 *
119 * Constrain visibility of wl_surface contents to secure outputs.
120 * See wp_secure_output for the description.
121 *
122 * The only visible on secure output state is double-buffered
123 * state, and will be applied on the next wl_surface.commit.
124 */
125 void (*only_visible_on_secure_output)(struct wl_client *client,
126 struct wl_resource *resource);
127 };
128
129
130 #ifdef __cplusplus
131 }
132 #endif
133
134 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698