From e366cf4f207e1fcbfa0bc11c83916fb89c7e6eae Mon Sep 17 00:00:00 2001 From: Olivier Hallot Date: Fri, 13 Jul 2018 11:18:15 -0300 Subject: tdf#115524 Some branch bookmarks are not working 1 With .ui dialogs, the Help system sends specific URL associated to the higlighted widget in the .ui dislog. Not every help page associated to the dialog has for all widgets of the dialog. As consequence, some URLs were not addressed and the default module entry page was displayed, instead of the dialog help page. The solution is to define a dumy bookmark '@@nowidget@@' to the help page associated to the dialog, and if the widget bookmark is missing in the help page then use the dummy target, thus offering a help page with the right contents anyway. This patch covers help pages for smath. Change-Id: I40b592271b0c336d4d3bacc33d2f3d19107ae702 Reviewed-on: https://gerrit.libreoffice.org/57393 Tested-by: Jenkins Reviewed-by: Olivier Hallot --- help3xsl/index2.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'help3xsl/index2.html') diff --git a/help3xsl/index2.html b/help3xsl/index2.html index b7872710bf..6ca41cc906 100644 --- a/help3xsl/index2.html +++ b/help3xsl/index2.html @@ -37,6 +37,11 @@ } var bookmark = rest.slice(rest.indexOf('/')+1, rest.indexOf('?')); var file = map[bookmark]; + // check first if a root bookmark @@nowidget@@ can be used + if (file === undefined){ + var b2 = bookmark.substring(0, bookmark.lastIndexOf("/")) + '/@@nowidget@@'; + file = map[b2]; + } // rebuild URL if (file === undefined){ var newURL = lang + '/' + defaultFile + '?System=' + system + '&DbPAR=' + module; @@ -58,4 +63,3 @@ - -- cgit