Mir

Merge lp:~mir-team/mir/client-api-deprecation into lp:mir

Proposed by Alberto Aguirre
Status: Rejected
Rejected by: Daniel van Vugt
Proposed branch: lp:~mir-team/mir/client-api-deprecation
Merge into: lp:mir
Diff against target: 743 lines (+168/-8)
9 files modified
include/client/mir_toolkit/debug/surface.h (+8/-0)
include/client/mir_toolkit/mir_buffer_stream.h (+28/-5)
include/client/mir_toolkit/mir_connection.h (+25/-2)
include/client/mir_toolkit/mir_cursor_configuration.h (+3/-0)
include/client/mir_toolkit/mir_display_configuration.h (+6/-0)
include/client/mir_toolkit/mir_platform_message.h (+19/-0)
include/client/mir_toolkit/mir_screencast.h (+9/-0)
include/client/mir_toolkit/mir_surface.h (+69/-1)
include/core/mir_toolkit/common.h (+1/-0)
To merge this branch: bzr merge lp:~mir-team/mir/client-api-deprecation
Reviewer Review Type Date Requested Status
Daniel van Vugt Disapprove
Andreas Pokorny (community) Abstain
Brandon Schaefer (community) Approve
Mir CI Bot continuous-integration Needs Fixing
Review via email: mp+309364@code.launchpad.net

Commit message

DO NOT MERGE. At least not yet....

Description of the change

These are the client side APIs to deprecate as discussed during the sprint.

To post a comment you must log in.
Revision history for this message
Alberto Aguirre (albaguirre) wrote :

Alexandros pointed out that the getter APIs (such as mir_surface_get_state, mir_surface_get_type, etc) are just as racy as receiving the corresponding events, therefore should be left in.

Revision history for this message
Mir CI Bot (mir-ci-bot) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Brandon Schaefer (brandontschaefer) wrote :

lgtm

review: Approve
Revision history for this message
Kevin DuBois (kdub) wrote :

Looks like what we all worked on together, lgtm to me.

I'm ok with merging, as long as some items like:
+ * \deprecated Use "get_platform" extension
get captured in todo's in a document tracking the road to 1.0. (did we have a doc like that?)

Also, might be worth planning how the transition will work... eg, assuming no server breaks are needed for other reasons, something like this makes sense to me:
0.25 gets published
0.26 has all final header versions along with deprecations
0.27 removes deprecations/is the client api/abi break

Revision history for this message
Brandon Schaefer (brandontschaefer) wrote :

So we remember as well, need to go through the event api

Revision history for this message
Alberto Aguirre (albaguirre) wrote :

On mir_buffer_stream_set_scale and related, what is the alternative?

Are we still waiting on the outcome on this? https://docs.google.com/document/d/1Se4kbUHZNbgB9e3lrr3EQnVnQgSgFThyiBJ0MDgkZ0c/edit#heading=h.bo242kvnuqub

Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

> Looks like what we all worked on together, lgtm to me.
>
> I'm ok with merging, as long as some items like:
> + * \deprecated Use "get_platform" extension
> get captured in todo's in a document tracking the road to 1.0. (did we have a
> doc like that?)
>
> Also, might be worth planning how the transition will work... eg, assuming no
> server breaks are needed for other reasons, something like this makes sense to
> me:
> 0.25 gets published
> 0.26 has all final header versions along with deprecations
> 0.27 removes deprecations/is the client api/abi break

Surely that's 1.0?!

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Possibly don't deprecate 'get' functions and suggest events are an alternative. While libmirclient keeps such values cached, the most efficient and most convenient way to get at them is to 'get' from that cache. That avoids every toolkit having to re-implement the same cache for its getters.

Above the toolkit level, apps will sometimes want to get_some_attribute_of(surface) where they are not the surface owner and also don't see its events. So at the app level there is always a use case for needing getter functions in toolkits. And I don't think it's sensible to duplicate all the effort in every toolkit.

review: Needs Fixing
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

... unless on a case by case basis it can be shown that deprecating a getter makes it possible to completely remove caching of event values from libmirclient. You still have the duplication issue, but at least libmirclient would become smaller.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Regardless of the above comments, I would like to reiterate that not everyone wants to delete functions right now. I don't strongly endorse any deletions, and as we saw last week Gerry is also concerned. So whoever wants to delete client functions should also own all the corresponding downstream changes.

There are also changes unrelated to deprecation in this branch, so those could be proposed separately with less contention...

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Actually I'm experiencing the (lack of) getter problem right now and having to implement caching in my app for some attributes that don't have getters (visibility and surface output refresh rate).

Maybe what we need instead of getters is: e = mir_surface_get_last_event(surf, type)
That way all getters can indeed be replaced by the event query functions, but also each toolkit/app then doesn't have to duplicate too much code to write a getter for their own API.

Revision history for this message
Alberto Aguirre (albaguirre) wrote :

> Regardless of the above comments, I would like to reiterate that not everyone
> wants to delete functions right now.
That's why we will deprecate things first before deleting in 1.0

> I don't strongly endorse any deletions,
> and as we saw last week Gerry is also concerned.

Just confirmed with Gerry that deprecating first is ok as long as corresponding new apis that cover similar functionality are in place so the transition can be made.

>So whoever wants to delete
> client functions should also own all the corresponding downstream changes.
>
We have historically done so, I don't see why this time would be any different.

Revision history for this message
Andreas Pokorny (andreas-pokorny) wrote :

Hm from gdk/gtks perspective those removals are not problematic... I think some of the comments could point to the attribute change events..

review: Approve
Revision history for this message
Gerry Boland (gerboland) wrote :

> Regardless of the above comments, I would like to reiterate that not everyone
> wants to delete functions right now. I don't strongly endorse any deletions,
> and as we saw last week Gerry is also concerned. So whoever wants to delete
> client functions should also own all the corresponding downstream changes.

To clarify my perspective, I don't mind deprecations as long as I've had time to react to them - which for me means there is a release where the old api is deprecated but not removed, and the new API ready for use. As long as new api is a superset of the old api and gives me similar behaviour, I am not too concerned. If I find that is not the case, then we at least will have time to figure it out.

Revision history for this message
Andreas Pokorny (andreas-pokorny) wrote :

^ But will take a closer look with the current gtk+ ..

review: Abstain
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

OK, I abstain on the whole deprecation bit.

Just want to see the new bool return value and chrome changes proposed separately. They're unrelated to deprecation really. And the first one requires further logic changes anyway:
  bool mir_buffer_stream_get_graphics_region

review: Needs Fixing
Revision history for this message
Daniel van Vugt (vanvugt) :
review: Abstain
Revision history for this message
Daniel van Vugt (vanvugt) :
review: Needs Fixing
Revision history for this message
Daniel van Vugt (vanvugt) wrote :
Revision history for this message
Cemil Azizoglu (cemil-azizoglu) wrote :

79 + * \note TODO: Cleanup remove callback?

Yes we should.
----------------------

+ *
139 + * \note May need deprecation - Need a consistent API for high DPI scaling/destination size
140 + *
141 * \param [in] buffer_stream The buffer stream
142 * \param [in] scale The scale
143 - * \return A handle that can be passed to mir_wait_for
144 + * \return A handle that can be passed to mir_wait_for
145 */
146 MirWaitHandle *mir_buffer_stream_set_scale(MirBufferStream* buffer_stream, float scale);

At least the wait handle needs to be done away with.
----------------------

479 + * \note There is no implicit buffer stream creation. See mir_xxx to attach content.

You mean the "default" buffer stream.

Also, it should read "mir_surface_spec_add_render_surface() to attach content".
----------------------

488 + * \deprecated No replacement. This property is now part of the backing content
...

503 + * \deprecated No replacement. This property is now part of the backing content

More precisely, there is no default stream backing the surface.
----------------------

Revision history for this message
Brandon Schaefer (brandontschaefer) wrote :

This branch is a TODO pretty much of the talk we had during the sprint. Soo more of a working/branch of document i support.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Sounds like status should not be "Needs review" then.

Look to reviewing this one instead:
https://code.launchpad.net/~brandontschaefer/mir/first-round-deprecation/+merge/310024

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Alright, firstly Brandon's branch mentioned above replaced this one.

Secondly, he/we are in the process of proposing the various changes separately as smaller proposals, thus replacing Brandon's first-round-deprecation.

review: Disapprove
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I'm going to reject this because it's just a notepad. We can still refer to the notes even after it's rejected.

Unmerged revisions

3788. By Alberto Aguirre

