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

git pushed a commit to branch edje-vector-intergration
in repository efl.

View the commit online.

commit b403d9e3506ef18290c4417940670636248441ec
Author: [email protected] <[email protected]>
AuthorDate: Mon Apr 27 17:28:12 2026 -0600

    edje: extend vector part struct for state-animation (Task 1.2)
    
    Edje_Part_Description_Spec_Svg gains tree_id (file index, -1=legacy)
    and per-node overrides list. Edje_Real_Part_Vector gains cached base
    tree, cache valid sentinel, and color-class dirty flag for Phase 3
    rendering. Edje_File gains vector_dir pointer for per-file tree data
    (populated in Task 1.4). Forward typedef avoids reordering existing
    declarations. Sentinels (-1 for indices, NULL for pointers) are
    mandatory because 0 is a valid tree index.
    
    Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
---
 src/bin/edje/edje_cc_handlers.c |  3 +++
 src/lib/edje/edje_load.c        |  7 ++++++-
 src/lib/edje/edje_private.h     | 25 ++++++++++++++++++++-----
 3 files changed, 29 insertions(+), 6 deletions(-)

diff --git a/src/bin/edje/edje_cc_handlers.c b/src/bin/edje/edje_cc_handlers.c
index ac4be862a6..5f2657d598 100644
--- a/src/bin/edje/edje_cc_handlers.c
+++ b/src/bin/edje/edje_cc_handlers.c
@@ -1836,6 +1836,9 @@ _edje_part_description_alloc(unsigned char type, const char *collection, const c
 
          ed = mem_alloc(SZ(Edje_Part_Description_Vector));
 
+         ed->vg.tree_id = -1;
+         ed->vg.overrides = NULL;
+
          result = &ed->common;
          break;
       }
diff --git a/src/lib/edje/edje_load.c b/src/lib/edje/edje_load.c
index 24d1550faa..7d4d092eee 100644
--- a/src/lib/edje/edje_load.c
+++ b/src/lib/edje/edje_load.c
@@ -999,7 +999,12 @@ _edje_object_file_set_internal(Evas_Object *obj, const Eina_File *file, const ch
                        if (!rp->typedata.vector)
                          memerr = EINA_TRUE;
                        else
-                         rp->typedata.vector->current_id = -1;
+                         {
+                            rp->typedata.vector->current_id = -1;
+                            rp->typedata.vector->cached_tree_id = -1;
+                            rp->typedata.vector->cached_base_tree = NULL;
+                            rp->typedata.vector->classes_dirty = 0;
+                         }
                        break;
 
                      default:
diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h
index be86feeafe..0d2f019130 100644
--- a/src/lib/edje/edje_private.h
+++ b/src/lib/edje/edje_private.h
@@ -531,12 +531,16 @@ typedef struct Edje_Image_Hash
    int id;
 } Edje_Image_Hash;
 
+/* Forward declaration — full definition follows the VG data-model block. */
+typedef struct _Edje_Vg_Directory Edje_Vg_Directory;
+
 struct _Edje_File
 {
    const char                     *path;
 
    Edje_External_Directory        *external_dir;
    Edje_Image_Directory           *image_dir;
+   Edje_Vg_Directory              *vector_dir;
    Edje_Model_Directory           *model_dir;
    Edje_Sound_Directory           *sound_dir;
    Edje_Vibration_Directory       *vibration_dir;
@@ -1605,10 +1609,13 @@ struct _Edje_Part_Description_Spec_Table
 
 struct _Edje_Part_Description_Spec_Svg
 {
-   int                   id; /* the svg id to use */
-   Eina_Bool             set; /* if vg condition it's content */
+   int                   id;        /* the svg id to use */
+   Eina_Bool             set;       /* if vg condition it's content */
    Edje_Vector_File_Type type;
    double                frame;
+   /* Mode A/B — index into vector_dir->trees, -1 if Mode C/none */
+   int                   tree_id;
+   Eina_List            *overrides; /* of Edje_Vg_Override*, source order */
 };
 
 struct _Edje_Part_Description_Image
@@ -2019,9 +2026,17 @@ struct _Edje_Real_Part_Vector
    char      *lottie_data;
    int        start_frame;
    int        current_id;
-   Eina_Bool  backward : 1;
-   Eina_Bool  loop : 1;
-   Eina_Bool  is_playing : 1;
+   Eina_Bool  backward     : 1;
+   Eina_Bool  loop         : 1;
+   Eina_Bool  is_playing   : 1;
+   /* Phase 4 cache — cached_base_tree is a const pointer into
+      ed->file->vector_dir->trees (not an owned ref).
+      cached_tree_id == -1 means the cache is invalid.
+      classes_dirty is set by color-class observer callbacks and
+      cleared on recalc. */
+   const Edje_Vg_Tree *cached_base_tree;
+   int                 cached_tree_id;
+   Eina_Bool           classes_dirty : 1;
 };
 
 struct _Edje_Real_Part

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

Reply via email to