MUIM_List_Insert: Should I see individual entries being added for a single large insert?

5 posts / 0 new
Last post
ChrisH
ChrisH's picture
Offline
Last seen: 2 years 1 month ago
Joined: 2010-12-07 20:22
MUIM_List_Insert: Should I see individual entries being added for a single large insert?
I was rather surprised to find that when doing a single MUIM_List_Insert call (with pos = MUIV_List_Insert_Sorted) to insert a large number of entries, I was able to see individual entries appearing in the list. I was expecting it to just suddenly appear with all the entries added. Is this what is supposed to happen? I tried setting MUIA_List_Quiet to true, but that didn't help :-( . Any suggestions?
ChrisH
ChrisH's picture
Offline
Last seen: 2 years 1 month ago
Joined: 2010-12-07 20:22
Just so people know:
Just so people know: Replacing List with NList solved my problem. So it seems that MUI 3.9's built-in List is either rubbish or bugged.

Author of the PortablE programming language. I love using Amiga OS4.1 on my X1000 & Sam440 :-D
tboeckel
tboeckel's picture
Offline
Last seen: 1 year 7 months ago
Joined: 2011-09-13 12:32
I just tried to reproduce
I just tried to reproduce this issue and for me it worked as expected. Something like this works perfectly here:
  1. <prepare an array of 100000 strings>
  2. set(list, MUIA_List_Quiet, TRUE);
  3. DoMethod(list, MUIM_List_Insert, array, 100000, MUIV_List_Insert_Sorted);
  4. set(list, MUIA_List_Quiet, FALSE);
It takes its time to insert 100000 strings, but there is no graphical update during the insert process. Even inserting single strings in a loop makes no difference, except taking a bit more time. So from my point of view all I can say is: what ever you did, you did it wrong. And since you didn't give any detailed example code I am unable to tell what you did wrong.
ChrisH
ChrisH's picture
Offline
Last seen: 2 years 1 month ago
Joined: 2010-12-07 20:22
That fact that my code worked
That fact that my code worked perfectly when I swapped List for NList seems to indicate my code is not bugged! Please note that I tested this on public MUI 3.9, rather than anything later. Something possibly related is that my list entries are not plain strings, but instead objects (with appropriate creation/comparison/destruction hooks defined). Perhaps that causes problems for List but not NList?

Author of the PortablE programming language. I love using Amiga OS4.1 on my X1000 & Sam440 :-D
tboeckel
tboeckel's picture
Offline
Last seen: 1 year 7 months ago
Joined: 2011-09-13 12:32
The fact that your programs
The fact that your programs works with NList.mcc does not automatically mean that List.mui is buggy or broken. NList was originally meant to be a 100% replacement for List.mui and accepts lots of attributes and methods known from List.mui. But there may be incompatibilities nevertheless which surface only if you switch back to List.mui. I can only repeat myself. Provide an example source which does not work for you and I will have a look at it. Without any reproducable facts from your side this problem will remain unsolved.
Log in or register to post comments