How about to add that printing warning in elm_widget?

On Thu, Apr 12, 2012 at 9:11 PM, Daniel Juyung Seo <seojuyu...@gmail.com> wrote:
> You are right. We need to document this.
> But this is also a notice for the e-dev. If there is no sign like this
> someone will add setter again some time later without noticing why it
> does not exist.
> Anyhow, I will document this.
> Thanks!
>
> Daniel Juyung Seo (SeoZ)
>
> On Thu, Apr 12, 2012 at 8:29 PM, ChunEon Park <her...@naver.com> wrote:
>>
>>
>> If you does not support those callbacks, then they does not need to be 
>> registered.
>> I think it's enough to update the document only.
>>
>>
>>
>> ------------------------------------
>>
>> -Regards, Hermet-
>>
>>
>>
>> -----Original Message-----
>> From: "Enlightenment SVN"&lt;no-re...@enlightenment.org&gt;
>> To: &lt;enlightenment-...@lists.sourceforge.net&gt;;
>> Cc:
>> Sent: 2012-04-12 (목) 16:14:21
>> Subject: E SVN: seoz trunk/elementary/src/lib
>>
>> Log:
>> elm genlist: genlist/gengrid do not support 
>> elm_object_item_part_text/content_set/unset. Use normal callback systems.
>>
>> Author:       seoz
>> Date:         2012-04-12 00:14:21 -0700 (Thu, 12 Apr 2012)
>> New Revision: 70122
>> Trac:         http://trac.enlightenment.org/e/changeset/70122
>>
>> Modified:
>>  trunk/elementary/src/lib/elm_genlist.c
>>
>> Modified: trunk/elementary/src/lib/elm_genlist.c
>> ===================================================================
>> --- trunk/elementary/src/lib/elm_genlist.c      2012-04-12 07:14:15 UTC (rev 
>> 70121)
>> +++ trunk/elementary/src/lib/elm_genlist.c      2012-04-12 07:14:21 UTC (rev 
>> 70122)
>> @@ -3638,29 +3638,21 @@
>>  }
>>
>>  static void
>> -_item_content_set_hook(Elm_Gen_Item *it, const char *part, Evas_Object 
>> *content)
>> +_item_content_set_hook(Elm_Gen_Item *it __UNUSED__,
>> +                       const char   *part __UNUSED__,
>> +                       Evas_Object  *content __UNUSED__)
>>  {
>> -   Evas_Object *prev_obj;
>> -
>> -   if (content &amp;&amp; part)
>> -     {
>> -        if (eina_list_data_find(it-&gt;content_objs, content)) return;
>> -        prev_obj = _item_content_unset_hook(it, part);
>> -        if (prev_obj) evas_object_del(prev_obj);
>> -        it-&gt;content_objs = eina_list_append(it-&gt;content_objs, 
>> content);
>> -        edje_object_part_swallow(VIEW(it), part, content);
>> -     }
>> +   WRN("genlist/gengrid do not support elm_object_item_part_content_set.\n"
>> +       "Use normal genlist/gengrid content_get callback model.");
>>  }
>>
>>  static Evas_Object *
>> -_item_content_unset_hook(Elm_Gen_Item *it, const char *part)
>> +_item_content_unset_hook(Elm_Gen_Item *it __UNUSED__,
>> +                         const char   *part __UNUSED__)
>>  {
>> -   Evas_Object *obj;
>> -   obj = edje_object_part_swallow_get(VIEW(it), part);
>> -   if (!obj) return NULL;
>> -   it-&gt;content_objs = eina_list_remove(it-&gt;content_objs, obj);
>> -   edje_object_part_unswallow(VIEW(it), obj);
>> -   return obj;
>> +   WRN("genlist/gengrid do not support elm_object_item_part_content_set.\n"
>> +       "Use normal genlist/gengrid content_get callback model.");
>> +   return NULL;
>>  }
>>
>>  static const char *
>> @@ -3671,6 +3663,15 @@
>>  }
>>
>>  static void
>> +_item_text_set_hook(Elm_Object_Item *it __UNUSED__,
>> +                    const char      *part __UNUSED__,
>> +                    const char      *text __UNUSED__)
>> +{
>> +   WRN("genlist/gengrid do not support elm_object_item_part_text_set.\n"
>> +       "Use normal genlist/gengrid text_get callback model.");
>> +}
>> +
>> +static void
>>  _item_disable_hook(Elm_Object_Item *it)
>>  {
>>    Eina_List *l;
>> @@ -3762,6 +3763,7 @@
>>    elm_widget_item_content_set_hook_set(it, _item_content_set_hook);
>>    elm_widget_item_content_unset_hook_set(it, _item_content_unset_hook);
>>    elm_widget_item_text_get_hook_set(it, _item_text_get_hook);
>> +   elm_widget_item_text_set_hook_set(it, _item_text_set_hook);
>>    elm_widget_item_disable_hook_set(it, _item_disable_hook);
>>    elm_widget_item_del_pre_hook_set(it, _item_del_pre_hook);
>>    elm_widget_item_signal_emit_hook_set(it, _item_signal_emit_hook);
>>
>>
>> ------------------------------------------------------------------------------
>> For Developers, A Lot Can Happen In A Second.
>> Boundary is the first to Know...and Tell You.
>> Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
>> http://p.sf.net/sfu/Boundary-d2dvs2
>> _______________________________________________
>> enlightenment-svn mailing list
>> enlightenment-...@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/enlightenment-svn
>>
>>
>> ------------------------------------------------------------------------------
>> For Developers, A Lot Can Happen In A Second.
>> Boundary is the first to Know...and Tell You.
>> Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
>> http://p.sf.net/sfu/Boundary-d2dvs2
>> _______________________________________________
>> enlightenment-devel mailing list
>> enlightenment-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
> ------------------------------------------------------------------------------
> For Developers, A Lot Can Happen In A Second.
> Boundary is the first to Know...and Tell You.
> Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
> http://p.sf.net/sfu/Boundary-d2dvs2
> _______________________________________________
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to