summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorSerge Krot <Serge.Krot@cib.de>2017-11-13 17:35:48 +0100
committerThorsten Behrens <Thorsten.Behrens@CIB.de>2017-11-14 14:07:06 +0100
commit2818280eb4f2af5a76a338676d12dcf2d721c2e9 (patch)
tree756eaf53f424e790570889aa64370430334aa6b8 /cui
parent7d6f8b48ad4131b13f18ce9d92c10f6b998a68ec (diff)
tdf#113807 Enable clicking on pathfile-names in "Links" dialog
Improved: * Very long pathfilename now do not overwrite its label on the dialog * Full pathfilename could be clicked to show attachment/image with default viewer. Change-Id: I6e5398ed2a2013aae0d9b51a719e694b3206dcce Reviewed-on: https://gerrit.libreoffice.org/44689 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'cui')
-rw-r--r--cui/source/dialogs/linkdlg.cxx1
-rw-r--r--cui/source/inc/linkdlg.hxx3
-rw-r--r--cui/uiconfig/ui/baselinksdialog.ui26
3 files changed, 27 insertions, 3 deletions
diff --git a/cui/source/dialogs/linkdlg.cxx b/cui/source/dialogs/linkdlg.cxx
index 86a2963014dd..4ffa5c090cad 100644
--- a/cui/source/dialogs/linkdlg.cxx
+++ b/cui/source/dialogs/linkdlg.cxx
@@ -243,6 +243,7 @@ IMPL_LINK( SvBaseLinksDlg, LinksSelectHdl, SvTreeListBox *, pSvTabListBox, void
sfx2::LinkManager::GetDisplayNames( pLink, &sType, &aFileName, pLinkNm, pFilter );
aFileName = INetURLObject::decode(aFileName, INetURLObject::DecodeMechanism::Unambiguous);
m_pFtFullFileName->SetText( aFileName );
+ m_pFtFullFileName->SetURL( aFileName );
m_pFtFullSourceName->SetText( sLink );
m_pFtFullTypeName->SetText( sType );
}
diff --git a/cui/source/inc/linkdlg.hxx b/cui/source/inc/linkdlg.hxx
index ecfcd3855fa4..9d274b431951 100644
--- a/cui/source/inc/linkdlg.hxx
+++ b/cui/source/inc/linkdlg.hxx
@@ -26,6 +26,7 @@
#include <vcl/edit.hxx>
#include <vcl/lstbox.hxx>
#include <vcl/idle.hxx>
+#include <vcl/fixedhyper.hxx>
#include <svtools/svmedit.hxx>
#include <svtools/svtabbx.hxx>
@@ -45,7 +46,7 @@ class SvBaseLinksDlg : public ModalDialog
using Window::SetType;
VclPtr<SvTabListBox> m_pTbLinks;
- VclPtr<FixedText> m_pFtFullFileName;
+ VclPtr<FixedHyperlink> m_pFtFullFileName;
VclPtr<FixedText> m_pFtFullSourceName;
VclPtr<FixedText> m_pFtFullTypeName;
VclPtr<RadioButton> m_pRbAutomatic;
diff --git a/cui/uiconfig/ui/baselinksdialog.ui b/cui/uiconfig/ui/baselinksdialog.ui
index bd14fce35e68..b04ed44cc7d0 100644
--- a/cui/uiconfig/ui/baselinksdialog.ui
+++ b/cui/uiconfig/ui/baselinksdialog.ui
@@ -297,16 +297,38 @@
</packing>
</child>
<child>
- <object class="GtkLabel" id="FULL_FILE_NAME">
+ <object class="GtkBox" id="box_hexpand">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="xalign">0</property>
+ <property name="hexpand">True</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">6</property>
+ <child>
+ <object class="GtkLinkButton" id="FULL_FILE_NAME">
+ <property name="label"></property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="has_tooltip">True</property>
+ <property name="relief">none</property>
+ <property name="focus_on_click">False</property>
+ <property name="xalign">0</property>
+ <property name="uri"></property>
+ </object>
+ <packing>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
</packing>
</child>
<child>