Hi Ken,

I try to answer you questions to make it more understandable.

1) "changeSelection" always appear when the selection changed, also when a _selected_ item is removed from the SelectBox. The reason for that is the selection manager. The manager doesn't allow a empty selection on SelectBox and selected the next child, which triggers a "changeSelection" event.

When your implementation removes the items from first to last. Then this will happen -> the implementation removes the current selected item -> the manager selected the next child, which triggers an event -> the implementation removes the current selected item -> the manager selected the next, and so on. You can avoid this when you are remove the items from last to first or configure the manager to allow empty selection in the removing phase.

2) The deprecation warning on disabled widget. The warning is fired from the selection mixin and it it's general. In the past we saw a different behavior with disabled widgets. Some widgets allow a selection change and some not on disabled widgets. That's the reason, why a deprecation warning is fired from disabled SelectBox. But so fare as I know the SelectBox is one of the widget which has already the correct behavior.

3) Yes, the output from qx.log.Logger is due to the deprecation warning.

4) Sorry, you can't suppress the deprecation warning.

5) Deprecations warnings are only logged in the source version from your application. The build version is doesn't log deprecations warnings, so there are no negative effects on runtime.

Cheers,
Chris

Am 25.05.2010 06:27, schrieb Kenneth Tilton:
Two qualities of a SelectBox I have in my app seem to be in conflict:
(a) sometimes it is disabled depending on other user input
(b) the items offered by the SelectBox vary as other input fields change.

Th conflict: What I see is that changeSelection events are firing
because (I guess!) I am adding/deleting items and (I guess!) that act
itself causes qooxdoo to change the selection. That is understandable.

But! This is going on even when the select box is disabled, at which
point two things happen:

-- in the debugger I see an informational saying changing the selection
of a disabled SelectBox is deprecated. By induction, also deprecated is
altering the SelectBox list of choices (since that can trigger
changeSelection events).

In trying to think of how I can work around this, I find myself trying
to understand the thinking here: why is it a problem altering the
selection of a SelectBox when it is disabled, or in this case updating
the items offered by a SelectBox?

-- in the debugger I also see a ton of output from qx.log.Logger. Is
that a consequence of the deprecated behavior? Can the output be
suppressed? Or is it not a problem: as long as the debugger console is
not open, the logger will be inactive?

cheers, ken



--
Christian Hagendorn
Software Entwickler

1&1 Internet AG - Web Technologies
Ernst-Frey-Straße 9 · DE-76135 Karlsruhe

Amtsgericht Montabaur / HRB 6484
Vorstände: Henning Ahlert, Ralph Dommermuth, Matthias Ehrlich, Thomas 
Gottschlich, Robert Hoffmann, Markus Huhn, Hans-Henning Kettler, Dr. Oliver 
Mauss, Gert Nowotny, Jan Oetjen
Aufsichtsratsvorsitzender: Michael Scheeren

------------------------------------------------------------------------------

_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to