forked from enlightenment/efl
Deprecate ecore_x_randr_current_crtc_get,
implement and use ecore_x_randr_window_crtcs_get instead SVN revision: 68344
This commit is contained in:
parent
23528373cc
commit
895355ef99
|
@ -2771,6 +2771,9 @@ EINA_DEPRECATED EAPI Ecore_X_Randr_Output *
|
||||||
ecore_x_randr_current_output_get(Ecore_X_Window window,
|
ecore_x_randr_current_output_get(Ecore_X_Window window,
|
||||||
int *num);
|
int *num);
|
||||||
EAPI Ecore_X_Randr_Crtc *
|
EAPI Ecore_X_Randr_Crtc *
|
||||||
|
ecore_x_randr_window_crtcs_get(Ecore_X_Window window,
|
||||||
|
int *num);
|
||||||
|
EINA_DEPRECATED EAPI Ecore_X_Randr_Crtc *
|
||||||
ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
||||||
int *num);
|
int *num);
|
||||||
EAPI Ecore_X_Randr_Output *
|
EAPI Ecore_X_Randr_Output *
|
||||||
|
|
|
@ -533,6 +533,21 @@ ecore_x_randr_crtcs_get(Ecore_X_Window root,
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @depricated bad naming. Use ecore_x_randr_window_outputs_get instead.
|
||||||
|
* @brief get the CRTCs, which display a certain window
|
||||||
|
* @param window window the displaying crtcs shall be found for
|
||||||
|
* @param num the number of crtcs displaying the window
|
||||||
|
* @return array of crtcs that display a certain window. NULL if no crtcs
|
||||||
|
* was found that displays the specified window.
|
||||||
|
*/
|
||||||
|
EINA_DEPRECATED EAPI Ecore_X_Randr_Crtc *
|
||||||
|
ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
||||||
|
int *num)
|
||||||
|
{
|
||||||
|
return ecore_x_randr_window_crtcs_get(window, num);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* @brief get the CRTCs, which display a certain window
|
* @brief get the CRTCs, which display a certain window
|
||||||
* @param window window the displaying crtcs shall be found for
|
* @param window window the displaying crtcs shall be found for
|
||||||
|
@ -541,7 +556,7 @@ ecore_x_randr_crtcs_get(Ecore_X_Window root,
|
||||||
* was found that displays the specified window.
|
* was found that displays the specified window.
|
||||||
*/
|
*/
|
||||||
EAPI Ecore_X_Randr_Crtc *
|
EAPI Ecore_X_Randr_Crtc *
|
||||||
ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
ecore_x_randr_window_crtcs_get(Ecore_X_Window window,
|
||||||
int *num)
|
int *num)
|
||||||
{
|
{
|
||||||
#ifdef ECORE_XRANDR
|
#ifdef ECORE_XRANDR
|
||||||
|
@ -553,7 +568,7 @@ ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
||||||
Window tw;
|
Window tw;
|
||||||
int ncrtcs, i, nret = 0, rx = 0, ry = 0;
|
int ncrtcs, i, nret = 0, rx = 0, ry = 0;
|
||||||
|
|
||||||
if (_randr_version < RANDR_1_2) goto _ecore_x_randr_current_crtc_get_fail;
|
if (_randr_version < RANDR_1_2) goto _ecore_x_randr_window_crtcs_get_fail;
|
||||||
|
|
||||||
ecore_x_window_geometry_get(window,
|
ecore_x_window_geometry_get(window,
|
||||||
&w_geo.x, &w_geo.y,
|
&w_geo.x, &w_geo.y,
|
||||||
|
@ -561,7 +576,7 @@ ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
||||||
|
|
||||||
root = ecore_x_window_root_get(window);
|
root = ecore_x_window_root_get(window);
|
||||||
crtcs = ecore_x_randr_crtcs_get(root, &ncrtcs);
|
crtcs = ecore_x_randr_crtcs_get(root, &ncrtcs);
|
||||||
if (!crtcs) goto _ecore_x_randr_current_crtc_get_fail;
|
if (!crtcs) goto _ecore_x_randr_window_crtcs_get_fail;
|
||||||
|
|
||||||
/* now get window RELATIVE to root window - thats what matters. */
|
/* now get window RELATIVE to root window - thats what matters. */
|
||||||
XTranslateCoordinates(_ecore_x_disp, window, root, 0, 0, &rx, &ry, &tw);
|
XTranslateCoordinates(_ecore_x_disp, window, root, 0, 0, &rx, &ry, &tw);
|
||||||
|
@ -588,7 +603,7 @@ ecore_x_randr_current_crtc_get(Ecore_X_Window window,
|
||||||
if (num) *num = nret;
|
if (num) *num = nret;
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
_ecore_x_randr_current_crtc_get_fail:
|
_ecore_x_randr_window_crtcs_get_fail:
|
||||||
#endif
|
#endif
|
||||||
if (num) *num = 0;
|
if (num) *num = 0;
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
Loading…
Reference in New Issue