summaryrefslogtreecommitdiff
path: root/addons/mail/static/src/js/thread_windows/abstract_thread_window.js
diff options
context:
space:
mode:
Diffstat (limited to 'addons/mail/static/src/js/thread_windows/abstract_thread_window.js')
-rw-r--r--addons/mail/static/src/js/thread_windows/abstract_thread_window.js16
1 files changed, 4 insertions, 12 deletions
diff --git a/addons/mail/static/src/js/thread_windows/abstract_thread_window.js b/addons/mail/static/src/js/thread_windows/abstract_thread_window.js
index ff5acfea0d2..7a38d337f24 100644
--- a/addons/mail/static/src/js/thread_windows/abstract_thread_window.js
+++ b/addons/mail/static/src/js/thread_windows/abstract_thread_window.js
@@ -83,6 +83,8 @@ var AbstractThreadWindow = Widget.extend({
displayStars: this.options.displayStars,
});
+ // animate the (un)folding of thread windows
+ this.$el.css({transition: 'height ' + this.FOLD_ANIMATION_DURATION + 'ms linear'});
if (this.isFolded()) {
this.$el.css('height', this.HEIGHT_FOLDED);
} else if (this.options.autofocus) {
@@ -319,7 +321,8 @@ var AbstractThreadWindow = Widget.extend({
this._focusInput();
}
}
- this._animateFold();
+ var height = this.isFolded() ? this.HEIGHT_FOLDED : this.HEIGHT_OPEN;
+ this.$el.css({height: height});
},
//--------------------------------------------------------------------------
@@ -327,17 +330,6 @@ var AbstractThreadWindow = Widget.extend({
//--------------------------------------------------------------------------
/**
- * Called when there is a change of the fold state of the thread window.
- * This method animates the change of fold state of this thread window.
- *
- * @private
- */
- _animateFold: function () {
- this.$el.animate({
- height: this.isFolded() ? this.HEIGHT_FOLDED : this.HEIGHT_OPEN
- }, this.FOLD_ANIMATION_DURATION);
- },
- /**
* Set the focus on the composer of the thread window. This operation is
* ignored in mobile context.
*