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

git pushed a commit to branch master
in repository efl.

View the commit online.

commit 1b032268faf7af8b48ee487f7c9176e0ba3d228a
Author: Carsten Haitzler <ras...@rasterman.com>
AuthorDate: Fri Jul 18 13:48:28 2025 +0100

    x + elm: keep commentsi in uri-list so they can be used
    
    in elm prefix them with " //..//" to make them unlikely to conflict
    with file paths ever.
---
 src/lib/ecore_x/ecore_x_selection.c             |  7 ++++---
 src/modules/ecore_evas/engines/x/ecore_evas_x.c | 22 +++++++++++++++++-----
 2 files changed, 21 insertions(+), 8 deletions(-)

diff --git a/src/lib/ecore_x/ecore_x_selection.c b/src/lib/ecore_x/ecore_x_selection.c
index de4c91abd5..14e34eeedd 100644
--- a/src/lib/ecore_x/ecore_x_selection.c
+++ b/src/lib/ecore_x/ecore_x_selection.c
@@ -793,9 +793,10 @@ _ecore_x_selection_parser_files(const char *target,
         is = 0;
         while ((is < size) && (data[is]))
           {
-             if ((i == 0) && (data[is] == '#'))
-               for (; ((data[is]) && (data[is] != '\n')); is++) ;
-             else
+// keep comments as files so elm can provide them in the file list
+//             if ((i == 0) && (data[is] == '#'))
+//               for (; ((data[is]) && (data[is] != '\n')); is++) ;
+//             else
                {
                   if ((data[is] != '\r') &&
                       (data[is] != '\n'))
diff --git a/src/modules/ecore_evas/engines/x/ecore_evas_x.c b/src/modules/ecore_evas/engines/x/ecore_evas_x.c
index 659870c90d..18dc41a1c3 100644
--- a/src/modules/ecore_evas/engines/x/ecore_evas_x.c
+++ b/src/modules/ecore_evas/engines/x/ecore_evas_x.c
@@ -3893,15 +3893,27 @@ _deliver_content(Ecore_Evas *ee, Ecore_Evas_Engine_Data_X11 *edata, Ecore_Evas_S
 
         for (i = 0; i < files->num_files ; i++)
           {
-             uri = efreet_uri_decode(files->files[i]);
-             if (uri)
+             const char *f = files->files[i];
+
+             if (f[0] == '#') // a comment!
                {
-                  eina_strbuf_append(strbuf, uri->path);
-                  efreet_uri_free(uri);
+                 // add " //..//COMMENT\n" as files beginning with space
+                 // not likely and then //..// even less likely
+                 eina_strbuf_append(strbuf, " //..//");
+                 eina_strbuf_append(strbuf, f);
                }
              else
                {
-                  eina_strbuf_append(strbuf, files->files[i]);
+                  uri = efreet_uri_decode(f);
+                  if (uri)
+                    {
+                       eina_strbuf_append(strbuf, uri->path);
+                       efreet_uri_free(uri);
+                    }
+                 else
+                    {
+                       eina_strbuf_append(strbuf, f);
+                    }
                }
              if (i < (files->num_files - 1))
                eina_strbuf_append(strbuf, "\n");

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

Reply via email to