Entraides et échanges autour de la technologie Scol - Informations and exchanges on the Scol technology
Vous pouvez changer la langue de l'interface une fois inscrit - You can change the language once registered
You are not logged in.
Hi,
There is maybe a little bug in the interface plugit "dialog list" (but maybe it comes from my configuration or misuse from my part).
Description:
You can fill the item dialog list "statically" by adding items directly in its window parameters before to play the scene:
It works fine and the result is this:
But you can also fill the items list dynamically on run by calling its action "Add element to list" (in this example i just use a button to call this action) :
I do it 3 times to add the same 3 elements than above. But then the size of the list item is not update and three little dots appears to indicate that not all items are displayed because dialog height is too small to show them all :
Origin of Problem:
In the plugit code (cdialoglist.pkg), the problem seems to come from the mecanism that should update the variables containing the item's list, but that don't work. In particular the number of items in the list is not update :
obstr.PDLGL_iNbElem
This var is used to compute the height of the dialog list, when it is created on show:
Ln285:
let 30 + (obstr.PDLGL_iNbElem * 36 + (obstr.PDLGL_iNbElem - 1) * oh) -> height in
But when you use action "Add element to list", this var is not update to the new number of items, so neither the height of the dialog that should grow accordingly.
The code of the action "Add element to list" is in :
fun cbAddElement(...):
which call differents functions of v3dui.pkg like:
VUIaddListElement & VUIunfoldListElement
Line 5543: fun VUIaddListElement(...)=
does different things to add the new item to list, then ask for an update of the dialoglist:
VUIelementNeedUpdate parentstr.VUILE_element 1;
I haven't yet the time to follow the rest of the code, but apparently the update mecanism of the dialog list is not done somehere and the dialoglist height stays as there was only one item in the list.
Maybe it is wanted as this, but i don't find a way to adjust the height of the dialog after it is created. Of course the height of the dialog box can't grow infinitely, but I think it should at least be able to grow to show 3 or 4 elements, as it is possible when doing it with first method.
Thank's for reading.
Last edited by ARappy (18-Sep-2019 21:20:14)
Offline
Offline