ecore: whitespaces--

SVN revision: 80017
This commit is contained in:
Vincent Torri 2012-12-03 07:37:17 +00:00
parent 6961362425
commit a3562c0173
3 changed files with 55 additions and 55 deletions

View File

@ -998,7 +998,7 @@
* Wayland SHM now features a mechanism to synchronize rendering with * Wayland SHM now features a mechanism to synchronize rendering with
the compositor, removing tearing effect in animations when using that the compositor, removing tearing effect in animations when using that
engine. engine.
2012-10-10 Michal Pakula vel Rutka 2012-10-10 Michal Pakula vel Rutka
* Fix: Send ECORE_X_EVENT_SELECTION_NOTIFY even if there is no data. * Fix: Send ECORE_X_EVENT_SELECTION_NOTIFY even if there is no data.

View File

@ -45,7 +45,7 @@ Fixes:
Removal: Removal:
* 16bpp evas engine support removed (API still there, but inactive). * 16bpp evas engine support removed (API still there, but inactive).
* 8bpp evas engine support removed (API still there, but inactive). * 8bpp evas engine support removed (API still there, but inactive).
Improvements: Improvements:
* Use Eina_Thread for Ecore_Thread. * Use Eina_Thread for Ecore_Thread.

View File

@ -14,7 +14,7 @@ static Eina_Bool _ecore_wl_xkb_shutdown(Ecore_Wl_Display *ewd);
/* local variables */ /* local variables */
static int _ecore_wl_init_count = 0; static int _ecore_wl_init_count = 0;
static const struct wl_registry_listener _ecore_wl_registry_listener = static const struct wl_registry_listener _ecore_wl_registry_listener =
{ {
_ecore_wl_cb_handle_global, _ecore_wl_cb_handle_global,
NULL // handle_global_remove NULL // handle_global_remove
@ -41,21 +41,21 @@ EAPI int ECORE_WL_EVENT_INTERFACES_BOUND = 0;
/** /**
* @defgroup Ecore_Wl_Init_Group Wayland Library Init and Shutdown Functions * @defgroup Ecore_Wl_Init_Group Wayland Library Init and Shutdown Functions
* *
* Functions that start and shutdown the Ecore Wayland Library. * Functions that start and shutdown the Ecore Wayland Library.
*/ */
/** /**
* Initialize the Wayland display connection to the given display. * Initialize the Wayland display connection to the given display.
* *
* @param name Display target name. if @c NULL, the default display is * @param name Display target name. if @c NULL, the default display is
* assumed. * assumed.
* @return The number of times the library has been initialized without being * @return The number of times the library has been initialized without being
* shut down. 0 is returned if an error occurs. * shut down. 0 is returned if an error occurs.
* *
* @ingroup Ecore_Wl_Init_Group * @ingroup Ecore_Wl_Init_Group
*/ */
EAPI int EAPI int
ecore_wl_init(const char *name) ecore_wl_init(const char *name)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -64,7 +64,7 @@ ecore_wl_init(const char *name)
if (!eina_init()) return --_ecore_wl_init_count; if (!eina_init()) return --_ecore_wl_init_count;
_ecore_wl_log_dom = _ecore_wl_log_dom =
eina_log_domain_register("ecore_wl", ECORE_WL_DEFAULT_LOG_COLOR); eina_log_domain_register("ecore_wl", ECORE_WL_DEFAULT_LOG_COLOR);
if (_ecore_wl_log_dom < 0) if (_ecore_wl_log_dom < 0)
{ {
@ -136,18 +136,18 @@ ecore_wl_init(const char *name)
_ecore_wl_disp->fd = wl_display_get_fd(_ecore_wl_disp->wl.display); _ecore_wl_disp->fd = wl_display_get_fd(_ecore_wl_disp->wl.display);
_ecore_wl_disp->fd_hdl = _ecore_wl_disp->fd_hdl =
ecore_main_fd_handler_add(_ecore_wl_disp->fd, ecore_main_fd_handler_add(_ecore_wl_disp->fd,
ECORE_FD_READ | ECORE_FD_WRITE, ECORE_FD_READ | ECORE_FD_WRITE,
_ecore_wl_cb_handle_data, _ecore_wl_disp, _ecore_wl_cb_handle_data, _ecore_wl_disp,
NULL, NULL); NULL, NULL);
wl_list_init(&_ecore_wl_disp->inputs); wl_list_init(&_ecore_wl_disp->inputs);
wl_list_init(&_ecore_wl_disp->outputs); wl_list_init(&_ecore_wl_disp->outputs);
_ecore_wl_disp->wl.registry = _ecore_wl_disp->wl.registry =
wl_display_get_registry(_ecore_wl_disp->wl.display); wl_display_get_registry(_ecore_wl_disp->wl.display);
wl_registry_add_listener(_ecore_wl_disp->wl.registry, wl_registry_add_listener(_ecore_wl_disp->wl.registry,
&_ecore_wl_registry_listener, _ecore_wl_disp); &_ecore_wl_registry_listener, _ecore_wl_disp);
wl_display_dispatch(_ecore_wl_disp->wl.display); wl_display_dispatch(_ecore_wl_disp->wl.display);
@ -171,16 +171,16 @@ ecore_wl_init(const char *name)
/** /**
* Shuts down the Ecore Wayland Library * Shuts down the Ecore Wayland Library
* *
* In shutting down the library, the Wayland display connection is terminated * In shutting down the library, the Wayland display connection is terminated
* and any event handlers for it are removed. * and any event handlers for it are removed.
* *
* @return The number of times the library has been initialized without * @return The number of times the library has been initialized without
* being shut down. * being shut down.
* *
* @ingroup Ecore_Wl_Init_Group * @ingroup Ecore_Wl_Init_Group
*/ */
EAPI int EAPI int
ecore_wl_shutdown(void) ecore_wl_shutdown(void)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -190,18 +190,18 @@ ecore_wl_shutdown(void)
/** /**
* @defgroup Ecore_Wl_Flush_Group Wayland Synchronization Functions * @defgroup Ecore_Wl_Flush_Group Wayland Synchronization Functions
* *
* Functions that ensure that all commands which have been issued by the * Functions that ensure that all commands which have been issued by the
* Ecore Wayland library have been sent to the server. * Ecore Wayland library have been sent to the server.
*/ */
/** /**
* Sends all Wayland commands to the Wayland Display. * Sends all Wayland commands to the Wayland Display.
* *
* @ingroup Ecore_Wl_Flush_Group * @ingroup Ecore_Wl_Flush_Group
* @since 1.2 * @since 1.2
*/ */
EAPI void EAPI void
ecore_wl_flush(void) ecore_wl_flush(void)
{ {
// LOGFN(__FILE__, __LINE__, __FUNCTION__); // LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -210,13 +210,13 @@ ecore_wl_flush(void)
} }
/** /**
* Flushes the command buffer and waits until all requests have been * Flushes the command buffer and waits until all requests have been
* processed by the server. * processed by the server.
* *
* @ingroup Ecore_Wl_Flush_Group * @ingroup Ecore_Wl_Flush_Group
* @since 1.2 * @since 1.2
*/ */
EAPI void EAPI void
ecore_wl_sync(void) ecore_wl_sync(void)
{ {
// LOGFN(__FILE__, __LINE__, __FUNCTION__); // LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -226,15 +226,15 @@ ecore_wl_sync(void)
/** /**
* @defgroup Ecore_Wl_Display_Group Wayland Display Functions * @defgroup Ecore_Wl_Display_Group Wayland Display Functions
* *
* Functions that set and retrieve various information about the Wayland Display. * Functions that set and retrieve various information about the Wayland Display.
*/ */
/** /**
* Retrieves the Wayland Shm Interface used for the current Wayland connection. * Retrieves the Wayland Shm Interface used for the current Wayland connection.
* *
* @return The current wayland shm interface * @return The current wayland shm interface
* *
* @ingroup Ecore_Wl_Display_Group * @ingroup Ecore_Wl_Display_Group
* @since 1.2 * @since 1.2
*/ */
@ -246,9 +246,9 @@ ecore_wl_shm_get(void)
/** /**
* Retrieves the Wayland Display Interface used for the current Wayland connection. * Retrieves the Wayland Display Interface used for the current Wayland connection.
* *
* @return The current wayland display interface * @return The current wayland display interface
* *
* @ingroup Ecore_Wl_Display_Group * @ingroup Ecore_Wl_Display_Group
* @since 1.2 * @since 1.2
*/ */
@ -260,14 +260,14 @@ ecore_wl_display_get(void)
/** /**
* Retrieves the size of the current screen. * Retrieves the size of the current screen.
* *
* @param w where to return the width. May be NULL. Returns 0 on error. * @param w where to return the width. May be NULL. Returns 0 on error.
* @param h where to return the height. May be NULL. Returns 0 on error. * @param h where to return the height. May be NULL. Returns 0 on error.
* *
* @ingroup Ecore_Wl_Display_Group * @ingroup Ecore_Wl_Display_Group
* @since 1.2 * @since 1.2
*/ */
EAPI void EAPI void
ecore_wl_screen_size_get(int *w, int *h) ecore_wl_screen_size_get(int *w, int *h)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -282,7 +282,7 @@ ecore_wl_screen_size_get(int *w, int *h)
} }
/* @since 1.2 */ /* @since 1.2 */
EAPI void EAPI void
ecore_wl_pointer_xy_get(int *x, int *y) ecore_wl_pointer_xy_get(int *x, int *y)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -298,10 +298,10 @@ ecore_wl_pointer_xy_get(int *x, int *y)
* xrandr where different parts of the screen may have different DPI etc. * xrandr where different parts of the screen may have different DPI etc.
* *
* @return the general screen DPI (dots/pixels per inch). * @return the general screen DPI (dots/pixels per inch).
* *
* @since 1.2 * @since 1.2
*/ */
EAPI int EAPI int
ecore_wl_dpi_get(void) ecore_wl_dpi_get(void)
{ {
int w, mw; int w, mw;
@ -314,12 +314,12 @@ ecore_wl_dpi_get(void)
if (mw <= 0) return 75; if (mw <= 0) return 75;
w = _ecore_wl_disp->output->allocation.w; w = _ecore_wl_disp->output->allocation.w;
/* FIXME: NB: Hrrrmmm, need to verify this. xorg code is using a different /* FIXME: NB: Hrrrmmm, need to verify this. xorg code is using a different
* formula to calc this */ * formula to calc this */
return (((w * 254) / mw) + 5) / 10; return (((w * 254) / mw) + 5) / 10;
} }
EAPI void EAPI void
ecore_wl_display_iterate(void) ecore_wl_display_iterate(void)
{ {
wl_display_dispatch(_ecore_wl_disp->wl.display); wl_display_dispatch(_ecore_wl_disp->wl.display);
@ -327,7 +327,7 @@ ecore_wl_display_iterate(void)
/** /**
* Retrieves the requested cursor from the cursor theme * Retrieves the requested cursor from the cursor theme
* *
* @param cursor_name The desired cursor name to be looked up in the theme * @param cursor_name The desired cursor name to be looked up in the theme
* @return the cursor or NULL if the cursor cannot be found * @return the cursor or NULL if the cursor cannot be found
* *
@ -336,7 +336,7 @@ ecore_wl_display_iterate(void)
EAPI struct wl_cursor * EAPI struct wl_cursor *
ecore_wl_cursor_get(const char *cursor_name) ecore_wl_cursor_get(const char *cursor_name)
{ {
if ((!_ecore_wl_disp) || (!_ecore_wl_disp->cursor_theme)) if ((!_ecore_wl_disp) || (!_ecore_wl_disp->cursor_theme))
return NULL; return NULL;
return wl_cursor_theme_get_cursor(_ecore_wl_disp->cursor_theme, return wl_cursor_theme_get_cursor(_ecore_wl_disp->cursor_theme,
@ -344,7 +344,7 @@ ecore_wl_cursor_get(const char *cursor_name)
} }
/* local functions */ /* local functions */
static Eina_Bool static Eina_Bool
_ecore_wl_shutdown(Eina_Bool close) _ecore_wl_shutdown(Eina_Bool close)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -354,10 +354,10 @@ _ecore_wl_shutdown(Eina_Bool close)
_ecore_wl_window_shutdown(); _ecore_wl_window_shutdown();
if (_ecore_wl_disp->fd_hdl) if (_ecore_wl_disp->fd_hdl)
ecore_main_fd_handler_del(_ecore_wl_disp->fd_hdl); ecore_main_fd_handler_del(_ecore_wl_disp->fd_hdl);
if (close) if (close)
{ {
Ecore_Wl_Output *out, *tout; Ecore_Wl_Output *out, *tout;
Ecore_Wl_Input *in, *tin; Ecore_Wl_Input *in, *tin;
@ -370,7 +370,7 @@ _ecore_wl_shutdown(Eina_Bool close)
_ecore_wl_xkb_shutdown(_ecore_wl_disp); _ecore_wl_xkb_shutdown(_ecore_wl_disp);
if (_ecore_wl_disp->wl.shell) if (_ecore_wl_disp->wl.shell)
wl_shell_destroy(_ecore_wl_disp->wl.shell); wl_shell_destroy(_ecore_wl_disp->wl.shell);
if (_ecore_wl_disp->wl.shm) wl_shm_destroy(_ecore_wl_disp->wl.shm); if (_ecore_wl_disp->wl.shm) wl_shm_destroy(_ecore_wl_disp->wl.shm);
if (_ecore_wl_disp->wl.data_device_manager) if (_ecore_wl_disp->wl.data_device_manager)
@ -396,7 +396,7 @@ _ecore_wl_shutdown(Eina_Bool close)
return _ecore_wl_init_count; return _ecore_wl_init_count;
} }
static Eina_Bool static Eina_Bool
_ecore_wl_cb_handle_data(void *data, Ecore_Fd_Handler *hdl) _ecore_wl_cb_handle_data(void *data, Ecore_Fd_Handler *hdl)
{ {
Ecore_Wl_Display *ewd; Ecore_Wl_Display *ewd;
@ -417,7 +417,7 @@ _ecore_wl_cb_handle_data(void *data, Ecore_Fd_Handler *hdl)
return ECORE_CALLBACK_RENEW; return ECORE_CALLBACK_RENEW;
} }
static void static void
_ecore_wl_cb_handle_global(void *data, struct wl_registry *registry, unsigned int id, const char *interface, unsigned int version EINA_UNUSED) _ecore_wl_cb_handle_global(void *data, struct wl_registry *registry, unsigned int id, const char *interface, unsigned int version EINA_UNUSED)
{ {
Ecore_Wl_Display *ewd; Ecore_Wl_Display *ewd;
@ -428,7 +428,7 @@ _ecore_wl_cb_handle_global(void *data, struct wl_registry *registry, unsigned in
if (!strcmp(interface, "wl_compositor")) if (!strcmp(interface, "wl_compositor"))
{ {
ewd->wl.compositor = ewd->wl.compositor =
wl_registry_bind(registry, id, &wl_compositor_interface, 1); wl_registry_bind(registry, id, &wl_compositor_interface, 1);
} }
else if (!strcmp(interface, "wl_output")) else if (!strcmp(interface, "wl_output"))
@ -437,20 +437,20 @@ _ecore_wl_cb_handle_global(void *data, struct wl_registry *registry, unsigned in
_ecore_wl_input_add(ewd, id); _ecore_wl_input_add(ewd, id);
else if (!strcmp(interface, "wl_shell")) else if (!strcmp(interface, "wl_shell"))
{ {
ewd->wl.shell = ewd->wl.shell =
wl_registry_bind(registry, id, &wl_shell_interface, 1); wl_registry_bind(registry, id, &wl_shell_interface, 1);
} }
else if (!strcmp(interface, "wl_shm")) else if (!strcmp(interface, "wl_shm"))
{ {
ewd->wl.shm = wl_registry_bind(registry, id, &wl_shm_interface, 1); ewd->wl.shm = wl_registry_bind(registry, id, &wl_shm_interface, 1);
/* FIXME: We should not hard-code a cursor size here, and we should /* FIXME: We should not hard-code a cursor size here, and we should
* also import the theme name from a config or env variable */ * also import the theme name from a config or env variable */
ewd->cursor_theme = wl_cursor_theme_load(NULL, 32, ewd->wl.shm); ewd->cursor_theme = wl_cursor_theme_load(NULL, 32, ewd->wl.shm);
} }
else if (!strcmp(interface, "wl_data_device_manager")) else if (!strcmp(interface, "wl_data_device_manager"))
{ {
ewd->wl.data_device_manager = ewd->wl.data_device_manager =
wl_registry_bind(registry, id, &wl_data_device_manager_interface, 1); wl_registry_bind(registry, id, &wl_data_device_manager_interface, 1);
} }
@ -469,7 +469,7 @@ _ecore_wl_cb_handle_global(void *data, struct wl_registry *registry, unsigned in
} }
} }
static Eina_Bool static Eina_Bool
_ecore_wl_xkb_init(Ecore_Wl_Display *ewd) _ecore_wl_xkb_init(Ecore_Wl_Display *ewd)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);
@ -480,7 +480,7 @@ _ecore_wl_xkb_init(Ecore_Wl_Display *ewd)
return EINA_TRUE; return EINA_TRUE;
} }
static Eina_Bool static Eina_Bool
_ecore_wl_xkb_shutdown(Ecore_Wl_Display *ewd) _ecore_wl_xkb_shutdown(Ecore_Wl_Display *ewd)
{ {
LOGFN(__FILE__, __LINE__, __FUNCTION__); LOGFN(__FILE__, __LINE__, __FUNCTION__);