*/
EAPI void ecore_drm_screen_size_range_get(Ecore_Drm_Device *dev, int *minw, int *minh, int *maxw, int *maxh);
+/**
+ * Get if a given output is connected
+ *
+ * @param output The Ecore_Drm_Output to get the connected status of
+ *
+ * @return EINA_TRUE if output is connected, EINA_FALSE otherwise
+ *
+ * @ingroup Ecore_Drm_Output_Group
+ * @since 1.15
+ */
+EAPI Eina_Bool ecore_drm_output_connected_get(Ecore_Drm_Output *output);
+
#ifdef __cplusplus
}
#endif
if (!(conn = drmModeGetConnector(dev->drm.fd, res->connectors[i])))
continue;
- if (conn->connection != DRM_MODE_CONNECTED) goto next;
+ /* if (conn->connection != DRM_MODE_CONNECTED) goto next; */
/* create output for this connector */
if (!(output =
_ecore_drm_output_create(dev, res, conn, x, y, EINA_FALSE)))
goto next;
+ output->connected = (conn->connection == DRM_MODE_CONNECTED);
+
x += output->current_mode->width;
next:
return strdup(output->name);
}
+
+EAPI Eina_Bool
+ecore_drm_output_connected_get(Ecore_Drm_Output *output)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(output, EINA_FALSE);
+
+ return output->connected;
+}