diff --git a/default.aproj b/default.aproj index 01f32bf..6304c0f 100644 --- a/default.aproj +++ b/default.aproj @@ -1,5 +1,5 @@  - + diff --git a/dlg/timeline.aardio b/dlg/timeline.aardio index 6b7c4d3..2239606 100644 --- a/dlg/timeline.aardio +++ b/dlg/timeline.aardio @@ -795,16 +795,19 @@ winform.删除plus.oncommand = function(id,event){ var confirmed = winform.msgboxTest("确认删除"""+tl_time+"""吗?","确认删除"); if(confirmed){ try{ - ..dbTimeline.exec("DELETE FROM ?? WHERE time=?;",{ winform.当前主题.text,tl_time} ) + var hasErr = ..dbTimeline.exec("DELETE FROM ?? WHERE time=?;",{ winform.当前主题.text,tl_time} ) ..logWarn(">>>已删除项",winform.当前主题.text,"中的:",tl_time) + if(hasErr){ + return ; + } + win.delay(200) + tl_webview.xcall("removeContent",{tostring(tl_time)}); win.delay(200) winform.addUIReset(winform); - win.delay(200) - tl_webview.xcall("removeContent",{tostring(tl_time)}); + win.delay(200) winform.listboxUpdate(winform); - win.delay(200) winform.timelineWebUpdate(winform); } catch(e){ diff --git a/release/1.6.0.12 b/release/1.6.0.12 deleted file mode 100644 index 36b6905..0000000 --- a/release/1.6.0.12 +++ /dev/null @@ -1 +0,0 @@ -1.6.0.12 \ No newline at end of file diff --git a/release/1.6.0.13 b/release/1.6.0.13 new file mode 100644 index 0000000..be3ccf3 --- /dev/null +++ b/release/1.6.0.13 @@ -0,0 +1 @@ +1.6.0.13 \ No newline at end of file diff --git a/release/ChiikawaBest.exe b/release/ChiikawaBest.exe index 9c52f56..a994d67 100644 Binary files a/release/ChiikawaBest.exe and b/release/ChiikawaBest.exe differ diff --git a/res/template_timeline.aardio b/res/template_timeline.aardio index f780969..728377d 100644 --- a/res/template_timeline.aardio +++ b/res/template_timeline.aardio @@ -55,6 +55,12 @@ body { z-index: 1000; } +.fixed-top > ul { + margin-left: 1.5em; + padding-left: 0em; + list-style-type: decimal-leading-zero; +} + /* Styling */ .timeline { margin: 4em auto; @@ -483,6 +489,7 @@ var content_js = /** window.removeContent = function(datas){ var liEle = document.getElementById(datas[0]); liEle.remove(); + console.log('Removed',datas[0]) } window.watchImg = function(){ @@ -1154,17 +1161,21 @@ var content_js = /** let idFlag = 1 headingSet.forEach(heading => { + console.log('forEach Starting...', idFlag); const hLevel = heading.outerHTML.match(//)[1] - console.log(hLevel) const titleText = heading.innerText - - switch (hLevel >= curLevel) { + switch (hLevel > curLevel) { case true: + console.log('>>>switch true') if (preTocItem === undefined) { + console.log('>>>switch true->if true') preTocItem = new TocItem(titleText, hLevel) + console.log(preTocItem) tocData.push(preTocItem) } else { + console.log('>>>switch true->if false') const curTocItem = new TocItem(titleText, hLevel) + console.log(curTocItem) const parent = curTocItem.level > preTocItem.level ? preTocItem : preTocItem.parent curTocItem.parent = parent parent.children.push(curTocItem) @@ -1172,10 +1183,12 @@ var content_js = /** } break case false: + console.log('>>>switch false') // We need to find the appropriate parent node from the preTocItem const curTocItem = new TocItem(titleText, hLevel) while (1) { if (preTocItem.level < curTocItem.level) { + console.log('>>>switch false->if < is true') preTocItem.children.push(curTocItem) preTocItem = curTocItem break @@ -1183,6 +1196,7 @@ var content_js = /** preTocItem = preTocItem.parent if (preTocItem === undefined) { + console.log('>>>switch false->if === is true') tocData.push(curTocItem) preTocItem = curTocItem break @@ -1190,16 +1204,16 @@ var content_js = /** } break } - curLevel = hLevel if (heading.id === "") { - let tmpId = titleText.replace(/\s+/g,"_").toLowerCase() + "-toc-" + idFlag.toString(); + console.log('>>>if no heading id') + let tmpId = "toc-" + idFlag.toString() + "-" + titleText.replace(/\s+/g,"_").toLowerCase(); heading.id = tmpId; } preTocItem.id = heading.id; - idFlag += idFlag; - console.log(preTocItem.id) + idFlag += 1; + console.log('forEach Ending...'); }) return tocData