sw/source/core/access/accmap.cxx |   17 +++++++----------
 1 file changed, 7 insertions(+), 10 deletions(-)

New commits:
commit 4e35cf055d3074beaef7bf573fafefe4adb2a37e
Author:     Michael Weghorn <[email protected]>
AuthorDate: Tue Jan 14 08:16:04 2025 +0100
Commit:     Michael Weghorn <[email protected]>
CommitDate: Wed Jan 15 10:09:43 2025 +0100

    sw a11y: Use reference instead of pointer
    
    Change-Id: I79b7fa475642b93f15c000d6f989cf30864ce212
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/180222
    Tested-by: Jenkins
    Reviewed-by: Michael Weghorn <[email protected]>

diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index 0ca948193eb0..611daa4e234b 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -1370,8 +1370,8 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
                     SwFrame *pFrame = nullptr;
                     if(nStartIndex.GetNode().IsContentNode())
                     {
-                        SwContentNode* pCNd = 
static_cast<SwContentNode*>(&(nStartIndex.GetNode()));
-                        pFrame = SwIterator<SwFrame, SwContentNode, 
sw::IteratorMode::UnwrapMulti>(*pCNd).First();
+                        SwContentNode& rCNd = 
static_cast<SwContentNode&>(nStartIndex.GetNode());
+                        pFrame = SwIterator<SwFrame, SwContentNode, 
sw::IteratorMode::UnwrapMulti>(rCNd).First();
                         if (mapTemp.find(pFrame) != mapTemp.end())
                         {
                             continue; // sw_redlinehide: once is enough
@@ -1379,8 +1379,8 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
                     }
                     else if( nStartIndex.GetNode().IsTableNode() )
                     {
-                        SwTableNode * pTable = static_cast<SwTableNode 
*>(&(nStartIndex.GetNode()));
-                        SwTableFormat* pFormat = 
pTable->GetTable().GetFrameFormat();
+                        SwTableNode& rTable = 
static_cast<SwTableNode&>(nStartIndex.GetNode());
+                        SwTableFormat* pFormat = 
rTable.GetTable().GetFrameFormat();
                         pFrame = SwIterator<SwFrame, 
SwTableFormat>(*pFormat).First();
                     }
 
commit 8f8518cdacb8ef7aee872b2380ae3424dcb3d633
Author:     Michael Weghorn <[email protected]>
AuthorDate: Tue Jan 14 08:10:57 2025 +0100
Commit:     Michael Weghorn <[email protected]>
CommitDate: Wed Jan 15 10:09:37 2025 +0100

    sw a11y: Drop VEC_PARA typedef
    
    Change-Id: I8de415d96f95f6d65c8e9fa0f03658818489821d
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/180221
    Tested-by: Jenkins
    Reviewed-by: Michael Weghorn <[email protected]>

diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index 0b298c07da61..0ca948193eb0 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -1352,9 +1352,8 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
         }
     }
 
-    typedef std::vector< SwAccessibleContext* > VEC_PARA;
-    VEC_PARA vecAdd;
-    VEC_PARA vecRemove;
+    std::vector<SwAccessibleContext*> vecAdd;
+    std::vector<SwAccessibleContext*> vecRemove;
     //Checked for Paras.
     bool bMarkChanged = false;
     SwAccessibleContextMap_Impl mapTemp;
commit b0a4f7c24a4371761d00b91e526eb4eccec3bf47
Author:     Michael Weghorn <[email protected]>
AuthorDate: Tue Jan 14 08:03:34 2025 +0100
Commit:     Michael Weghorn <[email protected]>
CommitDate: Wed Jan 15 10:09:30 2025 +0100

    sw a11y: Drop local var bIsSelAll
    
    Just call IsDocumentSelAll() at the one
    place where the local var was used so far.
    
    Change-Id: Ia7b50bbb678f0186a6cb10cd9c156ac4c2b026b4
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/180220
    Tested-by: Jenkins
    Reviewed-by: Michael Weghorn <[email protected]>

diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index 4dfe6284beb8..0b298c07da61 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -1147,15 +1147,13 @@ void SwAccessibleMap::InvalidateShapeInParaSelection()
     if( mpShapeMap )
         pShapes = mpShapeMap->Copy( nShapes, pFESh, &pSelShape );
 
-    bool bIsSelAll =IsDocumentSelAll();
-
     if( mpShapeMap )
     {
         //Checked for shapes.
         SwAccessibleShapeMap_Impl::const_iterator aIter = mpShapeMap->cbegin();
         SwAccessibleShapeMap_Impl::const_iterator aEndIter = 
mpShapeMap->cend();
 
-        if( bIsSelAll)
+        if (IsDocumentSelAll())
         {
             while( aIter != aEndIter )
             {

Reply via email to