forked from enlightenment/efl
ecore-wl2: Add API to set window available rotations
@feature Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
parent
fa7f8d25b2
commit
b1584c9054
|
@ -1041,6 +1041,18 @@ EAPI void ecore_wl2_window_preferred_rotation_set(Ecore_Wl2_Window *window, int
|
|||
*/
|
||||
EAPI int ecore_wl2_window_preferred_rotation_get(Ecore_Wl2_Window *window);
|
||||
|
||||
/**
|
||||
* Set a windows available rotations
|
||||
*
|
||||
* @param window
|
||||
* @param rots
|
||||
* @param count
|
||||
*
|
||||
* @ingroup Ecore_Wl2_Window_Group
|
||||
* @since 1.20
|
||||
*/
|
||||
EAPI void ecore_wl2_window_available_rotations_set(Ecore_Wl2_Window *window, const int *rots, unsigned int count);
|
||||
|
||||
/**
|
||||
* @defgroup Ecore_Wl2_Input_Group Wayland Library Input Functions
|
||||
* @ingroup Ecore_Wl2_Group
|
||||
|
|
|
@ -191,6 +191,8 @@ struct _Ecore_Wl2_Window
|
|||
Eina_Bool supported : 1;
|
||||
Eina_Bool app_set : 1;
|
||||
int preferred_rot;
|
||||
int *available_rots;
|
||||
unsigned int count;
|
||||
} wm_rot;
|
||||
};
|
||||
|
||||
|
|
|
@ -1255,3 +1255,11 @@ ecore_wl2_window_preferred_rotation_get(Ecore_Wl2_Window *window)
|
|||
EINA_SAFETY_ON_NULL_RETURN_VAL(window, 0);
|
||||
return window->wm_rot.preferred_rot;
|
||||
}
|
||||
|
||||
EAPI void
|
||||
ecore_wl2_window_available_rotations_set(Ecore_Wl2_Window *window, const int *rots, unsigned int count)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN(window);
|
||||
window->wm_rot.count = count;
|
||||
window->wm_rot.available_rots = rots;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue