[Libreoffice-commits] .: sw/source

Miklos Vajna vmiklos at kemper.freedesktop.org
Thu Aug 9 03:12:52 PDT 2012


 sw/source/core/crsr/swcrsr.cxx |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 5c6454f07b6f8e7b66892fda0111c02182180e92
Author: Miklos Vajna <vmiklos at suse.cz>
Date:   Thu Aug 9 12:11:57 2012 +0200

    fdo#52960 SwCursor::SelectWordWT fix text selection in commented text ranges
    
    Change-Id: Iabb1ac89163c2aa715c7631987886245fb96101c

diff --git a/sw/source/core/crsr/swcrsr.cxx b/sw/source/core/crsr/swcrsr.cxx
index e99d948..c1e0b40 100644
--- a/sw/source/core/crsr/swcrsr.cxx
+++ b/sw/source/core/crsr/swcrsr.cxx
@@ -57,6 +57,7 @@
 #include <mdiexp.hxx>
 #include <statstr.hrc>
 #include <redline.hxx>
+#include <xmloff/odffields.hxx>
 
 using namespace ::com::sun::star::i18n;
 
@@ -1341,8 +1342,8 @@ sal_Bool SwCursor::SelectWordWT( ViewShell* pViewShell, sal_Int16 nWordType, con
     {
         // Should we select the whole fieldmark?
         const IDocumentMarkAccess* pMarksAccess = GetDoc()->getIDocumentMarkAccess( );
-        sw::mark::IMark* pMark = GetPoint() ? pMarksAccess->getFieldmarkFor( *GetPoint( ) ) : NULL;
-        if ( pMark )
+        sw::mark::IFieldmark* pMark = GetPoint() ? pMarksAccess->getFieldmarkFor( *GetPoint( ) ) : NULL;
+        if ( pMark && pMark->GetFieldname() != ODF_COMMENTRANGE )
         {
             const SwPosition rStart = pMark->GetMarkStart();
             GetPoint()->nNode = rStart.nNode;


More information about the Libreoffice-commits mailing list