[Libreoffice-commits] core.git: Branch 'distro/collabora/cd-5.3-3.1' - sw/source
Jan Holesovsky
kendy at collabora.com
Fri Apr 6 14:46:50 UTC 2018
sw/source/uibase/wrtsh/wrtsh2.cxx | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
New commits:
commit 0cd1c3789bbd50c7c8fe80066afb794a07c7c4b0
Author: Jan Holesovsky <kendy at collabora.com>
Date: Fri Apr 6 15:46:47 2018 +0200
sw lok: Don't try to open TOC marks in a new window, jump instead.
Change-Id: I1ecae82c4b1e08383f6957c38cb70b91fc3549d4
Reviewed-on: https://gerrit.libreoffice.org/52504
Reviewed-by: Ashod Nakashian <ashnakash at gmail.com>
Tested-by: Ashod Nakashian <ashnakash at gmail.com>
(cherry picked from commit e112fe434df84d2367d9efb83e9e1105a1394492)
Reviewed-on: https://gerrit.libreoffice.org/52509
diff --git a/sw/source/uibase/wrtsh/wrtsh2.cxx b/sw/source/uibase/wrtsh/wrtsh2.cxx
index ac17db298931..e4305c383c11 100644
--- a/sw/source/uibase/wrtsh/wrtsh2.cxx
+++ b/sw/source/uibase/wrtsh/wrtsh2.cxx
@@ -470,8 +470,9 @@ void LoadURL( SwViewShell& rVSh, const OUString& rURL, sal_uInt16 nFilter,
if ( dynamic_cast<const SwCursorShell*>( &rVSh) == nullptr )
return;
- // We are doing tiledRendering, let the client handles the URL loading.
- if (comphelper::LibreOfficeKit::isActive())
+ // We are doing tiledRendering, let the client handles the URL loading,
+ // unless we are jumping to a TOC mark.
+ if (comphelper::LibreOfficeKit::isActive() && !rURL.startsWith("#"))
{
rVSh.GetSfxViewShell()->libreOfficeKitViewCallback(LOK_CALLBACK_HYPERLINK_CLICKED, rURL.toUtf8().getStr());
return;
@@ -506,7 +507,7 @@ void LoadURL( SwViewShell& rVSh, const OUString& rURL, sal_uInt16 nFilter,
//#39076# Silent can be removed accordingly to SFX.
SfxBoolItem aBrowse( SID_BROWSE, true );
- if( nFilter & URLLOAD_NEWVIEW )
+ if ((nFilter & URLLOAD_NEWVIEW) && !comphelper::LibreOfficeKit::isActive())
aTargetFrameName.SetValue( "_blank" );
const SfxPoolItem* aArr[] = {
More information about the Libreoffice-commits
mailing list