diff options
Diffstat (limited to 'src/local')
| -rw-r--r-- | src/local/container.nim | 3 | ||||
| -rw-r--r-- | src/local/pager.nim | 11 |
2 files changed, 8 insertions, 6 deletions
diff --git a/src/local/container.nim b/src/local/container.nim index 65ebf6ad..ab69a0ed 100644 --- a/src/local/container.nim +++ b/src/local/container.nim @@ -1484,7 +1484,8 @@ proc onload(container: Container; res: int) = let anchor = container.url.hash.substr(1) if anchor != "" or container.config.autofocus: container.requestLines().then(proc(): Promise[GotoAnchorResult] = - return container.iface.gotoAnchor(anchor, container.config.autofocus) + return container.iface.gotoAnchor(anchor, container.config.autofocus, + true) ).then(proc(res: GotoAnchorResult) = if res.found: container.setCursorXYCenter(res.x, res.y) diff --git a/src/local/pager.nim b/src/local/pager.nim index b77c85f4..72945745 100644 --- a/src/local/pager.nim +++ b/src/local/pager.nim @@ -1932,11 +1932,12 @@ proc gotoURL(pager: Pager; request: Request; prevurl = none(URL); let container = pager.container let url = request.url let anchor = url.hash.substr(1) - container.iface.gotoAnchor(anchor, false).then(proc(res: GotoAnchorResult) = - if res.found: - pager.dupeBuffer(container, url) - else: - pager.alert("Anchor " & url.hash & " not found") + container.iface.gotoAnchor(anchor, false, false).then( + proc(res: GotoAnchorResult) = + if res.found: + pager.dupeBuffer(container, url) + else: + pager.alert("Anchor " & url.hash & " not found") ) return nil |