mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-02-28 05:32:52 +00:00
♻️ Implement some delayed kernel events using task queues https://github.com/siyuan-note/siyuan/issues/12393
This commit is contained in:
@@ -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
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user