This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch devs/devilhorns/apos
in repository efl.

View the commit online.

commit bb48cfc15b5dc17fee11b7ace781f99077c5a996
Author: Christopher Michael <devilho...@comcast.net>
AuthorDate: Wed Dec 7 08:08:34 2022 -0500

    ecore_drm2: Add API to return display name
---
 src/lib/ecore_drm2/Ecore_Drm2.h          | 5 +++++
 src/lib/ecore_drm2/ecore_drm2_displays.c | 8 ++++++++
 2 files changed, 13 insertions(+)

diff --git a/src/lib/ecore_drm2/Ecore_Drm2.h b/src/lib/ecore_drm2/Ecore_Drm2.h
index d1c602b7cf..2125b607e4 100644
--- a/src/lib/ecore_drm2/Ecore_Drm2.h
+++ b/src/lib/ecore_drm2/Ecore_Drm2.h
@@ -49,12 +49,17 @@ typedef struct _Ecore_Drm2_Device Ecore_Drm2_Device;
 /* API functions */
 EAPI int ecore_drm2_init(void);
 EAPI int ecore_drm2_shutdown(void);
+
+/* Device API functions */
 EAPI Ecore_Drm2_Device *ecore_drm2_device_open(const char *seat, unsigned int tty);
 EAPI void ecore_drm2_device_close(Ecore_Drm2_Device *dev);
 EAPI void ecore_drm2_device_cursor_size_get(Ecore_Drm2_Device *dev, int *width, int *height);
 EAPI void ecore_drm2_device_preferred_depth_get(Ecore_Drm2_Device *dev, int *depth, int *bpp);
 EAPI void ecore_drm2_device_screen_size_range_get(Ecore_Drm2_Device *dev, int *minw, int *minh, int *maxw, int *maxh);
 
+/* Display API functions */
+EAPI char *ecore_drm2_display_name_get(Ecore_Drm2_Display *disp);
+
 /* XXX: These are 'test' APIs */
 EAPI void ecore_drm2_display_mode_set(Ecore_Drm2_Display *disp, Ecore_Drm2_Display_Mode *mode, int x, int y);
 
diff --git a/src/lib/ecore_drm2/ecore_drm2_displays.c b/src/lib/ecore_drm2/ecore_drm2_displays.c
index f8bc9b21b4..ca576da4ef 100644
--- a/src/lib/ecore_drm2/ecore_drm2_displays.c
+++ b/src/lib/ecore_drm2/ecore_drm2_displays.c
@@ -526,6 +526,14 @@ _ecore_drm2_displays_destroy(Ecore_Drm2_Device *dev)
      }
 }
 
+EAPI char *
+ecore_drm2_display_name_get(Ecore_Drm2_Display *disp)
+{
+   EINA_SAFETY_ON_NULL_RETURN_VAL(disp, NULL);
+   EINA_SAFETY_ON_NULL_RETURN_VAL(disp->name, NULL);
+   return strdup(disp->name);
+}
+
 EAPI void
 ecore_drm2_display_mode_set(Ecore_Drm2_Display *disp, Ecore_Drm2_Display_Mode *mode, int x EINA_UNUSED, int y EINA_UNUSED)
 {

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to