Start deprecation of client side APIs

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'include/client/mir_toolkit/debug/surface.h'
--- include/client/mir_toolkit/debug/surface.h 2015-02-22 07:46:25 +0000
+++ include/client/mir_toolkit/debug/surface.h 2016-10-26 15:43:25 +0000
@@ -36,16 +36,23 @@
3636
37/**37/**
38 * Get the ID of the surface's current buffer (only useful for debug purposes)38 * Get the ID of the surface's current buffer (only useful for debug purposes)
39 *
40 * \deprecated Not useful anymore
41 *
39 * \pre The surface is valid42 * \pre The surface is valid
40 * \param [in] surface The surface43 * \param [in] surface The surface
41 * \return The internal buffer ID of the surface's current buffer.44 * \return The internal buffer ID of the surface's current buffer.
42 * This is the buffer that is currently being drawn to,45 * This is the buffer that is currently being drawn to,
43 * and would be returned by mir_surface_get_current_buffer.46 * and would be returned by mir_surface_get_current_buffer.
44 */47 */
48[[deprecated]]
45uint32_t mir_debug_surface_current_buffer_id(MirSurface *surface);49uint32_t mir_debug_surface_current_buffer_id(MirSurface *surface);
4650
47/**51/**
48 * Get the screen coordinates corresponding to a pair of surface coordinates52 * Get the screen coordinates corresponding to a pair of surface coordinates
53 *
54 * \deprecated Use the "debug_surface_coords" extension instead
55 *
49 * \pre The surface is valid56 * \pre The surface is valid
50 * \param [in] surface The surface57 * \param [in] surface The surface
51 * \param [in] x, y Surface coordinates to map to screen coordinates58 * \param [in] x, y Surface coordinates to map to screen coordinates
@@ -59,6 +66,7 @@
59 * This call will only be interesting for automated testing, where both the client66 * This call will only be interesting for automated testing, where both the client
60 * and shell state is known and constrained.67 * and shell state is known and constrained.
61 */68 */
69[[deprecated]]
62bool mir_debug_surface_coords_to_screen(MirSurface* surface,70bool mir_debug_surface_coords_to_screen(MirSurface* surface,
63 int x, int y,71 int x, int y,
64 int* screen_x, int* screen_y);72 int* screen_x, int* screen_y);
6573
=== modified file 'include/client/mir_toolkit/mir_buffer_stream.h'
--- include/client/mir_toolkit/mir_buffer_stream.h 2016-10-12 06:03:15 +0000
+++ include/client/mir_toolkit/mir_buffer_stream.h 2016-10-26 15:43:25 +0000
@@ -52,6 +52,8 @@
52/**52/**
53 * Create a new buffer stream. 53 * Create a new buffer stream.
54 *54 *
55 * \deprecated See mir_render_surface_create_buffer_stream
56 *
55 * For example, the resulting buffer stream may be used57 * For example, the resulting buffer stream may be used
56 * with mir_cursor_configuration_from_buffer_stream, 58 * with mir_cursor_configuration_from_buffer_stream,
57 * in order to post images to the system cursor.59 * in order to post images to the system cursor.
@@ -70,6 +72,7 @@
70 *72 *
71 * \return A handle that can be supplied to mir_wait_for73 * \return A handle that can be supplied to mir_wait_for
72 */74 */
75[[deprecated]]
73MirWaitHandle* mir_connection_create_buffer_stream(MirConnection *connection,76MirWaitHandle* mir_connection_create_buffer_stream(MirConnection *connection,
74 int width, int height,77 int width, int height,
75 MirPixelFormat format,78 MirPixelFormat format,
@@ -83,6 +86,8 @@
83 * mir_cursor_configuration_from_buffer_stream in order to post images 86 * mir_cursor_configuration_from_buffer_stream in order to post images
84 * to the system cursor.87 * to the system cursor.
85 *88 *
89 * \deprecated See mir_render_surface_create_buffer_stream_sync
90 *
86 * \param [in] connection A valid connection91 * \param [in] connection A valid connection
87 * \param [in] width Requested buffer width92 * \param [in] width Requested buffer width
88 * \param [in] height Requested buffer height93 * \param [in] height Requested buffer height
@@ -93,6 +98,7 @@
93 * \return The new buffer stream. This is guaranteed non-null, 98 * \return The new buffer stream. This is guaranteed non-null,
94 * but may be invalid in the case of error.99 * but may be invalid in the case of error.
95 */100 */
101[[deprecated]]
96MirBufferStream* mir_connection_create_buffer_stream_sync(MirConnection *connection,102MirBufferStream* mir_connection_create_buffer_stream_sync(MirConnection *connection,
97 int width, int height,103 int width, int height,
98 MirPixelFormat format,104 MirPixelFormat format,
@@ -100,6 +106,9 @@
100106
101/**107/**
102 * Release the supplied stream and any associated buffer. The returned wait108 * Release the supplied stream and any associated buffer. The returned wait
109 *
110 * \note TODO: Cleanup remove callback?
111 *
103 * handle remains valid until the connection to the server is released.112 * handle remains valid until the connection to the server is released.
104 * \warning callback could be called from another thread. You must do any113 * \warning callback could be called from another thread. You must do any
105 * locking appropriate to protect your data accessed in the114 * locking appropriate to protect your data accessed in the
@@ -140,17 +149,19 @@
140 * \return One of mir_platform_type_android or 149 * \return One of mir_platform_type_android or
141 * mir_platform_type_gbm150 * mir_platform_type_gbm
142 */151 */
143/// @cond152[[deprecated]]
144__attribute__ ((deprecated))
145/// @endcond
146MirPlatformType mir_buffer_stream_get_platform_type(MirBufferStream *stream);153MirPlatformType mir_buffer_stream_get_platform_type(MirBufferStream *stream);
147154
148/**155/**
149 * Retrieve the current buffer in "raw" representation.156 * Retrieve the current buffer in "raw" representation.
157 *
158 * \deprecated Replaced by a platform specific extension
159 *
150 * \pre The buffer stream is valid160 * \pre The buffer stream is valid
151 * \param [in] buffer_stream The buffer stream161 * \param [in] buffer_stream The buffer stream
152 * \param [out] buffer_package Structure to be populated162 * \param [out] buffer_package Structure to be populated
153 */163 */
164[[deprecated]]
154void mir_buffer_stream_get_current_buffer(MirBufferStream *buffer_stream,165void mir_buffer_stream_get_current_buffer(MirBufferStream *buffer_stream,
155 MirNativeBuffer **buffer_package);166 MirNativeBuffer **buffer_package);
156167
@@ -181,35 +192,47 @@
181192
182/**193/**
183 * Retrieve a buffer stream's graphics region194 * Retrieve a buffer stream's graphics region
195 *
184 * \warning Depending on platform, this can map the graphics buffer each196 * \warning Depending on platform, this can map the graphics buffer each
185 * time its called. The region remains mapped until197 * time its called. The region remains mapped until
186 * mir_buffer_stream_swap_buffers().198 * mir_buffer_stream_swap_buffers().
187 * \pre The buffer stream is valid199 * \pre The buffer stream is valid
188 * \param [in] buffer_stream The buffer stream200 * \param [in] buffer_stream The buffer stream
189 * \param [out] graphics_region Structure to be populated201 * \param [out] graphics_region Structure to be populated
202 * \return True if the region is valid, false otherwise.
190 */203 */
191void mir_buffer_stream_get_graphics_region(204bool mir_buffer_stream_get_graphics_region(
192 MirBufferStream *buffer_stream,205 MirBufferStream *buffer_stream,
193 MirGraphicsRegion *graphics_region);206 MirGraphicsRegion *graphics_region);
194207
195/**208/**
196 * Retrieve a window type which may be used by EGL.209 * Retrieve a window type which may be used by EGL.
210 *
211 * \deprecated No replacement, use MirRenderSurface * directly with EGL
212 *
197 * \param [in] buffer_stream The buffer stream213 * \param [in] buffer_stream The buffer stream
198 * \return An EGLNativeWindowType that the client can use214 * \return An EGLNativeWindowType that the client can use
199 */215 */
216[[deprecated]]
200MirEGLNativeWindowType mir_buffer_stream_get_egl_native_window(MirBufferStream *buffer_stream);217MirEGLNativeWindowType mir_buffer_stream_get_egl_native_window(MirBufferStream *buffer_stream);
201218
202/**219/**
203 * Set the scale associated with all buffers in the stream220 * Set the scale associated with all buffers in the stream
221 *
222 * \note May need deprecation - Need a consistent API for high DPI scaling/destination size
223 *
204 * \param [in] buffer_stream The buffer stream224 * \param [in] buffer_stream The buffer stream
205 * \param [in] scale The scale225 * \param [in] scale The scale
206 * \return A handle that can be passed to mir_wait_for226 * \return A handle that can be passed to mir_wait_for
207 */227 */
208MirWaitHandle *mir_buffer_stream_set_scale(MirBufferStream* buffer_stream, float scale);228MirWaitHandle *mir_buffer_stream_set_scale(MirBufferStream* buffer_stream, float scale);
209229
210/**230/**
211 * Set the scale as in mir_buffer_stream_set_scale(), but also wait for the231 * Set the scale as in mir_buffer_stream_set_scale(), but also wait for the
212 * operation to complete.232 * operation to complete.
233 *
234 * \note May need deprecation - Need a consistent API for high DPI scaling/destination size
235 *
213 * \param [in] buffer_stream The buffer stream236 * \param [in] buffer_stream The buffer stream
214 * \param [in] scale The scale237 * \param [in] scale The scale
215 */238 */
216239
=== modified file 'include/client/mir_toolkit/mir_connection.h'
--- include/client/mir_toolkit/mir_connection.h 2016-10-12 06:03:15 +0000
+++ include/client/mir_toolkit/mir_connection.h 2016-10-26 15:43:25 +0000
@@ -51,7 +51,7 @@
51 char const *server,51 char const *server,
52 char const *app_name,52 char const *app_name,
53 mir_connected_callback callback,53 mir_connected_callback callback,
54 void *context);54 void *context); 
5555
56/**56/**
57 * Perform a mir_connect() but also wait for and return the result.57 * Perform a mir_connect() but also wait for and return the result.
@@ -89,20 +89,26 @@
89/**89/**
90 * Query platform-specific data and/or file descriptors that are required to90 * Query platform-specific data and/or file descriptors that are required to
91 * initialize GL/EGL features.91 * initialize GL/EGL features.
92 *
93 * \deprecated Use "get_platform" extension
94 *
92 * \param [in] connection The connection95 * \param [in] connection The connection
93 * \param [out] platform_package Structure to be populated96 * \param [out] platform_package Structure to be populated
94 */97 */
98[[deprecated]]
95void mir_connection_get_platform(MirConnection *connection, MirPlatformPackage *platform_package);99void mir_connection_get_platform(MirConnection *connection, MirPlatformPackage *platform_package);
96100
97/**101/**
98 * Query graphics platform module.102 * Query graphics platform module.
99 *103 *
104 * \deprecated Use "get_graphics_module" extension
100 * \note The char pointers in MirModuleProperties are owned by the connection and should not be105 * \note The char pointers in MirModuleProperties are owned by the connection and should not be
101 * freed. They remain valid until the connection is released.106 * freed. They remain valid until the connection is released.
102 *107 *
103 * \param [in] connection The connection108 * \param [in] connection The connection
104 * \param [out] properties Structure to be populated109 * \param [out] properties Structure to be populated
105 */110 */
111[[deprecated]]
106void mir_connection_get_graphics_module(MirConnection *connection, MirModuleProperties *properties);112void mir_connection_get_graphics_module(MirConnection *connection, MirModuleProperties *properties);
107113
108/**114/**
@@ -146,13 +152,14 @@
146/**152/**
147 * Query the display153 * Query the display
148 *154 *
149 * \deprecated Use mir_connection_create_display_configuration() instead.155 * \deprecated See mir_connection_create_display_configuration()
150 *156 *
151 * \warning return value must be destroyed via mir_display_config_destroy()157 * \warning return value must be destroyed via mir_display_config_destroy()
152 * \warning may return null if connection is invalid158 * \warning may return null if connection is invalid
153 * \param [in] connection The connection159 * \param [in] connection The connection
154 * \return structure that describes the display configuration160 * \return structure that describes the display configuration
155 */161 */
162[[deprecated("Use mir_connection_create_display_configuration")]]
156MirDisplayConfiguration* mir_connection_create_display_config(MirConnection *connection);163MirDisplayConfiguration* mir_connection_create_display_config(MirConnection *connection);
157164
158/**165/**
@@ -189,6 +196,8 @@
189/**196/**
190 * Apply the display configuration197 * Apply the display configuration
191 *198 *
199 * \deprecated Replace with mir_connection_apply_display_configuration(...)
200 *
192 * The display configuration is applied to this connection only (per-connection201 * The display configuration is applied to this connection only (per-connection
193 * configuration) and is invalidated when a hardware change occurs. Clients should202 * configuration) and is invalidated when a hardware change occurs. Clients should
194 * register a callback with mir_connection_set_display_config_change_callback()203 * register a callback with mir_connection_set_display_config_change_callback()
@@ -199,11 +208,14 @@
199 * \param [in] display_configuration The display_configuration to apply208 * \param [in] display_configuration The display_configuration to apply
200 * \return A handle that can be passed to mir_wait_for209 * \return A handle that can be passed to mir_wait_for
201 */210 */
211[[deprecated]]
202MirWaitHandle* mir_connection_apply_display_config(MirConnection *connection, MirDisplayConfiguration* display_configuration);212MirWaitHandle* mir_connection_apply_display_config(MirConnection *connection, MirDisplayConfiguration* display_configuration);
203213
204/**214/**
205 * Set the base display configuration215 * Set the base display configuration
206 *216 *
217 * \deprecated Use mir_connection_preview_base_display_configuration/mir_connection_confirm_base_display_configuration
218 *
207 * The base display configuration is the configuration the server applies when219 * The base display configuration is the configuration the server applies when
208 * there is no active per-connection configuration.220 * there is no active per-connection configuration.
209 *221 *
@@ -222,6 +234,7 @@
222 * \param [in] display_configuration The display_configuration to set as base234 * \param [in] display_configuration The display_configuration to set as base
223 * \return A handle that can be passed to mir_wait_for235 * \return A handle that can be passed to mir_wait_for
224 */236 */
237[[deprecated]]
225MirWaitHandle* mir_connection_set_base_display_config(238MirWaitHandle* mir_connection_set_base_display_config(
226 MirConnection* connection,239 MirConnection* connection,
227 MirDisplayConfiguration const* display_configuration);240 MirDisplayConfiguration const* display_configuration);
@@ -298,6 +311,9 @@
298311
299/**312/**
300 * Get a display type that can be used for OpenGL ES 2.0 acceleration.313 * Get a display type that can be used for OpenGL ES 2.0 acceleration.
314 *
315 * \deprecated No replacement. Use MirConnection * directly with EGL
316 *
301 * \param [in] connection The connection317 * \param [in] connection The connection
302 * \return An EGLNativeDisplayType that the client can use318 * \return An EGLNativeDisplayType that the client can use
303 */319 */
@@ -306,11 +322,15 @@
306/**322/**
307 * Get the exact MirPixelFormat to use in creating a surface for a chosen323 * Get the exact MirPixelFormat to use in creating a surface for a chosen
308 * EGLConfig.324 * EGLConfig.
325 *
326 * \deprecated No replacement. Use EGL configs directly.
327 *
309 * \param [in] connection The connection328 * \param [in] connection The connection
310 * \param [in] egldisplay The EGLDisplay for the given config329 * \param [in] egldisplay The EGLDisplay for the given config
311 * \param [in] eglconfig The EGLConfig you have chosen to use330 * \param [in] eglconfig The EGLConfig you have chosen to use
312 * \return The MirPixelFormat to use in surface creation331 * \return The MirPixelFormat to use in surface creation
313 */332 */
333[[deprecated]]
314MirPixelFormat mir_connection_get_egl_pixel_format(334MirPixelFormat mir_connection_get_egl_pixel_format(
315 MirConnection *connection, void *egldisplay, void *eglconfig);335 MirConnection *connection, void *egldisplay, void *eglconfig);
316336
@@ -336,6 +356,8 @@
336/**356/**
337 * Perform a platform specific operation.357 * Perform a platform specific operation.
338 *358 *
359 * \deprecated Use the platform extensions API instead
360 *
339 * The MirPlatformMessage used for the request needs to remain valid361 * The MirPlatformMessage used for the request needs to remain valid
340 * until this operation finishes.362 * until this operation finishes.
341 *363 *
@@ -345,6 +367,7 @@
345 * \param [in,out] context User data passed to the callback function367 * \param [in,out] context User data passed to the callback function
346 * \return A handle that can be passed to mir_wait_for368 * \return A handle that can be passed to mir_wait_for
347 */369 */
370[[deprecated]]
348MirWaitHandle* mir_connection_platform_operation(371MirWaitHandle* mir_connection_platform_operation(
349 MirConnection* connection,372 MirConnection* connection,
350 MirPlatformMessage const* request,373 MirPlatformMessage const* request,
351374
=== modified file 'include/client/mir_toolkit/mir_cursor_configuration.h'
--- include/client/mir_toolkit/mir_cursor_configuration.h 2016-09-08 02:58:56 +0000
+++ include/client/mir_toolkit/mir_cursor_configuration.h 2016-10-26 15:43:25 +0000
@@ -57,6 +57,9 @@
57 * Returns a new cursor configuration tied to a given buffer stream.57 * Returns a new cursor configuration tied to a given buffer stream.
58 * If the configuration is successfully applied buffers from the stream will be used 58 * If the configuration is successfully applied buffers from the stream will be used
59 * to fill the system cursor.59 * to fill the system cursor.
60 *
61 * \note Replace MirBufferStream with MirRenderSurface
62 *
60 * \param [in] stream The buffer stream63 * \param [in] stream The buffer stream
61 * \param [in] hotspot_x The x-coordinate to use as the cursor's hotspot.64 * \param [in] hotspot_x The x-coordinate to use as the cursor's hotspot.
62 * \param [in] hotspot_y The y-coordinate to use as the cursor's hotspot.65 * \param [in] hotspot_y The y-coordinate to use as the cursor's hotspot.
6366
=== modified file 'include/client/mir_toolkit/mir_display_configuration.h'
--- include/client/mir_toolkit/mir_display_configuration.h 2016-10-20 15:07:39 +0000
+++ include/client/mir_toolkit/mir_display_configuration.h 2016-10-26 15:43:25 +0000
@@ -50,6 +50,8 @@
50 * Get the maximum possible number of simultaneously active outputs this system50 * Get the maximum possible number of simultaneously active outputs this system
51 * supports.51 * supports.
52 *52 *
53 * No replacement. API is not useful.
54 *
53 * \note There may be restrictions on the configuration required to achieve this55 * \note There may be restrictions on the configuration required to achieve this
54 * many active outputs. Typically the achievable number of simultaneously active56 * many active outputs. Typically the achievable number of simultaneously active
55 * outputs is lower than this number.57 * outputs is lower than this number.
@@ -58,6 +60,7 @@
58 * \returns The maximum number of simultaneously active outputs60 * \returns The maximum number of simultaneously active outputs
59 * supportable at this time.61 * supportable at this time.
60 */62 */
63[[deprecated]]
61int mir_display_config_get_max_simultaneous_outputs(64int mir_display_config_get_max_simultaneous_outputs(
62 MirDisplayConfig const* config);65 MirDisplayConfig const* config);
6366
@@ -263,9 +266,12 @@
263/**266/**
264 * Get the textual name of an output type.267 * Get the textual name of an output type.
265 *268 *
269 * \deprecated See mir_output_type_name
270 *
266 * \param [in] type The MirDisplayOutputType to describe.271 * \param [in] type The MirDisplayOutputType to describe.
267 * \returns The name of the output type.272 * \returns The name of the output type.
268 */273 */
274[[deprecated]]
269char const* mir_display_output_type_name(MirDisplayOutputType type);275char const* mir_display_output_type_name(MirDisplayOutputType type);
270276
271/**277/**
272278
=== modified file 'include/client/mir_toolkit/mir_platform_message.h'
--- include/client/mir_toolkit/mir_platform_message.h 2014-12-10 11:02:04 +0000
+++ include/client/mir_toolkit/mir_platform_message.h 2016-10-26 15:43:25 +0000
@@ -48,16 +48,22 @@
48 * Each call to mir_platform_message_create() should be matched by48 * Each call to mir_platform_message_create() should be matched by
49 * a call to mir_platform_message_release() to avoid memory leaks.49 * a call to mir_platform_message_release() to avoid memory leaks.
50 *50 *
51 * \deprecated Use platform extensions API
52 *
51 * \param [in] opcode The platform message opcode53 * \param [in] opcode The platform message opcode
52 * \return The created MirPlatformMessage54 * \return The created MirPlatformMessage
53 */55 */
56[[deprecated]]
54MirPlatformMessage* mir_platform_message_create(unsigned int opcode);57MirPlatformMessage* mir_platform_message_create(unsigned int opcode);
5558
56/**59/**
57 * Release a platform message.60 * Release a platform message.
58 *61 *
62 * \deprecated Use platform extensions API
63 *
59 * \param [in] message The MirPlatformMessage64 * \param [in] message The MirPlatformMessage
60 */65 */
66[[deprecated]]
61void mir_platform_message_release(MirPlatformMessage const* message);67void mir_platform_message_release(MirPlatformMessage const* message);
6268
63/**69/**
@@ -65,10 +71,13 @@
65 *71 *
66 * The data is copied into the message.72 * The data is copied into the message.
67 *73 *
74 * \deprecated Use platform extensions API
75 *
68 * \param [in] message The MirPlatformMessage76 * \param [in] message The MirPlatformMessage
69 * \param [in] data Pointer to the data77 * \param [in] data Pointer to the data
70 * \param [in] data_size The size of the data in bytes78 * \param [in] data_size The size of the data in bytes
71 */79 */
80[[deprecated]]
72void mir_platform_message_set_data(MirPlatformMessage* message, void const* data, size_t data_size);81void mir_platform_message_set_data(MirPlatformMessage* message, void const* data, size_t data_size);
7382
74/**83/**
@@ -82,18 +91,24 @@
82 * is released. The caller is responsible for closing the fds when the message91 * is released. The caller is responsible for closing the fds when the message
83 * doesn't need them anymore (see also mir_platform_message_get_fds()).92 * doesn't need them anymore (see also mir_platform_message_get_fds()).
84 *93 *
94 * \deprecated Use platform extensions API
95 *
85 * \param [in] message The MirPlatformMessage96 * \param [in] message The MirPlatformMessage
86 * \param [in] fds Pointer to the array of fds97 * \param [in] fds Pointer to the array of fds
87 * \param [in] num_fds The number of fds98 * \param [in] num_fds The number of fds
88 */99 */
100[[deprecated]]
89void mir_platform_message_set_fds(MirPlatformMessage* message, int const* fds, size_t num_fds);101void mir_platform_message_set_fds(MirPlatformMessage* message, int const* fds, size_t num_fds);
90102
91/**103/**
92 * Get the opcode of a message.104 * Get the opcode of a message.
93 *105 *
106 * \deprecated Use platform extensions API
107 *
94 * \param [in] message The MirPlatformMessage108 * \param [in] message The MirPlatformMessage
95 * \return The opcode109 * \return The opcode
96 */110 */
111[[deprecated]]
97unsigned int mir_platform_message_get_opcode(MirPlatformMessage const* message);112unsigned int mir_platform_message_get_opcode(MirPlatformMessage const* message);
98113
99/**114/**
@@ -103,9 +118,11 @@
103 * valid only as long as the message is valid and mir_platform_set_data() is118 * valid only as long as the message is valid and mir_platform_set_data() is
104 * not called. You must not change or free the returned data array.119 * not called. You must not change or free the returned data array.
105 *120 *
121 * \deprecated Use platform extensions API
106 * \param [in] message The MirPlatformMessage122 * \param [in] message The MirPlatformMessage
107 * \return The data123 * \return The data
108 */124 */
125[[deprecated]]
109MirPlatformMessageData mir_platform_message_get_data(MirPlatformMessage const* message);126MirPlatformMessageData mir_platform_message_get_data(MirPlatformMessage const* message);
110127
111/**128/**
@@ -119,9 +136,11 @@
119 * message is released. Users are responsible for getting and closing the136 * message is released. Users are responsible for getting and closing the
120 * fds to avoid leaks.137 * fds to avoid leaks.
121 *138 *
139 * \deprecated Use platform extensions API
122 * \param [in] message The MirPlatformMessage140 * \param [in] message The MirPlatformMessage
123 * \return The fds141 * \return The fds
124 */142 */
143[[deprecated]]
125MirPlatformMessageFds mir_platform_message_get_fds(MirPlatformMessage const* message);144MirPlatformMessageFds mir_platform_message_get_fds(MirPlatformMessage const* message);
126145
127#ifdef __cplusplus146#ifdef __cplusplus
128147
=== modified file 'include/client/mir_toolkit/mir_screencast.h'
--- include/client/mir_toolkit/mir_screencast.h 2016-07-18 07:38:38 +0000
+++ include/client/mir_toolkit/mir_screencast.h 2016-10-26 15:43:25 +0000
@@ -89,10 +89,13 @@
89/**89/**
90 * Set the requested number of buffers to use.90 * Set the requested number of buffers to use.
91 *91 *
92 * \deprecated See mir_screencast_capture_to_buffer
93 *
92 * \param [in] spec Specification to mutate94 * \param [in] spec Specification to mutate
93 * \param [in] nbuffers The number of buffers to allocate for screencasting95 * \param [in] nbuffers The number of buffers to allocate for screencasting
94 *96 *
95 */97 */
98[[deprecated]]
96void mir_screencast_spec_set_number_of_buffers(MirScreencastSpec* spec, unsigned int nbuffers);99void mir_screencast_spec_set_number_of_buffers(MirScreencastSpec* spec, unsigned int nbuffers);
97100
98/**101/**
@@ -135,11 +138,14 @@
135 *138 *
136 * A screencast allows clients to read the contents of the screen.139 * A screencast allows clients to read the contents of the screen.
137 *140 *
141 * \deprecated See mir_screencast_create_sync
142 *
138 * \warning This request may be denied.143 * \warning This request may be denied.
139 * \param [in] connection The connection144 * \param [in] connection The connection
140 * \param [in] parameters The screencast parameters145 * \param [in] parameters The screencast parameters
141 * \return The resulting screencast146 * \return The resulting screencast
142 */147 */
148[[deprecated]]
143MirScreencast* mir_connection_create_screencast_sync(149MirScreencast* mir_connection_create_screencast_sync(
144 MirConnection* connection,150 MirConnection* connection,
145 MirScreencastParameters* parameters);151 MirScreencastParameters* parameters);
@@ -155,8 +161,11 @@
155 * Retrieve the MirBufferStream associated with a screencast 161 * Retrieve the MirBufferStream associated with a screencast
156 * (to advance buffers, obtain EGLNativeWindowType, etc...)162 * (to advance buffers, obtain EGLNativeWindowType, etc...)
157 * 163 *
164 * \deprecated See mir_screencast_capture_to_buffer
165 *
158 * \param[in] screencast The screencast166 * \param[in] screencast The screencast
159 */167 */
168[[deprecated]]
160MirBufferStream* mir_screencast_get_buffer_stream(MirScreencast* screencast);169MirBufferStream* mir_screencast_get_buffer_stream(MirScreencast* screencast);
161170
162#ifdef __cplusplus171#ifdef __cplusplus
163172
=== modified file 'include/client/mir_toolkit/mir_surface.h'
--- include/client/mir_toolkit/mir_surface.h 2016-10-12 06:03:15 +0000
+++ include/client/mir_toolkit/mir_surface.h 2016-10-26 15:43:25 +0000
@@ -232,6 +232,7 @@
232/**232/**
233 * Create a surface from a given specification233 * Create a surface from a given specification
234 *234 *
235 * \note There is no implicit buffer stream creation. See mir_xxx to attach content.
235 *236 *
236 * \param [in] requested_specification Specification of the attributes for the created surface237 * \param [in] requested_specification Specification of the attributes for the created surface
237 * \param [in] callback Callback function to be invoked when creation is complete238 * \param [in] callback Callback function to be invoked when creation is complete
@@ -411,6 +412,9 @@
411412
412/**413/**
413 * Set the requested pixel format.414 * Set the requested pixel format.
415 *
416 * \deprecated No replacement. This property is now part of the backing content
417 *
414 * \param [in] spec Specification to mutate418 * \param [in] spec Specification to mutate
415 * \param [in] format Requested pixel format419 * \param [in] format Requested pixel format
416 *420 *
@@ -418,10 +422,14 @@
418 * If the server is unable to create a surface with this pixel format at422 * If the server is unable to create a surface with this pixel format at
419 * the point mir_surface_create() is called it will instead return an invalid surface.423 * the point mir_surface_create() is called it will instead return an invalid surface.
420 */424 */
425[[deprecated]]
421void mir_surface_spec_set_pixel_format(MirSurfaceSpec* spec, MirPixelFormat format);426void mir_surface_spec_set_pixel_format(MirSurfaceSpec* spec, MirPixelFormat format);
422427
423/**428/**
424 * Set the requested buffer usage.429 * Set the requested buffer usage.
430 *
431 * \deprecated No replacement. This property is now part of the backing content
432 *
425 * \param [in] spec Specification to mutate433 * \param [in] spec Specification to mutate
426 * \param [in] usage Requested buffer usage434 * \param [in] usage Requested buffer usage
427 *435 *
@@ -429,13 +437,15 @@
429 * If the server is unable to create a surface with this buffer usage at437 * If the server is unable to create a surface with this buffer usage at
430 * the point mir_surface_create() is called it will instead return an invalid surface.438 * the point mir_surface_create() is called it will instead return an invalid surface.
431 */439 */
440[[deprecated]]
432void mir_surface_spec_set_buffer_usage(MirSurfaceSpec* spec, MirBufferUsage usage);441void mir_surface_spec_set_buffer_usage(MirSurfaceSpec* spec, MirBufferUsage usage);
433442
434/**443/**
435 * \param [in] spec Specification to mutate444 * \param [in] spec Specification to mutate
436 * \param [in] output_id ID of output to place surface on. From MirDisplayOutput.output_id445 * \param [in] output_id ID of output to place surface on. From MirDisplayOutput.output_id
437 *446 *
438 * \note If this call returns %true then a valid surface returned from mir_surface_create() is447 * \note Update comment below
448 * \note If this call returns %t then a valid surface returned from mir_surface_create() is
439 * guaranteed to be fullscreen on the specified output. An invalid surface is returned449 * guaranteed to be fullscreen on the specified output. An invalid surface is returned
440 * if the server unable to, or policy prevents it from, honouring this request.450 * if the server unable to, or policy prevents it from, honouring this request.
441 */451 */
@@ -501,6 +511,8 @@
501 * but is in the list will be associated with the surface.511 * but is in the list will be associated with the surface.
502 * Streams set a displacement from the top-left corner of the surface.512 * Streams set a displacement from the top-left corner of the surface.
503 * 513 *
514 * \deprecated Replaced by mir_surface_set_render_surfaces
515 *
504 * \warning disassociating streams from the surface will not release() them.516 * \warning disassociating streams from the surface will not release() them.
505 * \warning It is wiser to arrange the streams within the bounds of the517 * \warning It is wiser to arrange the streams within the bounds of the
506 * surface the spec is applied to. Shells can define their own518 * surface the spec is applied to. Shells can define their own
@@ -510,6 +522,7 @@
510 * \param [in] streams An array of non-null streams info.522 * \param [in] streams An array of non-null streams info.
511 * \param [in] num_streams The number of elements in the streams array.523 * \param [in] num_streams The number of elements in the streams array.
512 */524 */
525[[deprecated]]
513void mir_surface_spec_set_streams(MirSurfaceSpec* spec,526void mir_surface_spec_set_streams(MirSurfaceSpec* spec,
514 MirBufferStreamInfo* streams,527 MirBufferStreamInfo* streams,
515 unsigned int num_streams);528 unsigned int num_streams);
@@ -600,6 +613,9 @@
600613
601/**614/**
602 * Set the event handler to be called when events arrive for a surface.615 * Set the event handler to be called when events arrive for a surface.
616 *
617 * \deprecated Use mir_surface_spec_set_event_handler instead.
618 *
603 * \warning event_handler could be called from another thread. You must do619 * \warning event_handler could be called from another thread. You must do
604 * any locking appropriate to protect your data accessed in the620 * any locking appropriate to protect your data accessed in the
605 * callback. There is also a chance that different events will be621 * callback. There is also a chance that different events will be
@@ -609,6 +625,7 @@
609 * \param [in] callback The callback function625 * \param [in] callback The callback function
610 * \param [in] context Additional argument to be passed to callback626 * \param [in] context Additional argument to be passed to callback
611 */627 */
628[[deprecated("Use mir_surface_spec_set_event_handler")]]
612void mir_surface_set_event_handler(MirSurface *surface,629void mir_surface_set_event_handler(MirSurface *surface,
613 mir_surface_event_callback callback,630 mir_surface_event_callback callback,
614 void* context);631 void* context);
@@ -626,6 +643,7 @@
626 * be removed, and this function will return NULL.643 * be removed, and this function will return NULL.
627 * \param[in] surface The surface644 * \param[in] surface The surface
628 */645 */
646[[deprecated]]
629MirBufferStream* mir_surface_get_buffer_stream(MirSurface *surface);647MirBufferStream* mir_surface_get_buffer_stream(MirSurface *surface);
630648
631/**649/**
@@ -649,10 +667,14 @@
649667
650/**668/**
651 * Get a surface's parameters.669 * Get a surface's parameters.
670 *
671 * \deprecated MirSurfaceParameters is obsolete.
672 *
652 * \pre The surface is valid673 * \pre The surface is valid
653 * \param [in] surface The surface674 * \param [in] surface The surface
654 * \param [out] parameters Structure to be populated675 * \param [out] parameters Structure to be populated
655 */676 */
677[[deprecated]]
656void mir_surface_get_parameters(MirSurface *surface, MirSurfaceParameters *parameters);678void mir_surface_get_parameters(MirSurface *surface, MirSurfaceParameters *parameters);
657679
658/**680/**
@@ -681,29 +703,44 @@
681703
682/**704/**
683 * Get the type (purpose) of a surface.705 * Get the type (purpose) of a surface.
706 *
707 * \deprecated ? Mostly a convenience function. Look for MirSurfaceType events instead?
708 *
684 * \param [in] surface The surface to query709 * \param [in] surface The surface to query
685 * \return The type of the surface710 * \return The type of the surface
686 */711 */
712[[deprecated]]
687MirSurfaceType mir_surface_get_type(MirSurface *surface);713MirSurfaceType mir_surface_get_type(MirSurface *surface);
688714
689/**715/**
690 * Change the state of a surface.716 * Change the state of a surface.
717 *
718 * \deprecated Use mir_surface_apply_spec instead
719 *
691 * \param [in] surface The surface to operate on720 * \param [in] surface The surface to operate on
692 * \param [in] state The new state of the surface721 * \param [in] state The new state of the surface
693 * \return A wait handle that can be passed to mir_wait_for722 * \return A wait handle that can be passed to mir_wait_for
694 */723 */
724[[deprecated("See mir_surface_apply_spec")]]
695MirWaitHandle* mir_surface_set_state(MirSurface *surface,725MirWaitHandle* mir_surface_set_state(MirSurface *surface,
696 MirSurfaceState state);726 MirSurfaceState state);
697727
698/**728/**
699 * Get the current state of a surface.729 * Get the current state of a surface.
730 *
731 * \deprecated ? Mostly a convenience function. Look for MirSurfaceState events instead?
732 *
700 * \param [in] surface The surface to query733 * \param [in] surface The surface to query
701 * \return The state of the surface734 * \return The state of the surface
702 */735 */
736[[deprecated]]
703MirSurfaceState mir_surface_get_state(MirSurface *surface);737MirSurfaceState mir_surface_get_state(MirSurface *surface);
704738
705/**739/**
706 * Set the swapinterval for the default stream.740 * Set the swapinterval for the default stream.
741 *
742 * \deprecated No replacement. This is not a property of the surface anymore.
743 *
707 * \warning EGL users should use eglSwapInterval directly.744 * \warning EGL users should use eglSwapInterval directly.
708 * \warning Only swapinterval of 0 or 1 is supported.745 * \warning Only swapinterval of 0 or 1 is supported.
709 * \warning If the surface was created with, or modified to have a746 * \warning If the surface was created with, or modified to have a
@@ -716,27 +753,39 @@
716 * \return A wait handle that can be passed to mir_wait_for,753 * \return A wait handle that can be passed to mir_wait_for,
717 * or NULL if the interval could not be supported754 * or NULL if the interval could not be supported
718 */755 */
756[[deprecated]]
719MirWaitHandle* mir_surface_set_swapinterval(MirSurface* surface, int interval);757MirWaitHandle* mir_surface_set_swapinterval(MirSurface* surface, int interval);
720758
721/**759/**
722 * Query the swapinterval that the surface is operating with.760 * Query the swapinterval that the surface is operating with.
723 * The default interval is 1.761 * The default interval is 1.
762 *
763 * \deprecated No replacement. This is not a property of the surface anymore.
764 *
724 * \param [in] surface The surface to operate on765 * \param [in] surface The surface to operate on
725 * \return The swapinterval value that the client is operating with.766 * \return The swapinterval value that the client is operating with.
726 * Returns -1 if surface is invalid, or if the default stream767 * Returns -1 if surface is invalid, or if the default stream
727 * was removed by use of mir_surface_spec_set_streams().768 * was removed by use of mir_surface_spec_set_streams().
728 */769 */
770[[deprecated]]
729int mir_surface_get_swapinterval(MirSurface* surface);771int mir_surface_get_swapinterval(MirSurface* surface);
730772
731/**773/**
732 * Query the DPI value of the surface (dots per inch). This will vary depending774 * Query the DPI value of the surface (dots per inch). This will vary depending
733 * on the physical display configuration and where the surface is within it.775 * on the physical display configuration and where the surface is within it.
776 *
777 * \deprecated ? Mostly a convenience function - Use dpi events instead?
778 *
734 * \return The DPI of the surface, or zero if unknown.779 * \return The DPI of the surface, or zero if unknown.
735 */780 */
781[[deprecated]]
736int mir_surface_get_dpi(MirSurface* surface);782int mir_surface_get_dpi(MirSurface* surface);
737 783
738/**784/**
739 * Query the focus state for a surface.785 * Query the focus state for a surface.
786 *
787 * \deprecated
788 *
740 * \param [in] surface The surface to operate on789 * \param [in] surface The surface to operate on
741 * \return The focus state of said surface790 * \return The focus state of said surface
742 */791 */
@@ -744,6 +793,9 @@
744793
745/**794/**
746 * Query the visibility state for a surface.795 * Query the visibility state for a surface.
796 *
797 * \deprecated
798 *
747 * \param [in] surface The surface to operate on799 * \param [in] surface The surface to operate on
748 * \return The visibility state of said surface800 * \return The visibility state of said surface
749 */801 */
@@ -752,6 +804,9 @@
752/**804/**
753 * Choose the cursor state for a surface: whether a cursor is shown, 805 * Choose the cursor state for a surface: whether a cursor is shown,
754 * and which cursor if so.806 * and which cursor if so.
807 *
808 * \deprecated Use mir_surface_apply_spec instead
809 *
755 * \param [in] surface The surface to operate on810 * \param [in] surface The surface to operate on
756 * \param [in] parameters The configuration parameters obtained811 * \param [in] parameters The configuration parameters obtained
757 * from mir_cursor* family of functions.812 * from mir_cursor* family of functions.
@@ -759,30 +814,43 @@
759 * or NULL if parameters is invalid.814 * or NULL if parameters is invalid.
760 *815 *
761 */816 */
817[[deprecated("See mir_surface_apply_spec")]]
762MirWaitHandle* mir_surface_configure_cursor(MirSurface *surface, MirCursorConfiguration const* parameters);818MirWaitHandle* mir_surface_configure_cursor(MirSurface *surface, MirCursorConfiguration const* parameters);
763819
764/**820/**
765 * Get the orientation of a surface.821 * Get the orientation of a surface.
822 *
823 * \deprecated ? Mostly a convenience function - Use dpi events instead?
824 *
766 * \param [in] surface The surface to query825 * \param [in] surface The surface to query
767 * \return The orientation of the surface826 * \return The orientation of the surface
768 */827 */
828[[deprecated]]
769MirOrientation mir_surface_get_orientation(MirSurface *surface);829MirOrientation mir_surface_get_orientation(MirSurface *surface);
770830
771/**831/**
772 * Request to set the preferred orientations of a surface.832 * Request to set the preferred orientations of a surface.
773 * The request may be rejected by the server; to check wait on the833 * The request may be rejected by the server; to check wait on the
774 * result and check the applied value using mir_surface_get_preferred_orientation834 * result and check the applied value using mir_surface_get_preferred_orientation
835 *
836 * \deprecated Use mir_surface_apply_spec instead
837 *
775 * \param [in] surface The surface to operate on838 * \param [in] surface The surface to operate on
776 * \param [in] orientation The preferred orientation modes839 * \param [in] orientation The preferred orientation modes
777 * \return A wait handle that can be passed to mir_wait_for840 * \return A wait handle that can be passed to mir_wait_for
778 */841 */
842[[deprecated("See mir_surface_apply_spec")]]
779MirWaitHandle* mir_surface_set_preferred_orientation(MirSurface *surface, MirOrientationMode orientation);843MirWaitHandle* mir_surface_set_preferred_orientation(MirSurface *surface, MirOrientationMode orientation);
780844
781/**845/**
782 * Get the preferred orientation modes of a surface.846 * Get the preferred orientation modes of a surface.
847 *
848 * \deprecated No alternative as client should already know what the preferred orientation the surface is set to.
849 *
783 * \param [in] surface The surface to query850 * \param [in] surface The surface to query
784 * \return The preferred orientation modes851 * \return The preferred orientation modes
785 */852 */
853[[deprecated]]
786MirOrientationMode mir_surface_get_preferred_orientation(MirSurface *surface);854MirOrientationMode mir_surface_get_preferred_orientation(MirSurface *surface);
787855
788/**856/**
789857
=== modified file 'include/core/mir_toolkit/common.h'
--- include/core/mir_toolkit/common.h 2016-10-20 15:05:56 +0000
+++ include/core/mir_toolkit/common.h 2016-10-26 15:43:25 +0000
@@ -349,6 +349,7 @@
349{349{
350 mir_shell_chrome_normal,350 mir_shell_chrome_normal,
351 mir_shell_chrome_low,351 mir_shell_chrome_low,
352 mir_shell_chrome_none
352} MirShellChrome;353} MirShellChrome;
353354
354/**355/**

Subscribers

People subscribed via source and target branches