Skip to content

Commit

Permalink
Keep view.bounds in sync during 'resize' events.
Browse files Browse the repository at this point in the history
Closes #1127
  • Loading branch information
lehni committed Aug 3, 2016
1 parent fa34563 commit 91371c1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/view/View.js
Original file line number Diff line number Diff line change
Expand Up @@ -389,12 +389,12 @@ var View = Base.extend(Emitter, /** @lends View# */{
return;
this._setElementSize(width, height);
this._viewSize._set(width, height);
// Call onResize handler on any size change
this._changed();
// Emit resize event on any size changes.
this.emit('resize', {
size: size,
delta: delta
});
this._changed();
if (this._autoUpdate) {
// Update right away, don't wait for the next animation frame as
// otherwise the view would flicker during resizes, see #1126
Expand Down

0 comments on commit 91371c1

Please sign in to comment.