diff options
author | Cedric BAIL <cedric.bail@free.fr> | 2019-04-18 16:16:26 -0700 |
---|---|---|
committer | Marcel Hollerbach <mail@marcel-hollerbach.de> | 2019-04-21 11:36:46 +0200 |
commit | 3b0261d5524ab8edb870a6c48549a4afd38757d4 (patch) | |
tree | afc48c8b1d9edb4c10685282200a62bddcf51f5a /src/lib/eio | |
parent | ef4dde48a035006b9d4dcd083eca836402bc5735 (diff) |
eio: rely on inheritance and reflection for Efl.IoModel path property.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D8653
Diffstat (limited to 'src/lib/eio')
-rw-r--r-- | src/lib/eio/efl_io_model.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/lib/eio/efl_io_model.c b/src/lib/eio/efl_io_model.c index 300dac0..f5d4664 100644 --- a/src/lib/eio/efl_io_model.c +++ b/src/lib/eio/efl_io_model.c | |||
@@ -496,12 +496,6 @@ _property_filename_cb(const Eo *obj, Efl_Io_Model_Data *pd) | |||
496 | } | 496 | } |
497 | 497 | ||
498 | static Eina_Value * | 498 | static Eina_Value * |
499 | _property_path_cb(const Eo *obj EINA_UNUSED, Efl_Io_Model_Data *pd) | ||
500 | { | ||
501 | return eina_value_stringshare_new(pd->path); | ||
502 | } | ||
503 | |||
504 | static Eina_Value * | ||
505 | _property_direct_info_cb(const Eo *obj, Efl_Io_Model_Data *pd) | 499 | _property_direct_info_cb(const Eo *obj, Efl_Io_Model_Data *pd) |
506 | { | 500 | { |
507 | _efl_io_model_info_build(obj, pd); | 501 | _efl_io_model_info_build(obj, pd); |
@@ -620,7 +614,7 @@ static struct { | |||
620 | const char *name; | 614 | const char *name; |
621 | Eina_Value *(*cb)(const Eo *obj, Efl_Io_Model_Data *pd); | 615 | Eina_Value *(*cb)(const Eo *obj, Efl_Io_Model_Data *pd); |
622 | } properties[] = { | 616 | } properties[] = { |
623 | PP(filename), PP(path), | 617 | PP(filename), |
624 | PP(direct_info), | 618 | PP(direct_info), |
625 | PP(mtime), PP(atime), PP(ctime), PP(is_dir), PP(is_lnk), PP(size), | 619 | PP(mtime), PP(atime), PP(ctime), PP(is_dir), PP(is_lnk), PP(size), |
626 | PP(stat), | 620 | PP(stat), |
@@ -649,9 +643,7 @@ _efl_io_model_efl_model_property_get(const Eo *obj, Efl_Io_Model_Data *pd, const | |||
649 | !strcmp(property, properties[i].name)) | 643 | !strcmp(property, properties[i].name)) |
650 | return properties[i].cb(obj, pd); | 644 | return properties[i].cb(obj, pd); |
651 | 645 | ||
652 | ERR("Could not find property '%s'.", property); | 646 | return efl_model_property_get(efl_super(obj, EFL_IO_MODEL_CLASS), property); |
653 | // Unknow value request | ||
654 | return eina_value_error_new(EFL_MODEL_ERROR_NOT_SUPPORTED); | ||
655 | } | 647 | } |
656 | 648 | ||
657 | static Eina_Future * | 649 | static Eina_Future * |