Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hey, Thanks for opening the bug and the discussion at all. :) You see, we did get a two bugs out of it which is good for you as developer and me as framework responsible. :D So I take care of it after the upcoming 1.2 release. (too much left to do for the upcoming release). Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5312317.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
> If thats working, we should take a closer look at this. Andreas, could you > open up a bug report for that? Done: http://bugzilla.qooxdoo.org/show_bug.cgi?id=3881 > But still if thats working, we need to do it > carefully because we catch every exception in the code which can be quite > huge. It should be possible to check if it's a "too much recursion" exception and only handle this one in a special way. Every other exception should be re-thrown. Regards, Andreas -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
If thats working, we should take a closer look at this. Andreas, could you open up a bug report for that? But still if thats working, we need to do it carefully because we catch every exception in the code which can be quite huge. -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5311925.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
> Fink, Andreas wrote:
> >
> > Is it possible to catch the "too much recursion" exception inside
the List
> > and give a better exception description if the problem relies to
> > duplicated models?
> >
> Interesting idea. But I'm not sure if this kind of exception can be
cough.
> Have you ever tried to catch a "too much recursion" exception?
Not yet but the following playground example is promising :)
var errorProducingFunction = function() {
while (true) {
errorProducingFunction();
}
};
try {
errorProducingFunction();
}
catch(ex) {
alert("catched " +ex);
throw "my new exception from too much recursion";
}
Regards,
Andreas
--
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
___
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hey Andreas, Fink, Andreas wrote: > > Is it possible to catch the "too much recursion" exception inside the List > and give a better exception description if the problem relies to > duplicated models? > Interesting idea. But I'm not sure if this kind of exception can be cough. Have you ever tried to catch a "too much recursion" exception? Fink, Andreas wrote: > > P.S.: By the way, a big compliment to you and the other persons of the > support team. Somewhere else such threads would be marked as not worth > discussing. > The support team is the whole code team. ;) The discussions come to a good solution most of the time (like this by fixing the documentation). So we think its worth the time. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5311527.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hi Martin, you're right that's too much overhead. Another idea and I promise it's the last one to not let us end up in a personal war about this topic. :D Is it possible to catch the "too much recursion" exception inside the List and give a better exception description if the problem relies to duplicated models? Maybe a model property check in the catch block with a simple loop through all ListItems could then throw a more specific exception, something like "Duplicated model found. The model property of each List item has to be unique." A better documentation would for sure give the most developers the ability to find the solution their own and would decrease the numbers of questions on the mailing list. So that's a good way to go :) Regards, Andreas P.S.: By the way, a big compliment to you and the other persons of the support team. Somewhere else such threads would be marked as not worth discussing. -Ursprüngliche Nachricht- Von: MartinWittemann [mailto:[email protected]] Gesendet: Montag, 19. Juli 2010 09:23 An: [email protected] Betreff: Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements Hello Andreas, Fink, Andreas wrote: > > Improving the documentation is for sure the first step :) > Right, I openend up a bug report for doing so. http://bugzilla.qooxdoo.org/show_bug.cgi?id=3875 Fink, Andreas wrote: > > Maybe you should look at it from another perspective: > Looking at the property description of model in the API tells us: > "Model property for storing additional information for the including > object. It can act as value property on form items for example." > Why it shouldn't be possible to have more than one item with the same > ADDITIONAL information (it could have other information, the label, some > userData, etc.), except of, it hits a "bug" in the framework? > Or in the documentation. ;) Fink, Andreas wrote: > > I only thought, maybe the framework could be improved a little bit, by > finding a way of working with such a construct or if there is no way, > could give a better support to the developer by not accepting things that > for sure end up in an hard to track bug. > Thats generally what we are trying to do. But in this case its hard to get that done because the list item has no connection to all the other list items. So only the container (select box e.g.) knows its children. That means that I need to attach (and remove) listener to all model property in the containers children and react on changes. This is way too much overhead for an edge case and a warning. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5310978.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hello Andreas, Fink, Andreas wrote: > > Improving the documentation is for sure the first step :) > Right, I openend up a bug report for doing so. http://bugzilla.qooxdoo.org/show_bug.cgi?id=3875 Fink, Andreas wrote: > > Maybe you should look at it from another perspective: > Looking at the property description of model in the API tells us: > "Model property for storing additional information for the including > object. It can act as value property on form items for example." > Why it shouldn't be possible to have more than one item with the same > ADDITIONAL information (it could have other information, the label, some > userData, etc.), except of, it hits a "bug" in the framework? > Or in the documentation. ;) Fink, Andreas wrote: > > I only thought, maybe the framework could be improved a little bit, by > finding a way of working with such a construct or if there is no way, > could give a better support to the developer by not accepting things that > for sure end up in an hard to track bug. > Thats generally what we are trying to do. But in this case its hard to get that done because the list item has no connection to all the other list items. So only the container (select box e.g.) knows its children. That means that I need to attach (and remove) listener to all model property in the containers children and react on changes. This is way too much overhead for an edge case and a warning. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5310978.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hi Martin, Improving the documentation is for sure the first step :) Qooxdoo does a great job, preventing developers of wrong API usage (type checks, allowed values, etc.) and I'm only talking about the SelectBox (or depending widgets) at the moment. Maybe you should look at it from another perspective: Looking at the property description of model in the API tells us: "Model property for storing additional information for the including object. It can act as value property on form items for example." Why it shouldn't be possible to have more than one item with the same ADDITIONAL information (it could have other information, the label, some userData, etc.), except of, it hits a "bug" in the framework? I absolutely confirm with you that the frameworks provided functionality is good enough for, let's say "every" use case. I only thought, maybe the framework could be improved a little bit, by finding a way of working with such a construct or if there is no way, could give a better support to the developer by not accepting things that for sure end up in an hard to track bug. Regards, Andreas -Ursprüngliche Nachricht- Von: MartinWittemann [mailto:[email protected]] Gesendet: Freitag, 16. Juli 2010 10:08 An: [email protected] Betreff: Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements Hey, Hm, so you are saying that the framework should prevent or warn on every wrong usage of the API no matter where in the framework? Thats a lot of work to do only for the cases someone is using the API in a way not intended, especially if there is no real use case for using the API this way. I think a hint in the documentations saying how to use the API should be enough. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5300909.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hey, Hm, so you are saying that the framework should prevent or warn on every wrong usage of the API no matter where in the framework? Thats a lot of work to do only for the cases someone is using the API in a way not intended, especially if there is no real use case for using the API this way. I think a hint in the documentations saying how to use the API should be enough. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5300909.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hi Martin, I certainly have no special use case for it. I only think that if the SelectBox or the List widget allows adding ListItems with identical models then it should work and not break the application with too much recursion. I only started this discussion because I hit this problem in the past and since then 2 or 3 other threads started on the mailing list depending to the same problem. So even if it is possible to cover all use cases of the community with the current implementation, very often framework users hit to this specific problem without knowing what they doing wrong. And if a user didn't know what he is doing wrong he suspects a framework bug and I say it is a framework bug because of the fact that the framework couldn't handle and even didn't avoid this :) Regards, Andreas -Ursprüngliche Nachricht- Von: MartinWittemann [mailto:[email protected]] Gesendet: Freitag, 16. Juli 2010 08:34 An: [email protected] Betreff: Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements Hello Andreas, curretly, the reason for that is technical based. We have a circular relation between the regular selection and the model selection which brings up this behavior. Could you explain why it should work and whats your use case for that? Maybe I'm just missing a thing and we should search for a fix on that issue. Currently its not clear to me why someone should have a list partly filled with models. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5300634.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hello Andreas, curretly, the reason for that is technical based. We have a circular relation between the regular selection and the model selection which brings up this behavior. Could you explain why it should work and whats your use case for that? Maybe I'm just missing a thing and we should search for a fix on that issue. Currently its not clear to me why someone should have a list partly filled with models. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5300634.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hi Martin, I'll try to explain it with a playground example: http://tinyurl.com/354tgct For me it is not clearly visible why the SelectBox works when selecting the first 5 ListItems and fails to select the last 5. Of course with the necessary background knowledge things getting clear but anyway I think this example shouldn't fail at least it shouldn't fail without giving the developer an exception or warning. Your feelings about my second example are right, it is nonsense :) Regards, Andreas -Ursprüngliche Nachricht- Von: MartinWittemann [mailto:[email protected]] Gesendet: Donnerstag, 15. Juli 2010 15:50 An: [email protected] Betreff: Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements Hello Andreas, Fink, Andreas wrote: > > If the model property of the ListItems is necessary for the SelectBox > to work,... > It is only necessary if you want to use the model selection. If you don't care about the model selection and the whole data binding stuff, you can just go without the model property. Fink, Andreas wrote: > > ... I think it should check this property for uniqueness and throw an > exception or at least gives a warning. > The current implementation only has references from the list to the list items which means we can not check with one list item if the model is unique. Thats a task the list would have to do but i'm not sure whats the benefit of that. Usually the model property is set by the binding controller which is in charge of that. Fink, Andreas wrote: > > Another idea is to set the model property of the ListItem to the label > value by default (if no model is provided during constructor call to > also allow null to set). I think this wouldn't break existing code and > increase the usability of both widgets. > Hm, I am not sure about that. In the first place, this sounds not a bad idea but somehow I have a bad feeling about it. Maybe its because I don't see the problem you are trying to solve with that. Maybe you can explain a little bit whats the problem with not having a model set. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5297450.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Re: [qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hello Andreas, Fink, Andreas wrote: > > If the model property of the ListItems is necessary for the SelectBox to > work,... > It is only necessary if you want to use the model selection. If you don't care about the model selection and the whole data binding stuff, you can just go without the model property. Fink, Andreas wrote: > > ... I think it should check this property for uniqueness and throw an > exception or at least gives a warning. > The current implementation only has references from the list to the list items which means we can not check with one list item if the model is unique. Thats a task the list would have to do but i'm not sure whats the benefit of that. Usually the model property is set by the binding controller which is in charge of that. Fink, Andreas wrote: > > Another idea is to set the model property of the ListItem to the label > value by default (if no model is provided during constructor call to also > allow null to set). I think this wouldn't break existing code and increase > the usability of both widgets. > Hm, I am not sure about that. In the first place, this sounds not a bad idea but somehow I have a bad feeling about it. Maybe its because I don't see the problem you are trying to solve with that. Maybe you can explain a little bit whats the problem with not having a model set. Regards, Martin -- View this message in context: http://qooxdoo.678.n2.nabble.com/Discussion-for-ListItem-SelectBox-improvements-tp5296939p5297450.html Sent from the qooxdoo mailing list archive at Nabble.com. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
[qooxdoo-devel] Discussion for ListItem/SelectBox improvements
Hi all, as I also had problems with the SelectBox before and I just want to start a discussion if the ListItem and/or SelectBox could be improved. If the model property of the ListItems is necessary for the SelectBox to work, I think it should check this property for uniqueness and throw an exception or at least gives a warning. Another idea is to set the model property of the ListItem to the label value by default (if no model is provided during constructor call to also allow null to set). I think this wouldn't break existing code and increase the usability of both widgets. Regards, Andreas -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
