Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

resize event on window is always triggered #8

Open
gluparia opened this issue Nov 27, 2012 · 4 comments
Open

resize event on window is always triggered #8

gluparia opened this issue Nov 27, 2012 · 4 comments

Comments

@gluparia
Copy link

I have the following code:

dynamic content

$(window).resize(function(e) {
console.log(e);
}

$("#test").resize(function() {
console.log("resize element");
});

The window resize callback is executed even though the window dimensions did not change.

JQuery 1.7.2

@FagnerMartinsBrack
Copy link

Happens here too

@ramaralo
Copy link

ramaralo commented Sep 2, 2013

Browser: Chrome 22.0.1229.94
SO: Ubuntu 10.10

I have a flot instance with resize plugin. No series in it. Memory profile shows the behavior the attached print screen illustrates.

I'm kind of surprised to see a timer for this plugin.
The records point to several timers being fired and never ending (jquery.flot.resize.js:22).

Memory suddenly drops apparently because chrome is able to garbage collect something that is leaking...

flotresizememory_leak

@FagnerMartinsBrack
Copy link

This is a non standard resizing event, so the only way to get the desired behavior is using timers. I don't remember last time I used this plugin but I haven't noticed any memory leak.

@ramaralo
Copy link

ramaralo commented Sep 2, 2013

Sorry just realized this repository is of jquery plugin wich is used by a flot plugin.

Anyway, just for information, the flot resize plugin example page

http://www.flotcharts.org/flot/examples/resize/index.html

has the same behavior.

I'll post this on their repo.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants