From 68444017d86c8912ecc26542046b005b2bad12eb Mon Sep 17 00:00:00 2001 From: Jaakko Keränen Date: Thu, 29 Oct 2020 14:11:46 +0200 Subject: SidebarWidget: Improving blank Identities tab If there are no identities, the Identities tab now shows a button for creating one, and a link to the Help documentation. --- src/app.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/app.c') diff --git a/src/app.c b/src/app.c index 64ea9ad1..e4c31eaf 100644 --- a/src/app.c +++ b/src/app.c @@ -1018,6 +1018,12 @@ iBool handleCommand_App(const char *cmd) { setInitialScroll_DocumentWidget(doc, argfLabel_Command(cmd, "scroll")); setRedirectCount_DocumentWidget(doc, redirectCount); setUrlFromCache_DocumentWidget(doc, url, isHistory); + /* Optionally, jump to a text in the document. This will only work if the document + is already available, e.g., it's from "about:" or restored from cache. */ + const iRangecc gotoHeading = range_Command(cmd, "gotoheading"); + if (gotoHeading.start) { + postCommandf_App("document.goto heading:%s", cstr_Rangecc(gotoHeading)); + } } else if (equal_Command(cmd, "document.request.cancelled")) { /* TODO: How should cancelled requests be treated in the history? */ -- cgit v1.2.3