writerfilter/source/dmapper/DomainMapper_Impl.cxx |   11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

New commits:
commit d21ba804040bdb275234254fbbe742ce830420c2
Author:     Justin Luth <justin.l...@collabora.com>
AuthorDate: Mon Mar 13 12:46:28 2023 -0400
Commit:     Justin Luth <jl...@mail.com>
CommitDate: Wed Mar 15 16:15:50 2023 +0000

    tdf#154129 tdf#97128 writerfilter framePr: deduplicate PopFrameDirection
    
    Well, not really deduplicate, because it only existed once.
    But I can't imagine why it would depend on a parent style.
    
    Recently added with 7.1 commit af4e5ee0f93c1ff442d08caed5c875f2b2c1fd43
    Author: Daniel Arato (NISZ) on  Wed Sep 16 08:48:32 2020 +0200
        tdf#97128 DOCX import: fix frame direction
    
    Typically only RTF files don't have a parent style,
    so the lack of it being there in the "else" clause
    likely wouldn't have been noticed.
    
    Change-Id: I8e561dcfc5a1dfc6ac1979ad4226b6c5f35800d8
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148814
    Tested-by: Jenkins
    Reviewed-by: Justin Luth <jl...@mail.com>

diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx 
b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index 09492826f13f..0f8991819b3b 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -1805,13 +1805,14 @@ void 
DomainMapper_Impl::CheckUnregisteredFrameConversion( )
             getPropertyName(PROP_BOTTOM_MARGIN),
             nVertOrient == text::VertOrientation::BOTTOM ? 0 : nBottomDist));
 
-        if (vProps.size() > 1)
+        if (const std::optional<sal_Int16> nDirection = PopFrameDirection())
         {
-            if (const std::optional<sal_Int16> nDirection = 
PopFrameDirection())
-            {
-                
aFrameProperties.push_back(comphelper::makePropertyValue(getPropertyName(PROP_FRM_DIRECTION),
 *nDirection));
-            }
+            aFrameProperties.push_back(
+                
comphelper::makePropertyValue(getPropertyName(PROP_FRM_DIRECTION), 
*nDirection));
+        }
 
+        if (vProps.size() > 1)
+        {
             // If there is no fill, the Word default is 100% transparency.
             // Otherwise CellColorHandler has priority, and this setting
             // will be ignored.

Reply via email to