mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 10:00:13 +01:00
♻️ Implement some delayed kernel events using task queues https://github.com/siyuan-note/siyuan/issues/12393
This commit is contained in:
parent
9088e49a76
commit
09eec52a02
10 changed files with 79 additions and 44 deletions
|
|
@ -45,8 +45,13 @@ var UseSingleLineSave = true
|
|||
var IsUILoaded = false
|
||||
|
||||
func WaitForUILoaded() {
|
||||
start := time.Now()
|
||||
for !IsUILoaded {
|
||||
time.Sleep(200 * time.Millisecond)
|
||||
if time.Since(start) > 30*time.Second {
|
||||
logging.LogErrorf("wait for ui loaded timeout")
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue