mirror of
https://github.com/kuaifan/dootask.git
synced 2026-02-07 22:55:35 +00:00
perf: 客户端窗口激活自动获取聊天焦点
This commit is contained in:
parent
82fad2c17d
commit
f6b7eca0f5
@ -479,6 +479,7 @@ export default {
|
|||||||
'cacheDialogs',
|
'cacheDialogs',
|
||||||
'wsOpenNum',
|
'wsOpenNum',
|
||||||
'touchBackInProgress',
|
'touchBackInProgress',
|
||||||
|
'dialogIns'
|
||||||
]),
|
]),
|
||||||
|
|
||||||
...mapGetters(['isLoad']),
|
...mapGetters(['isLoad']),
|
||||||
@ -793,6 +794,15 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
windowActive(active) {
|
||||||
|
if (active && this.autoFocus) {
|
||||||
|
const lastDialog = $A.last(this.dialogIns)
|
||||||
|
if (lastDialog && lastDialog.uid === this._uid) {
|
||||||
|
this.inputFocus()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
dialogDrag(val) {
|
dialogDrag(val) {
|
||||||
if (val) {
|
if (val) {
|
||||||
this.operateVisible = false;
|
this.operateVisible = false;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user