Opened 12 years ago
Last modified 12 years ago
#10000 confirmed Bug
Magicline plugin might slow the page down
Reported by: | Anna Tomanek | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 4.0 |
Keywords: | magicline | Cc: |
Description
Reported on the forum: http://ckeditor.com/comment/123583#comment-123583
I noticed my site was becoming slow and less responsive recently and after some profiling I traced it to this plugin. It seems that anywhere the mouse is moved triggers a mouseout event so basically the entire time the user is using a page in my application with this plugin it was causing it to be less responsive.
I traced it to this line of code inside the plugin.js file of magicline. I am using v4 of ckeditor with the div based editor.
Hide the box on mouseout if mouse leaves document.
editable.attachListener( that.inInlineMode ? doc : doc.getWindow().getFrame(), 'mouseout', function( event ) {
See attached profile results. Notice I ran it for just 2.1 seconds and the top 7 calls were running for 1.7 - 1.9s a piece which explains why it was so bogged down. These results are probably slightly misleading as well because as I move my mouse in and out of the page to click the Profiler in Firebug it would stop triggering mouse out events which means realistically as long as the user has their mouse moving on the page cycles are being consumed the entire time for no reason.
Attachments (1)
Change History (2)
Changed 12 years ago by
Attachment: | ckeditor_magicline_slow.png added |
---|
comment:1 Changed 12 years ago by
Status: | new → confirmed |
---|
I'm confirming this issue as this part of code
that.inInlineMode ? doc
is disturbing but I would be nice if @Cyclone112 could attach sample code that caused problem for him.