Hi Devs,

I have a question about the benefits of the change from event based to
polling based folder highlighting when dragging.

Revision 1763 changed the manner in which target folders are highlighted
when dragging a message.   Before 1763, each folder had an onmouseover
which would trigger focus_folder.  

1763 removed that onmouseover event and instead calls drag_move every
time the mouse moves.  drag_move essentially polls the position of the
mouse and loops over every folder on screen to see if the mouse is above
that folder folder.  This polling is costly and has mixed effects across
browsers, operating systems and pcs with different specs.

On all systems tested so far, even if the dragging appears smooth, at
least one cpu is maxed at 100% by the polling.  On some systems/browsers
a cpu is pegged and the dragging is intolerably choppy and slow.

The commit comment for 1763 includes: "Don't rely on browser events anymore"

Is relying on browser events a bad thing?  Worse than polling?

It seems that the previous highlighting detection method was more
efficient and compatible across a wider range of systems.

If there are reasons that polling has to be the answer, then perhaps we
can add some sort of rate limiting?

Thanks for your consideration,
Ziba

-- 
Ziba Scott
Webmaster Team
The University of Michigan



_______________________________________________
List info: http://lists.roundcube.net/dev/

Reply via email to