/* LCOV_EXCL_STOP */
}
+tdm_error
+tdm_client_handle_pending_events(tdm_client *client)
+{
+ tdm_private_client *private_client;
+
+ TDM_RETURN_VAL_IF_FAIL(client != NULL, TDM_ERROR_INVALID_PARAMETER);
+
+ /* LCOV_EXCL_START */
+ private_client = (tdm_private_client*)client;
+
+ pthread_mutex_lock(&private_client->lock);
+
+ if (CHECK_WL_PROTOCOL_ERROR(private_client)) {
+ pthread_mutex_unlock(&private_client->lock);
+ return TDM_ERROR_PROTOCOL_ERROR;
+ }
+
+ if (wl_display_dispatch_pending(private_client->display) < 0 ) {
+ pthread_mutex_unlock(&private_client->lock);
+ return TDM_ERROR_OPERATION_FAILED;
+ }
+
+ pthread_mutex_unlock(&private_client->lock);
+
+ return TDM_ERROR_NONE;
+ /* LCOV_EXCL_STOP */
+}
+
static int
_tdm_client_poll(struct wl_display *display, short int events, int timeout)
{
tdm_client_handle_events_timeout(tdm_client *client, int ms_timeout);
/**
+ * @brief Handle the pending events of the given tdm_client
+ * @param[in] client A TDM client object
+ * @return #TDM_ERROR_NONE if success. Otherwise, error value.
+ * @see #tdm_client_get_fd
+ */
+tdm_error
+tdm_client_handle_pending_events(tdm_client *client);
+
+/**
* @brief @b Deprecated. Wait for VBLANK.
* @deprecated
* @details After interval vblanks, a client vblank handler will be called.