Opened 13 years ago

Closed 13 years ago

Last modified 12 years ago

#1134 closed defect (fixed)

Tooltips cause high CPU load in Firefox

Reported by: guest Owned by: bill
Priority: high Milestone:
Component: General Version: 0.3
Keywords: tooltip cpu Cc: filter-dojo@…
Blocked By: Blocking:

Description

With latest svn I have observed the following problem in firefox 1.5.0.1/linux...

I have a page that contains 20 or so tooltips. After 8-9 different tooltips have been displayed the page gets very sluggish. Hovering over a link (*any* link) will then cause firefox to eat up 99% CPU which induces very noticable lag.

With my very limited knowledge of the dojo internals I can only guess that the tooltips, when displayed for the first time, register some kind of global onmouseover-handler (one that is called for all links on the page, no matter if they're connected to a tooltip or not). Thus the performance degradation gets worse with each additional tooltip that has been displayed at least once.

I have not noticed this problem in older dojo versions, I think it's a new one.

Change History (5)

comment:1 Changed 13 years ago by dylan

Milestone: 0.5
Owner: changed from anonymous to bill

comment:2 Changed 13 years ago by moe

Cc: filter-dojo@… added

Here is a way to reproduce this:

  1. Go to http://archive.dojotoolkit.org/nightly/tests/widget/test_Tooltip.html
  1. Open a "top" command or similar to view CPU usage
  1. Just wiggle your mouse over some whitespace of the page, CPU load should remain low
  1. View *all* tooltips on that page, one after another
  1. Again, wiggle your mouse over some whitespace (for 4-8 seconds), CPU usage will jump to 99%

This is how it behaves in Firefox 1.5.0.5 on linux. I have not tested on other configurations.

comment:3 Changed 13 years ago by bill

Milestone: 0.50.4
Status: newassigned

comment:4 Changed 13 years ago by bill

Resolution: fixed
Status: assignedclosed

(In [5624]) 1. fix dojo.html.overElement() calculation; it was using the position of the content box rather than the border box (but using the size of the border box)

  1. fix tooltip bug where the onMouseMove wasn't getting canceled when the mouse was moved away before the tooltip even appeared. (fixes #1134)

comment:5 Changed 12 years ago by (none)

Milestone: 0.4

Milestone 0.4 deleted

Note: See TracTickets for help on using tickets.