[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-4.1' - sc/source
Noel Power
noel.power at suse.com
Mon Oct 28 11:49:34 PDT 2013
sc/source/filter/excel/xecontent.cxx | 8 ++++++--
sc/source/filter/inc/xecontent.hxx | 9 +++++----
2 files changed, 11 insertions(+), 6 deletions(-)
New commits:
commit 3c032c59b3a5b128dfc86bbd2e0325f3459e949a
Author: Noel Power <noel.power at suse.com>
Date: Fri Jun 21 15:46:08 2013 +0100
write display attr of hyperlink only if value is different from stringtable
Conflicts:
sc/source/filter/inc/xecontent.hxx
Change-Id: Iff6f16d6cdb539ad80ef01e91db51613e95053d1
diff --git a/sc/source/filter/excel/xecontent.cxx b/sc/source/filter/excel/xecontent.cxx
index 7287fe7..706f24c 100644
--- a/sc/source/filter/excel/xecontent.cxx
+++ b/sc/source/filter/excel/xecontent.cxx
@@ -332,7 +332,8 @@ XclExpHyperlink::XclExpHyperlink( const XclExpRoot& rRoot, const SvxURLField& rU
XclExpRecord( EXC_ID_HLINK ),
maScPos( rScPos ),
mxVarData( new SvMemoryStream ),
- mnFlags( 0 )
+ mnFlags( 0 ),
+ mbSetDisplay( true )
{
const String& rUrl = rUrlField.GetURL();
const String& rRepr = rUrlField.GetRepresentation();
@@ -498,6 +499,7 @@ void XclExpHyperlink::WriteEmbeddedData( XclExpStream& rStrm )
void XclExpHyperlink::SaveXml( XclExpXmlStream& rStrm )
{
+ OString sTmp = XclXmlUtils::ToOString( maScPos );
OUString sId = !msTarget.isEmpty() ? rStrm.addRelation( rStrm.GetCurrentStream()->getOutputStream(),
XclXmlUtils::ToOUString( "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" ),
msTarget, true ) : OUString();
@@ -510,7 +512,9 @@ void XclExpHyperlink::SaveXml( XclExpXmlStream& rStrm )
? XclXmlUtils::ToOString( *mxTextMark ).getStr()
: NULL,
// OOXTODO: XML_tooltip, from record HLinkTooltip 800h wzTooltip
- XML_display, XclXmlUtils::ToOString( *mxRepr ).getStr(),
+ XML_display, mbSetDisplay
+ ? XclXmlUtils::ToOString( *mxRepr ).getStr()
+ : NULL,
FSEND );
}
diff --git a/sc/source/filter/inc/xecontent.hxx b/sc/source/filter/inc/xecontent.hxx
index b972da4..3b95302 100644
--- a/sc/source/filter/inc/xecontent.hxx
+++ b/sc/source/filter/inc/xecontent.hxx
@@ -109,6 +109,7 @@ public:
virtual void SaveXml( XclExpXmlStream& rStrm );
virtual void WriteEmbeddedData( XclExpStream& rStrm );
+ void SetDisplay( bool bDisplay ) { mbSetDisplay = bDisplay; }
private:
/** Builds file name from the passed file URL. Tries to convert to relative file name.
@param rnLevel (out-param) The parent directory level.
@@ -119,7 +120,6 @@ private:
/** Writes the body of the HLINK record. */
virtual void WriteBody( XclExpStream& rStrm );
-
private:
typedef boost::scoped_ptr< String > StringPtr;
typedef boost::scoped_ptr< SvStream > SvStreamPtr;
@@ -129,7 +129,8 @@ private:
SvStreamPtr mxVarData; /// Buffer stream with variable data.
sal_uInt32 mnFlags; /// Option flags.
XclExpStringRef mxTextMark; /// Location within mxRepr
- OUString msTarget; /// Target URL
+ OUString msTarget; /// Target URL
+ bool mbSetDisplay; /// True if display attribute it written
};
typedef XclExpRecordList< XclExpHyperlink > XclExpHyperlinkList;
@@ -349,9 +350,9 @@ private:
XclExpString maErrorText; /// The error text.
XclExpStringRef mxString1; /// String for first condition formula.
XclTokenArrayRef mxTokArr1; /// Formula for first condition.
- OUString msFormula1; /// OOXML Formula for first condition.
+ OUString msFormula1; /// OOXML Formula for first condition.
XclTokenArrayRef mxTokArr2; /// Formula for second condition.
- OUString msFormula2; /// OOXML Formula for second condition.
+ OUString msFormula2; /// OOXML Formula for second condition.
sal_uInt32 mnFlags; /// Miscellaneous flags.
sal_uLong mnScHandle; /// The core handle for quick list search.
};
More information about the Libreoffice-commits
mailing list