浏览代码

Don't check visibility before hiding.

In some cases the element is not visible,but we want to set 'display: None'
regardless, for example in cases where you only want one single chat of
multiple to be visible at any one time, while hiding it behind a sidebar.
JC Brand 9 年之前
父节点
当前提交
b90ad3aa6e
共有 1 个文件被更改,包括 2 次插入4 次删除
  1. 2 4
      src/converse-chatview.js

+ 2 - 4
src/converse-chatview.js

@@ -659,10 +659,8 @@
                 },
 
                 hide: function () {
-                    if (this.$el.is(':visible') && this.$el.css('opacity') === "1") {
-                        this.$el.hide();
-                        utils.refreshWebkit();
-                    }
+                    this.$el.hide();
+                    utils.refreshWebkit();
                     return this;
                 },