Re: Seaside design issue
Esteban Maringolo <[email protected]> Thu, 31 Aug 2023 09:07:27 -0300
| Newsgroups | gmane.comp.lang.smalltalk.squeak.seaside |
|---|---|
| Message-ID | <CAJMgPCKp930qCw-ENYT89fpNYj1gwDsChrWJXv31hyG+Sk2v9w@mail.gmail.com> |
--===============8565128406700719614== Content-Type: multipart/alternative; boundary="00000000000065fffb060436e5a3" --00000000000065fffb060436e5a3 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Annick, Either if you create a component that renders an anchor with a callback for each object or if you render a list or a table full with a callback to each of them, all these callbacks are going to be added to the callback registry (WACallbackRegistry). Depending on how you architecture your app (more or less AJAX oriented) you could use something like JS's #callback:passenger: helper method. But if your purpose is to drive a full page call/answer: then AJAX would not be an option there. As for leaking callbacks, have you found any or profiled the memory to confirm that it is leaking somewhere? Best regards, Esteban A. Maringolo On Thu, Aug 31, 2023 at 7:19=E2=80=AFAM Annick Fron <[email protected]> wr= ote: > Hi, > > I use tables with items and use anchors for item lines to perform > some particular action on an item. This action is for instance to call a > specific component on that item. > > If I have numerous items, I am worried about the number of > callbacks piling in and not being garbaged. > > Is it preferable to create a component per item holding only one > callback ? > > Annick > _______________________________________________ > seaside mailing list -- [email protected] > To unsubscribe send an email to [email protected] > --00000000000065fffb060436e5a3 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>Hi Annick,</div><div><br></div><div>Either if you cre= ate a component that renders an anchor with a callback for each object or i= f you render a list or a table full with a callback to each of them, all th= ese callbacks are going=C2=A0to be added to the callback registry (WACallba= ckRegistry).</div><div><br></div><div>Depending on how you architecture you= r app (more or less AJAX oriented) you could use something like JS's #c= allback:passenger: helper method. But if your purpose is to drive a full pa= ge call/answer: then AJAX would not be an option there.</div><div><br></div= ><div>As for leaking callbacks, have you found any or profiled the memory t= o confirm that it is leaking somewhere?</div><div><br></div><div>Best regar= ds,</div><br clear=3D"all"><div><div dir=3D"ltr" class=3D"gmail_signature" = data-smartmail=3D"gmail_signature">Esteban A. Maringolo</div></div><br></di= v><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On T= hu, Aug 31, 2023 at 7:19=E2=80=AFAM Annick Fron <<a href=3D"mailto:list@= afceurope.com">[email protected]</a>> wrote:<br></div><blockquote class= =3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rg= b(204,204,204);padding-left:1ex">Hi,<br> <br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 I use tables with items and use anchors for ite= m lines to perform some particular action on an item. This action is for in= stance to call a specific component on that item.<br> <br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 If I have numerous items, I am worried about th= e number of callbacks piling in and not being garbaged.<br> <br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 Is it preferable to create a component per item= holding only one callback ?<br> <br> Annick<br> _______________________________________________<br> seaside mailing list -- <a href=3D"mailto:[email protected]= g" target=3D"_blank">[email protected]</a><br> To unsubscribe send an email to <a href=3D"mailto:[email protected]= kfoundation.org" target=3D"_blank">[email protected]= </a><br> </blockquote></div> --00000000000065fffb060436e5a3-- --===============8565128406700719614== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ seaside mailing list -- [email protected] To unsubscribe send an email to [email protected] --===============8565128406700719614==--