mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-22 15:04:07 +01:00
🌐 启动界面进度提示加入多语言
This commit is contained in:
parent
b7faccc126
commit
899b38ab0a
7 changed files with 19 additions and 19 deletions
|
|
@ -523,11 +523,11 @@ func InitBoxes() {
|
|||
initialized := false
|
||||
if 1 > treenode.CountBlocks() {
|
||||
if gulu.File.IsExist(util.BlockTreePath) {
|
||||
util.IncBootProgress(20, "Reading block trees...")
|
||||
util.IncBootProgress(20, Conf.Language(91))
|
||||
go func() {
|
||||
for i := 0; i < 40; i++ {
|
||||
util.RandomSleep(50, 100)
|
||||
util.IncBootProgress(1, "Reading block trees...")
|
||||
util.IncBootProgress(1, Conf.Language(91))
|
||||
}
|
||||
}()
|
||||
|
||||
|
|
|
|||
|
|
@ -84,7 +84,7 @@ func (box *Box) Index(fullRebuildIndex bool) (treeCount int, treeSize int64) {
|
|||
docIAL := parse.IAL2MapUnEsc(tree.Root.KramdownIAL)
|
||||
cache.PutDocIAL(p, docIAL)
|
||||
|
||||
util.IncBootProgress(bootProgressPart, "Parsing tree "+util.ShortPathForBootingDisplay(tree.Path))
|
||||
util.IncBootProgress(bootProgressPart, fmt.Sprintf(Conf.Language(92), util.ShortPathForBootingDisplay(tree.Path)))
|
||||
treeSize += file.size
|
||||
treeCount++
|
||||
// 缓存文档标题,后面做 Path -> HPath 路径映射时需要
|
||||
|
|
@ -161,7 +161,7 @@ func (box *Box) Index(fullRebuildIndex bool) (treeCount int, treeSize int64) {
|
|||
continue
|
||||
}
|
||||
|
||||
util.IncBootProgress(bootProgressPart, "Indexing tree "+util.ShortPathForBootingDisplay(tree.Path))
|
||||
util.IncBootProgress(bootProgressPart, fmt.Sprintf(Conf.Language(93), util.ShortPathForBootingDisplay(tree.Path)))
|
||||
tx, err := sql.BeginTx()
|
||||
if nil != err {
|
||||
continue
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue