Commit fc9e61da authored by Masayuki Tanaka's avatar Masayuki Tanaka

Add onresize and onresized event hander - #145

parent e79df141
...@@ -113,7 +113,9 @@ ...@@ -113,7 +113,9 @@
__zoom_privileged = getConfig(['zoom', 'privileged'], false); __zoom_privileged = getConfig(['zoom', 'privileged'], false);
var __onenter = getConfig(['onenter'], function () {}), var __onenter = getConfig(['onenter'], function () {}),
__onleave = getConfig(['onleave'], function () {}); __onleave = getConfig(['onleave'], function () {}),
__onresize = getConfig(['onresize'], function () {}),
__onresized = getConfig(['onresized'], function () {});
var __transition_duration = getConfig(['transition', 'duration'], 350); var __transition_duration = getConfig(['transition', 'duration'], 350);
...@@ -2656,9 +2658,11 @@ ...@@ -2656,9 +2658,11 @@
window.onresize = generateResize(); window.onresize = generateResize();
} }
if (window.onresize.add) { if (window.onresize.add) {
window.onresize.add(__onresize);
window.onresize.add(function () { window.onresize.add(function () {
updateAndRedraw({withLegend: true, withTransition: false, withTransitionForTransform: false}); updateAndRedraw({withLegend: true, withTransition: false, withTransitionForTransform: false});
}); });
window.onresize.add(__onresized);
} }
} }
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment