On Wed, Mar 23, 2011 at 10:54 AM, cnook <[email protected]> wrote:
> Dear All,
>
Hey Shinwoo Kim,
> Thanks for your response.
>
> I have attached "elm_diskselector" patch using API and getting default value
> from theme.
> But the default value from "elementary/themes/default.edc" is applied only.
> If user wants new default value from his/her own theme file, it will not be
> applied.
>
>
> Why I have changed like this.. because there is one case I worry about
>
> [steps]
> 1. elm_diskselector_display_item_num_set(disk, 5)
> 2. elm_object_style_set(disk, "new/style"); // style has data.item
> "display_item_num" "7"
>
> In this case elm_diskselector will display 7 items.
So keep these values in different variables and prioritize the usage
of the value set with elm_diskselector_display_item_num_set over the
data.item in the theme_hook function. Or just keep a bool that is true
if the display_item_num was set by API
You need to consider the most simple case, that is just set a new
style that have a data.item != 3... It will be broken for this case,
if I understood you proposal correctly.
So, basically, you would have:
function display_item_num_set(value):
display_item_num_by_api = EINA_TRUE
display_item_num = value
function _theme_hook():
if (!display_item_num_by_api)
display_item_num = data_item_get()
>
>
> By the way.. you mean..
> 1. the newly defined default value should be applied?
> or
> 2. default value of default.edc is applied only? (attached patch)
>
> If you mean the first one, then both "Value from API" and "Value from
> Theme" will be supported. But I worry about above case and I'm not sure two
> ways should be coexisted.
The idea is that both ways will be supported, yeah.
Regards
>
> The second one.. it is also not meaningful..
>
> Ok, please let me now your opinion upon it. Thanks.
>
>
> Sincerely,
> Shinwoo Kim.
>
> 2011/3/22 Tom Hacohen <[email protected]>
>
>> Dear Shinwoo,
>>
>> Why did you ditch getting the data from the theme? I think my suggestion
>> is reasonable: use the data from the theme as the default value, and
>> allow people to override it from API. So it's essentially what you did
>> with just adding one line to the init of the object, to set
>> display_item_num from the theme...
>>
>> --
>> Tom.
>>
>> On Tue, 2011-03-22 at 19:36 +0900, cnook wrote:
>> > Dear All,
>> >
>> > Hello :)
>> >
>> > Thanks for your response.
>> > I have attached "elm_diskselector" patch using API and example code is
>> > also included.
>> > Please review this again. Thanks always.
>> >
>> > Sincerely,
>> > Shinwoo Kim.
>> >
>> > 2011/3/22 Tom Hacohen <[email protected]>
>> > You can load default from the theme and modify it with API...
>> >
>> >
>> > On Tue, 2011-03-22 at 13:47 +0900, Daniel Juyung Seo wrote:
>> > > Hello.
>> > >
>> > > > then several different theme file have to be existed. In
>> > this case, API
>> > > > would be more efficient.
>> > >
>> > > Hmm... you're right. It will be more flexible to use API for
>> > item count.
>> > > If we use previously suggested idea, we need to prepare many
>> > item
>> > > styles for several cases.
>> > > And that doesn't look that flexible.
>> > >
>> > > And one more comment.
>> > > You don't need to write separate sample application.
>> > > Just add the sample to elementary_test.
>> > >
>> > > Thanks.
>> > > Daniel Juyung Seo (SeoZ)
>> > >
>> > > On Mon, Mar 21, 2011 at 10:39 PM, cnook <[email protected]>
>> > wrote:
>> > > > Dear All,
>> > > >
>> > > > Hi~
>> > > > Thanks for your response always!
>> > > >
>> > > > I have changed the "elm_diskselector" based on your
>> > comments.
>> > > > The "displayed item count" is described by using theme
>> > file.
>> > > > And example source - example.tar.gz - have attached.
>> > > > (If you have an example of the example :), then please
>> > inform and send me.)
>> > > >
>> > > > By the way, I have something wondering about this way.
>> > > > If several "elm_diskselector" are added with different
>> > "displayed item
>> > > > count" on one same parent,
>> > > > then several different theme file have to be existed. In
>> > this case, API
>> > > > would be more efficient.
>> > > >
>> > > > I would like to know more about your opinion. Thanks
>> > > >
>> > > > Sincerely,
>> > > > Shinwoo Kim.
>> > > >
>> > > >
>> > > > 2011/3/19 Daniel Juyung Seo <[email protected]>
>> > > >>
>> > > >> Check the _theme_hook().
>> > > >> :)
>> > > >>
>> > > >> Thanks.
>> > > >> Daniel Juyung Seo (SeoZ)
>> > > >>
>> > > >> On Sat, Mar 19, 2011 at 1:53 PM, cnook
>> > <[email protected]> wrote:
>> > > >> > Dear All,
>> > > >> >
>> > > >> > Hi~
>> > > >> >
>> > > >> > Thanks for your response.
>> > > >> >
>> > > >> > I have tried to use "data.item" and
>> > edje_object_data_get() API. It works
>> > > >> > fine. :)
>> > > >> >
>> > > >> > But I met a problem. When I use a new style for
>> > elm_diskselector,
>> > > >> > edje_object_data_get() cannot retrieve "data.item" of
>> > new style.
>> > > >> >
>> > > >> > Only original (default) "data.item" value is retrieved.
>> > > >> >
>> > > >> > Would you please let me know what I forget?
>> > > >> >
>> > > >> > Thanks.
>> > > >> >
>> > > >> >
>> > > >> > Sincerely,
>> > > >> > Shinwoo Kim.
>> > > >> >
>> > > >> >
>> > > >> > 2011/3/18 Daniel Juyung Seo <[email protected]>
>> > > >> >>
>> > > >> >> +3 !
>> > > >> >> Using group data in theme looks better because it
>> > reduces source-gui
>> > > >> >> dependences.
>> > > >> >>
>> > > >> >> group { name: "xx";
>> > > >> >> data.item: "count" "3";
>> > > >> >>
>> > > >> >> You can fetch this data from c source using
>> > edje_object_data_get() API.
>> > > >> >> Please check other widgets for a reference.
>> > > >> >>
>> > > >> >> I checked the patch very briefly and here are some
>> > comments.
>> > > >> >>
>> > > >> >> 1. Indentation.
>> > > >> >> ex) line 250 in elm_diskselector.diff
>> > > >> >>
>> > > >> >> 2. Blank lines.
>> > > >> >> There are 2 blank lines at the end of diff file.
>> > 396, 397 lines.
>> > > >> >>
>> > > >> >> 3. Diff file.
>> > > >> >> I think there is no rule for this but you can merge
>> > two diff files
>> > > >> >> to one diff file
>> > > >> >> because they are patches for a one feature and one
>> > > >> >> library(elementary).
>> > > >> >>
>> > > >> >> 4. Sample code.
>> > > >> >> It will be better to have a sample code for a new
>> > feature in
>> > > >> >> elementary_test.
>> > > >> >>
>> > > >> >> Other than that, looks ok :)
>> > > >> >>
>> > > >> >> Thanks.
>> > > >> >> Daniel Juyung Seo (SeoZ)
>> > > >> >>
>> > > >> >> On Fri, Mar 18, 2011 at 5:57 AM, Tiago Falcao
>> > > >> >> <[email protected]>
>> > > >> >> wrote:
>> > > >> >> > +2 !
>> > > >> >> >
>> > > >> >> > When had see this widget in first time, I imagined
>> > it with option to
>> > > >> >> > many items but ever configured in theme.
>> > > >> >> > If i'm right, this widget is a lot dependent of code
>> > and less of
>> > > >> >> > theme
>> > > >> >> > :(
>> > > >> >> >
>> > > >> >> > What you thing about this, Shinwoo Kim?
>> > > >> >> > Gustavo suggested the easiest way, use group data.
>> > > >> >> >
>> > > >> >> > Thanks.
>> > > >> >> >
>> > > >> >> >
>> > > >> >> > On Thu, Mar 17, 2011 at 4:47 PM, Gustavo Sverzut
>> > Barbieri
>> > > >> >> > <[email protected]> wrote:
>> > > >> >> >> On Thu, Mar 17, 2011 at 7:42 PM, Bruno Dilly
>> > <[email protected]>
>> > > >> >> >> wrote:
>> > > >> >> >>> On Thu, Mar 17, 2011 at 10:45 AM, cnook
>> > <[email protected]> wrote:
>> > > >> >> >>>> Dear All,
>> > > >> >> >>>
>> > > >> >> >>> Hi Shinwoo Kim,
>> > > >> >> >>>
>> > > >> >> >>>>
>> > > >> >> >>>> This is Shinwoo Kim, learned that I could
>> > contribute to EFL! :)
>> > > >> >> >>>> I'm pleased to inform you that the patch for the
>> > > >> >> >>>> "elm_diskselector".
>> > > >> >> >>>>
>> > > >> >> >>>> Until now, the "elm_diskselector" only display 3
>> > items at once,
>> > > >> >> >>>> if you accept this patch, the "elm_diskselector"
>> > can display more
>> > > >> >> >>>> than 3
>> > > >> >> >>>> items.
>> > > >> >> >>>
>> > > >> >> >>> Displaying more than 3 items is a nice
>> > improvement.
>> > > >> >> >>> What do you think about the idea of getting the
>> > number of items to
>> > > >> >> >>> be
>> > > >> >> >>> displayed from the theme ?
>> > > >> >> >>>
>> > > >> >> >>> Anyway, there is a typo on documentation (param
>> > num). Maybe a
>> > > >> >> >>> getter
>> > > >> >> >>> could be useful as well.
>> > > >> >> >>
>> > > >> >> >> +1 to get it from theme!
>> > > >> >> >>
>> > > >> >> >> I did something similar for ephoto in some older
>> > version, it had
>> > > >> >> >> couple of swallow parts defined, like
>> > "elm.swallow.p%d", and a
>> > > >> >> >> data.item: "count" "3", thus it would fill 3
>> > swallows.
>> > > >> >> >>
>> > > >> >> >> I believe this is something up to the theme as it
>> > has the knowledge
>> > > >> >> >> on
>> > > >> >> >> how to pack more items.
>> > > >> >> >>
>> > > >> >> >>
>> > > >> >> >> --
>> > > >> >> >> Gustavo Sverzut Barbieri
>> > > >> >> >> http://profusion.mobi embedded systems
>> > > >> >> >> --------------------------------------
>> > > >> >> >> MSN: [email protected]
>> > > >> >> >> Skype: gsbarbieri
>> > > >> >> >> Mobile: +55 (19) 9225-2202
>> > > >> >> >>
>> > > >> >> >>
>> > > >> >> >>
>> > > >> >> >>
>> >
>> ------------------------------------------------------------------------------
>> > > >> >> >> Colocation vs. Managed Hosting
>> > > >> >> >> A question and answer guide to determining the best
>> > fit
>> > > >> >> >> for your organization - today and in the future.
>> > > >> >> >> http://p.sf.net/sfu/internap-sfd2d
>> > > >> >> >> _______________________________________________
>> > > >> >> >> enlightenment-devel mailing list
>> > > >> >> >> [email protected]
>> > > >> >> >>
>> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> > > >> >> >>
>> > > >> >> >
>> > > >> >> >
>> > > >> >> >
>> > > >> >> > --
>> > > >> >> > Tiago Rezende Campos Falcão
>> > > >> >> > http://www.tiagofalcao.com
>> > > >> >> > --
>> > > >> >> > ProFUSION | embedded systems
>> > > >> >> > Computer Systems Laboratory - IC - Unicamp
>> > > >> >> > Grupo Pró Software Livre - Unicamp
>> > > >> >> > Laboratory of Information Systems - IC - Unicamp
>> > > >> >> >
>> > > >> >> >
>> > > >> >> >
>> > > >> >> >
>> >
>> ------------------------------------------------------------------------------
>> > > >> >> > Colocation vs. Managed Hosting
>> > > >> >> > A question and answer guide to determining the best
>> > fit
>> > > >> >> > for your organization - today and in the future.
>> > > >> >> > http://p.sf.net/sfu/internap-sfd2d
>> > > >> >> > _______________________________________________
>> > > >> >> > enlightenment-devel mailing list
>> > > >> >> > [email protected]
>> > > >> >> >
>> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> > > >> >> >
>> > > >> >
>> > > >> >
>> > > >
>> > > >
>> > >
>> >
>> > >
>> >
>> ------------------------------------------------------------------------------
>> > > Enable your software for Intel(R) Active Management
>> > Technology to meet the
>> > > growing manageability and security demands of your
>> > customers. Businesses
>> > > are taking advantage of Intel(R) vPro (TM) technology - will
>> > your software
>> > > be a part of the solution? Download the Intel(R)
>> > Manageability Checker
>> > > today! http://p.sf.net/sfu/intel-dev2devmar
>> >
>> > > _______________________________________________
>> > > enlightenment-devel mailing list
>> > > [email protected]
>> > >
>> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> >
>> >
>> >
>> >
>>
>>
>>
>
> ------------------------------------------------------------------------------
> Enable your software for Intel(R) Active Management Technology to meet the
> growing manageability and security demands of your customers. Businesses
> are taking advantage of Intel(R) vPro (TM) technology - will your software
> be a part of the solution? Download the Intel(R) Manageability Checker
> today! http://p.sf.net/sfu/intel-dev2devmar
> _______________________________________________
> enlightenment-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>
------------------------------------------------------------------------------
Enable your software for Intel(R) Active Management Technology to meet the
growing manageability and security demands of your customers. Businesses
are taking advantage of Intel(R) vPro (TM) technology - will your software
be a part of the solution? Download the Intel(R) Manageability Checker
today! http://p.sf.net/sfu/intel-dev2devmar
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel