From 11ae1cf4e4415237ed4fce7fa8d77502ab058ab1 Mon Sep 17 00:00:00 2001 From: Pranam Lashkari Date: Mon, 15 Apr 2024 01:22:45 +0100 Subject: sw lok: .uno:SetDocumentProperties: add file size parameter MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit problem: in LOK/online to support async save, files in jails may have different extensions (ie: .upload, .uploading) this caused problem to detect files as original file name may not exist. As result property like file size were always set to 0 Change-Id: I552aef203297470d01032659a266210970129e66 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165769 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara (cherry picked from commit aa4e10efc6e9ac92b0c652f238526aacbe2096c6) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166171 Tested-by: Jenkins --- include/sfx2/dinfdlg.hxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/sfx2/dinfdlg.hxx b/include/sfx2/dinfdlg.hxx index 874e127f20b5..d4743ed00ef5 100644 --- a/include/sfx2/dinfdlg.hxx +++ b/include/sfx2/dinfdlg.hxx @@ -82,6 +82,7 @@ private: OUString m_Type; OUString m_Subject; OUString m_Title; + sal_Int64 m_nFileSize; bool m_bHasTemplate; bool m_bDeleteUserData; bool m_bUseUserData; @@ -95,7 +96,7 @@ public: SfxDocumentInfoItem( const OUString &rFileName, const css::uno::Reference< css::document::XDocumentProperties> & i_xDocProps, const css::uno::Sequence< css::document::CmisProperty> & i_cmisProps, - bool bUseUserData, bool bUseThumbnailSave ); + bool bUseUserData, bool bUseThumbnailSave, sal_Int64 nFileSize ); SfxDocumentInfoItem( const SfxDocumentInfoItem& ); virtual ~SfxDocumentInfoItem() override; @@ -148,6 +149,8 @@ public: void setSubject(const OUString& i_val) { m_Subject = i_val; } const OUString& getTitle() const { return m_Title; } void setTitle(const OUString& i_val) { m_Title = i_val; } + sal_Int64 getFileSize() const { return m_nFileSize; } + void setFileSize(sal_Int64 i_val) { m_nFileSize = i_val; } /// reset user-specific data (author, modified-by, ...) void resetUserData(const OUString & i_rAuthor); -- cgit