[Lazarus] @DBLookupControls users: call for test
Marcos Douglas
md at delfire.net
Mon Dec 12 17:25:08 CET 2011
On Mon, Dec 12, 2011 at 12:52 PM, Luiz Americo Pereira Camara
<luizmed at oi.com.br> wrote:
> On 12/12/2011 09:23, Marcos Douglas wrote:
>>
>> On Sat, Dec 10, 2011 at 11:15 AM, Luiz Americo Pereira Camara
>> <luizmed at oi.com.br> wrote:
>>>
>>> In order to fix some bugs i did significant changes in
>>> TDBLookup[List|Combo]Box controls
>>>
>>> I did a lot of testing but may broken something
>>>
>>> Please report problems you have
>>
>> I found a bug in TDBLookupComboBox
>> To reproduce:
>> 1. Define properties AutoComplete and AutoDropDown to True;
>> 2. Type a new value (the DropDown will open) that not exists in DataSet
>> (list);
>> 3. If you type ENTER the combo will clear, because no value on list
>> was found (OK);
>> 4. Repeat #2. Now if you type [Down] to select a item (use the
>> keyboard and don't type ENTER), but after type a new value that not
>> exists in DataSet list, the combo is not cleaned.
>>
>
> AFAIK this is the same behavior as before my changes.
No. I compared 2 apps using r34068 and r34129 and they have a
different comportment.
> It's a drawback from the decision to allow use the dropdown style (Delphi
> TDBLookupControl allows only dropdownlist, so no reference here what's the
> best approach)
I prefer csDropDownList, but AutoComplete only works using csDropDown!
And I need it.
> I think is not a good idea to clear the text the user entered. In the other
> side the control can have inconsistent values compared to dataset that is
> also not good.
I don't know if is good or not, but before this change the component
clean itself if the KeyValue is NULL.
> Let the other DBLookup users do an opinion. If they think this is the
> correct behavior i can implement that (clearing the text that does not exist
> in the list).
>
> For myself, i prefer to use dropdownlist, since the chance to user be
> confused is smaller.
If dropdownlist option works like TRxDBLookupCombo works in Delphi
7... would be very good.
> BTW:
> What's your widgetset?
Only Windows: Lazarus 0.9.31 r34129 FPC 2.5.1 i386-win32-win32/win64
> Pressing enter in either cases under win32 does not clear the content here.
> Just select the text
I think I wrote better in bug tracker:
1. Define properties AutoComplete and AutoDropDown to True;
2. Type a new value (the DropDown will open) that not exists in DataSet (list);
3. If you type ENTER the combo will clear, because no value on list
was found (OK);
4. Repeat 0000002. Now if you type [Down] to select a item (use the
keyboard and don't type ENTER), but after type a new value that not
exists in DataSet list and ENTER. The ComboBox is not cleaned.
Attention in:
+ AutoComplete and AutroDropDown;
+ Item #4: When the dropdown open, just click down (selecting a item)
but don't close it; after, type something that do not exists in list
and press ENTER. You see the Text typed still there.
Marcos Douglas
More information about the Lazarus
mailing list