[Libreoffice-commits] core.git: 4 commits - compilerplugins/clang sw/inc sw/source

Noel Grandin noel at peralex.com
Mon Nov 23 22:05:45 PST 2015


 compilerplugins/clang/unusedfields.py          |    3 ++-
 sw/inc/ccoll.hxx                               |    5 -----
 sw/inc/doc.hxx                                 |    9 +--------
 sw/inc/ndgrf.hxx                               |    1 -
 sw/inc/ndhints.hxx                             |    1 -
 sw/inc/shellio.hxx                             |    1 -
 sw/inc/shellres.hxx                            |    5 -----
 sw/inc/splargs.hxx                             |    3 ---
 sw/inc/view.hxx                                |    1 -
 sw/source/core/access/accmap.cxx               |    6 ------
 sw/source/core/doc/docnew.cxx                  |    2 --
 sw/source/core/doc/tblrwcl.cxx                 |    8 +++-----
 sw/source/core/inc/MarkManager.hxx             |    3 ---
 sw/source/core/inc/SwXMLTextBlocks.hxx         |    2 --
 sw/source/core/inc/flyfrms.hxx                 |    2 --
 sw/source/core/inc/swblocks.hxx                |    1 -
 sw/source/core/inc/viewimp.hxx                 |    3 ---
 sw/source/core/layout/flylay.cxx               |    1 -
 sw/source/core/swg/SwXMLTextBlocks.cxx         |    4 ----
 sw/source/core/swg/swblocks.cxx                |    4 ++--
 sw/source/core/text/itratr.cxx                 |    7 +++----
 sw/source/core/text/porlay.cxx                 |    7 -------
 sw/source/core/text/porlay.hxx                 |   12 ++----------
 sw/source/core/txtnode/thints.cxx              |    1 -
 sw/source/core/unocore/unofield.cxx            |    6 +-----
 sw/source/core/view/viewimp.cxx                |    1 -
 sw/source/filter/html/htmlatr.cxx              |    1 -
 sw/source/filter/html/swhtml.cxx               |    1 -
 sw/source/filter/html/swhtml.hxx               |    2 --
 sw/source/filter/html/wrthtml.cxx              |    1 -
 sw/source/filter/html/wrthtml.hxx              |    3 ---
 sw/source/filter/inc/wrtswtbl.hxx              |    1 -
 sw/source/filter/writer/wrtswtbl.cxx           |    3 +--
 sw/source/filter/ww8/wrtww8.hxx                |    1 -
 sw/source/filter/ww8/ww8par3.cxx               |    2 --
 sw/source/filter/xml/xmlexp.cxx                |    3 +--
 sw/source/filter/xml/xmlexp.hxx                |    1 -
 sw/source/filter/xml/xmltexte.cxx              |    1 -
 sw/source/filter/xml/xmltexte.hxx              |    1 -
 sw/source/ui/config/optcomp.cxx                |    9 +++------
 sw/source/ui/dbui/dbinsdlg.cxx                 |   14 +++++++-------
 sw/source/ui/envelp/swuilabimp.hxx             |    2 --
 sw/source/ui/vba/vbastyles.cxx                 |    5 ++---
 sw/source/uibase/dbui/dbtree.cxx               |    1 -
 sw/source/uibase/fldui/fldmgr.cxx              |    1 -
 sw/source/uibase/inc/dbinsdlg.hxx              |    4 +---
 sw/source/uibase/inc/fldmgr.hxx                |    1 -
 sw/source/uibase/inc/formedt.hxx               |    5 -----
 sw/source/uibase/inc/navipi.hxx                |    1 -
 sw/source/uibase/inc/num.hxx                   |    7 -------
 sw/source/uibase/inc/textsh.hxx                |    1 -
 sw/source/uibase/shells/textsh.cxx             |    2 +-
 sw/source/uibase/sidebar/StylePresetsPanel.cxx |   13 ++++---------
 sw/source/uibase/sidebar/StylePresetsPanel.hxx |   14 ++++----------
 sw/source/uibase/sidebar/SwPanelFactory.cxx    |    4 ++--
 sw/source/uibase/sidebar/ThemePanel.cxx        |   19 ++++++-------------
 sw/source/uibase/sidebar/ThemePanel.hxx        |    8 ++------
 sw/source/uibase/utlui/initui.cxx              |    3 ---
 sw/source/uibase/utlui/navipi.cxx              |    1 -
 59 files changed, 48 insertions(+), 187 deletions(-)

New commits:
commit 872d209bc62aab6a27a7a92734d1670b6e20adbf
Author: Noel Grandin <noel at peralex.com>
Date:   Mon Nov 23 14:47:57 2015 +0200

    loplugin:unusedfields in sw/
    
    Change-Id: I0d9c79d0756ef85260d3b69cb1e879d7665bf356

diff --git a/sw/inc/ccoll.hxx b/sw/inc/ccoll.hxx
index 9c9c64d..313609c 100644
--- a/sw/inc/ccoll.hxx
+++ b/sw/inc/ccoll.hxx
@@ -30,11 +30,6 @@
 #include "swdllapi.h"
 #include "cmdid.h"
 
-struct CollName {
-        sal_uLong nCnd;
-        sal_uLong nSubCond;
-    };
-
 #define COND_COMMAND_COUNT 28
 
 struct CommandStruct
diff --git a/sw/inc/doc.hxx b/sw/inc/doc.hxx
index 52eae86..66376b8 100644
--- a/sw/inc/doc.hxx
+++ b/sw/inc/doc.hxx
@@ -309,8 +309,6 @@ class SW_DLLPUBLIC SwDoc :
     SwDBManager         *mpDBManager;            /**< Pointer to the DBManager for
                                          evaluation of DB-fields. */
 
-    SwDoc           *mpGlossaryDoc;      //< Pointer to glossary-document.
-
     SwNumRule       *mpOutlineRule;
     SwFootnoteInfo       *mpFootnoteInfo;
     SwEndNoteInfo   *mpEndNoteInfo;
@@ -352,16 +350,12 @@ private:
 
     // other
 
-    sal_uInt16  mnUndoCnt;           //< Count of Undo Actions.
-    sal_uInt16  mnUndoSttEnd;        //< != 0 -> within parentheses.
-
     sal_uInt32  mnRsid;              //< current session ID of the document
     sal_uInt32  mnRsidRoot;          //< session ID when the document was created
 
     sal_Int32   mReferenceCount;
 
-    bool mbGlossDoc              : 1;    //< TRUE: glossary document.
-    bool mbDtor                  : 1;    /**< TRUE: is in SwDoc DTOR.
+   bool mbDtor                  : 1;    /**< TRUE: is in SwDoc DTOR.
                                                and unfortunately temorarily also in
                                                SwSwgReader::InLayout() when flawed
                                                frames need deletion. */
@@ -376,7 +370,6 @@ private:
                                                 View
                                                 notification of OLE-Objects PrtOLENotify() is required. */
     bool mbAllOLENotify          : 1;    //< True: Notification of all objects is required.
-    bool mbIsRedlineMove         : 1;    //< True: Redlines are moved into to / out of the section.
     bool mbInsOnlyTextGlssry      : 1;    //< True: insert 'only text' glossary into doc
     bool mbContains_MSVBasic     : 1;    //< True: MS-VBasic exist is in our storage
     bool mbClipBoard             : 1;    //< TRUE: this document represents the clipboard
diff --git a/sw/inc/ndgrf.hxx b/sw/inc/ndgrf.hxx
index d50e682..885311d 100644
--- a/sw/inc/ndgrf.hxx
+++ b/sw/inc/ndgrf.hxx
@@ -40,7 +40,6 @@ class SW_DLLPUBLIC SwGrfNode: public SwNoTextNode
     GraphicObject *mpReplacementGraphic;
     tools::SvRef<sfx2::SvBaseLink> refLink;       ///< If graphics only as link then pointer is set.
     Size nGrfSize;
-    OUString aLowResGrf;                   ///< HTML: LowRes graphics (substitute until regular HighRes graphics is loaded).
     bool bInSwapIn              :1;
 
     bool bGraphicArrived        :1;
diff --git a/sw/inc/ndhints.hxx b/sw/inc/ndhints.hxx
index c885be0..8fbe43b 100644
--- a/sw/inc/ndhints.hxx
+++ b/sw/inc/ndhints.hxx
@@ -89,7 +89,6 @@ private:
 
     SwRegHistory* m_pHistory;                   ///< for Undo
 
-    bool          m_bFontChange          : 1;   ///< font change
     /// true: the Node is in Split and Frames are moved
     bool          m_bInSplitNode         : 1;
     /// m_bHasHiddenParaField is invalid, call CalcHiddenParaField()
diff --git a/sw/inc/shellio.hxx b/sw/inc/shellio.hxx
index 9b8c94e..bf6f001 100644
--- a/sw/inc/shellio.hxx
+++ b/sw/inc/shellio.hxx
@@ -460,7 +460,6 @@ typedef tools::SvRef<Writer> WriterRef;
 class SW_DLLPUBLIC StgWriter : public Writer
 {
 protected:
-    OUString aFltName;
     tools::SvRef<SotStorage> pStg;
     css::uno::Reference < css::embed::XStorage > xStg;
 
diff --git a/sw/inc/shellres.hxx b/sw/inc/shellres.hxx
index ca89be7..15661f6 100644
--- a/sw/inc/shellres.hxx
+++ b/sw/inc/shellres.hxx
@@ -41,13 +41,8 @@ struct SW_DLLPUBLIC ShellResource : public Resource
     OUString        aCalc_Default;
     OUString        aCalc_Error;
 
-    // For GetRefField - up/down.
-    OUString        aGetRefField_Up;
-    OUString        aGetRefField_Down;
     // For GetRefField - referenced item not found.
     OUString        aGetRefField_RefItemNotFound;
-    // For dynamic menu - string "all".
-    OUString        aStrAllPageHeadFoot;
     // For some list boxes - string "none"
     OUString        aStrNone;
     // For fixed fields.
diff --git a/sw/inc/splargs.hxx b/sw/inc/splargs.hxx
index 33fe942..4034340 100644
--- a/sw/inc/splargs.hxx
+++ b/sw/inc/splargs.hxx
@@ -120,8 +120,6 @@ public:
     sal_Int32 nEnd;
     sal_Int32 nWordStart;
     sal_Int32 nWordLen;
-    sal_Int32 nHyphPos;
-    sal_uInt16 nMinTrail;
 
     SwInterHyphInfo( const Point &rCrsrPos, sal_Int32 nStartPos = 0,
         sal_Int32 nLength = SAL_MAX_INT32 )
@@ -131,7 +129,6 @@ public:
         , nStart(nStartPos)
         , nEnd(nLength == SAL_MAX_INT32 ? SAL_MAX_INT32 : nStartPos + nLength)
         , nWordStart(0), nWordLen(0)
-        , nHyphPos(0), nMinTrail(0)
     {
     }
     sal_Int32 GetEnd() const
diff --git a/sw/inc/view.hxx b/sw/inc/view.hxx
index 229f393..42b7f9d 100644
--- a/sw/inc/view.hxx
+++ b/sw/inc/view.hxx
@@ -236,7 +236,6 @@ class SW_DLLPUBLIC SwView: public SfxViewShell
                     m_bTopCrsr : 1,
                     m_bAlwaysShowSel : 1,
                     m_bTabColFromDoc : 1,
-                    m_bNumIndentFromDoc : 1, // #i23726#
                     m_bTabRowFromDoc : 1,
                     m_bSetTabColFromDoc : 1 ,
                     m_bSetTabRowFromDoc : 1,
diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx
index 36d513a..076ca69 100644
--- a/sw/source/core/doc/docnew.cxx
+++ b/sw/source/core/doc/docnew.cxx
@@ -240,7 +240,6 @@ SwDoc::SwDoc()
     mpGrfFormatCollTable( new SwGrfFormatColls() ),
     mpTOXTypes( new SwTOXTypes() ),
     mpDefTOXBases( new SwDefTOXBase_Impl() ),
-    mpGlossaryDoc( nullptr ),
     mpOutlineRule( nullptr ),
     mpFootnoteInfo( new SwFootnoteInfo ),
     mpEndNoteInfo( new SwEndNoteInfo ),
@@ -259,7 +258,6 @@ SwDoc::SwDoc()
     mpTableStyles(new SwTableAutoFormatTable),
     m_pXmlIdRegistry(),
     mReferenceCount(0),
-    mbGlossDoc(false),
     mbDtor(false),
     mbCopyIsMove(false),
     mbInReading(false),
diff --git a/sw/source/core/txtnode/thints.cxx b/sw/source/core/txtnode/thints.cxx
index a51afa3..f2cd600 100644
--- a/sw/source/core/txtnode/thints.cxx
+++ b/sw/source/core/txtnode/thints.cxx
@@ -87,7 +87,6 @@ using namespace ::com::sun::star::i18n;
 
 SwpHints::SwpHints()
     : m_pHistory(nullptr)
-    , m_bFontChange(true)
     , m_bInSplitNode(false)
     , m_bCalcHiddenParaField(false)
     , m_bHasHiddenParaField(false)
diff --git a/sw/source/uibase/utlui/initui.cxx b/sw/source/uibase/utlui/initui.cxx
index 30d009b..cf64f93 100644
--- a/sw/source/uibase/utlui/initui.cxx
+++ b/sw/source/uibase/utlui/initui.cxx
@@ -189,11 +189,8 @@ ShellResource::ShellResource()
     aCalc_Default( SW_RES( STR_CALC_DEFAULT ) ),
     aCalc_Error( SW_RES( STR_CALC_ERROR ) ),
 
-    aGetRefField_Up( SW_RES( STR_GETREFFLD_UP ) ),
-    aGetRefField_Down( SW_RES( STR_GETREFFLD_DOWN ) ),
     // #i81002#
     aGetRefField_RefItemNotFound( SW_RES( STR_GETREFFLD_REFITEMNOTFOUND ) ),
-    aStrAllPageHeadFoot( SW_RES( STR_ALLPAGE_HEADFOOT ) ),
     aStrNone( SW_RES( STR_TEMPLATE_NONE )),
     aFixedStr( SW_RES( STR_FIELD_FIXED )),
     sDurationFormat( SW_RES( STR_DURATION_FORMAT )),
commit 8770cd3894ce27ea7ceea3047af9899be57aae83
Author: Noel Grandin <noel at peralex.com>
Date:   Mon Nov 23 14:32:03 2015 +0200

    loplugin:unusedfields in sw/
    
    Change-Id: I323a038e5581b00cd3a4ea2f362c66540377759e

diff --git a/compilerplugins/clang/unusedfields.py b/compilerplugins/clang/unusedfields.py
index 4b9b6aa..08f0b67 100755
--- a/compilerplugins/clang/unusedfields.py
+++ b/compilerplugins/clang/unusedfields.py
@@ -59,7 +59,8 @@ for d in definitionSet:
     if (srcLoc.startswith("external/")):
         continue
     # this is all representations of on-disk data structures
-    if (srcLoc == "sc/source/filter/inc/scflt.hxx"):
+    if (srcLoc.startswith("sc/source/filter/inc/scflt.hxx")
+        or srcLoc.startswith("sw/source/filter/ww8/")):
         continue
 
     tmp1set.add((clazz, srcLoc))
diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index 2af9cd1..b8504b6 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -231,14 +231,8 @@ private:
 
 public:
 
-#if OSL_DEBUG_LEVEL > 0
-    bool mbLocked;
-#endif
     explicit SwAccessibleShapeMap_Impl( SwAccessibleMap *pMap )
         : maMap()
-#if OSL_DEBUG_LEVEL > 0
-        , mbLocked( false )
-#endif
     {
         maInfo.SetSdrView( pMap->GetShell()->GetDrawView() );
         maInfo.SetWindow( pMap->GetShell()->GetWin() );
diff --git a/sw/source/core/doc/tblrwcl.cxx b/sw/source/core/doc/tblrwcl.cxx
index c46d561..e1c0ccc 100644
--- a/sw/source/core/doc/tblrwcl.cxx
+++ b/sw/source/core/doc/tblrwcl.cxx
@@ -1373,14 +1373,12 @@ struct _InsULPara
     bool bUL : 1;           // Upper-Left(true) or Lower-Right(false) ?
 
     SwTableBox* pLeftBox;
-    SwTableBox* pRightBox;
-    SwTableBox* pMergeBox;
 
     _InsULPara( SwTableNode* pTNd, bool bUpperLower, bool bUpper,
-                SwTableBox* pLeft, SwTableBox* pMerge, SwTableBox* pRight,
+                SwTableBox* pLeft,
                 SwTableLine* pLine=nullptr, SwTableBox* pBox=nullptr )
         : pTableNd( pTNd ), pInsLine( pLine ), pInsBox( pBox ),
-        pLeftBox( pLeft ), pRightBox( pRight ), pMergeBox( pMerge )
+        pLeftBox( pLeft )
         {   bUL_LR = bUpperLower; bUL = bUpper; }
 
     void SetLeft( SwTableBox* pBox=nullptr )
@@ -1617,7 +1615,7 @@ bool SwTable::OldMerge( SwDoc* pDoc, const SwSelBoxes& rBoxes,
 
     // This contains all Lines that are above the selected Area,
     // thus they form a Upper/Lower Line
-    _InsULPara aPara( pTableNd, true, true, pLeftBox, pMergeBox, pRightBox, pInsLine );
+    _InsULPara aPara( pTableNd, true, true, pLeftBox, pInsLine );
 
     // Move the overlapping upper/lower Lines of the selected Area
     for (auto & it : pFndBox->GetLines().front()->GetBoxes())
diff --git a/sw/source/core/inc/MarkManager.hxx b/sw/source/core/inc/MarkManager.hxx
index 5df4e82..6abeb48 100644
--- a/sw/source/core/inc/MarkManager.hxx
+++ b/sw/source/core/inc/MarkManager.hxx
@@ -116,9 +116,6 @@ namespace sw {
             // container for annotation marks
             container_t m_vAnnotationMarks;
 
-            // container for all marks except annotation marks
-            container_t m_vCommonMarks;
-
             SwDoc * const m_pDoc;
     };
     } // namespace mark
diff --git a/sw/source/core/inc/SwXMLTextBlocks.hxx b/sw/source/core/inc/SwXMLTextBlocks.hxx
index 8f96c6d..884af8c 100644
--- a/sw/source/core/inc/SwXMLTextBlocks.hxx
+++ b/sw/source/core/inc/SwXMLTextBlocks.hxx
@@ -35,7 +35,6 @@ class SwXMLTextBlocks : public SwImpBlocks
 {
 protected:
     bool                    bAutocorrBlock;
-    bool                    bBlock;
     SfxObjectShellRef       xDocShellRef;
     sal_uInt16              nFlags;
     OUString                aPackageName;
@@ -49,7 +48,6 @@ protected:
 public:
     css::uno::Reference < css::embed::XStorage > xBlkRoot;
     css::uno::Reference < css::embed::XStorage > xRoot;
-    short               nCurBlk;
     SwXMLTextBlocks( const OUString& rFile );
     SwXMLTextBlocks( const css::uno::Reference < css::embed::XStorage >&, const OUString& rFile );
     void   AddName( const OUString&, const OUString&, const OUString&, bool bOnlyText = false );
diff --git a/sw/source/core/inc/flyfrms.hxx b/sw/source/core/inc/flyfrms.hxx
index 0deb6b7..115f25e 100644
--- a/sw/source/core/inc/flyfrms.hxx
+++ b/sw/source/core/inc/flyfrms.hxx
@@ -30,8 +30,6 @@ class SwFlyAtCntFrm;
 // bound in Content.
 class SwFlyFreeFrm : public SwFlyFrm
 {
-    SwPageFrm *pPage;   // page where the Fly is registered
-
     // #i34753# - flag for at-page anchored Writer fly frames
     // to prevent a positioning - call of method <MakeObjPos()> -, if Writer
     // fly frame is already clipped during its format by the object formatter.
diff --git a/sw/source/core/inc/swblocks.hxx b/sw/source/core/inc/swblocks.hxx
index f309519..90bbb59 100644
--- a/sw/source/core/inc/swblocks.hxx
+++ b/sw/source/core/inc/swblocks.hxx
@@ -38,7 +38,6 @@ public:
     OUString aPackageName;         /// Package name
     bool bIsOnlyTextFlagInit : 1;   /// Is the Flag valid?
     bool bIsOnlyText : 1;           /// Unformatted text
-    bool bInPutMuchBlocks : 1;     /// Put serveral block entries
 
     SwBlockName( const OUString& rShort, const OUString& rLong );
     SwBlockName( const OUString& rShort, const OUString& rLong, const OUString& rPackageName );
diff --git a/sw/source/core/inc/viewimp.hxx b/sw/source/core/inc/viewimp.hxx
index 52c5cf5..e6efdf4 100644
--- a/sw/source/core/inc/viewimp.hxx
+++ b/sw/source/core/inc/viewimp.hxx
@@ -76,9 +76,6 @@ class SwViewShellImp
 
     SwAccessibleMap *m_pAccessibleMap;    // Accessible wrappers
 
-    mutable const SdrObject * m_pSdrObjectCached;
-    mutable OUString m_sSdrObjectCachedComment;
-
     bool m_bFirstPageInvalid : 1; // Pointer to the first Page invalid?
     bool m_bResetHdlHiddenPaint : 1; // Ditto
     bool m_bSmoothUpdate : 1; // For SmoothScroll
diff --git a/sw/source/core/layout/flylay.cxx b/sw/source/core/layout/flylay.cxx
index d365fe2..951f5c8 100644
--- a/sw/source/core/layout/flylay.cxx
+++ b/sw/source/core/layout/flylay.cxx
@@ -45,7 +45,6 @@ using namespace ::com::sun::star;
 
 SwFlyFreeFrm::SwFlyFreeFrm( SwFlyFrameFormat *pFormat, SwFrm* pSib, SwFrm *pAnch ) :
     SwFlyFrm( pFormat, pSib, pAnch ),
-    pPage( nullptr ),
     // #i34753#
     mbNoMakePos( false ),
     // #i37068#
diff --git a/sw/source/core/swg/SwXMLTextBlocks.cxx b/sw/source/core/swg/SwXMLTextBlocks.cxx
index 2f911a5..efb72ea 100644
--- a/sw/source/core/swg/SwXMLTextBlocks.cxx
+++ b/sw/source/core/swg/SwXMLTextBlocks.cxx
@@ -58,9 +58,7 @@ void SwXMLTextBlocks::ResetBlockMode ( )
 SwXMLTextBlocks::SwXMLTextBlocks( const OUString& rFile )
     : SwImpBlocks(rFile)
     , bAutocorrBlock(false)
-    , bBlock(false)
     , nFlags(0)
-    , nCurBlk(0)
 {
     SwDocShell* pDocSh = new SwDocShell ( SfxObjectCreateMode::INTERNAL );
     if( !pDocSh->DoInitNew() )
@@ -104,9 +102,7 @@ SwXMLTextBlocks::SwXMLTextBlocks( const OUString& rFile )
 SwXMLTextBlocks::SwXMLTextBlocks( const uno::Reference < embed::XStorage >& rStg, const OUString& rName )
     : SwImpBlocks( rName )
     , bAutocorrBlock(false)
-    , bBlock(false)
     , nFlags(0)
-    , nCurBlk(0)
 {
     SwDocShell* pDocSh = new SwDocShell ( SfxObjectCreateMode::INTERNAL );
     if( !pDocSh->DoInitNew() )
diff --git a/sw/source/core/swg/swblocks.cxx b/sw/source/core/swg/swblocks.cxx
index 775254a..279b2f4 100644
--- a/sw/source/core/swg/swblocks.cxx
+++ b/sw/source/core/swg/swblocks.cxx
@@ -57,7 +57,7 @@ sal_uInt16 SwImpBlocks::Hash( const OUString& r )
 
 SwBlockName::SwBlockName( const OUString& rShort, const OUString& rLong )
     : aShort( rShort ), aLong( rLong ), aPackageName (rShort),
-    bIsOnlyTextFlagInit( false ), bIsOnlyText( false ), bInPutMuchBlocks(false)
+    bIsOnlyTextFlagInit( false ), bIsOnlyText( false )
 {
     nHashS = SwImpBlocks::Hash( rShort );
     nHashL = SwImpBlocks::Hash( rLong );
@@ -65,7 +65,7 @@ SwBlockName::SwBlockName( const OUString& rShort, const OUString& rLong )
 
 SwBlockName::SwBlockName( const OUString& rShort, const OUString& rLong, const OUString& rPackageName)
     : aShort( rShort ), aLong( rLong ), aPackageName (rPackageName),
-    bIsOnlyTextFlagInit( false ), bIsOnlyText( false ), bInPutMuchBlocks(false)
+    bIsOnlyTextFlagInit( false ), bIsOnlyText( false )
 {
     nHashS = SwImpBlocks::Hash( rShort );
     nHashL = SwImpBlocks::Hash( rLong );
diff --git a/sw/source/core/text/itratr.cxx b/sw/source/core/text/itratr.cxx
index 2a86ba9..56adbd5 100644
--- a/sw/source/core/text/itratr.cxx
+++ b/sw/source/core/text/itratr.cxx
@@ -341,14 +341,13 @@ public:
     VclPtr<OutputDevice> pOut;
     SwViewShell const * pSh;
     sal_uLong &rMin;
-    sal_uLong &rMax;
     sal_uLong &rAbsMin;
     long nRowWidth;
     long nWordWidth;
     long nWordAdd;
     sal_Int32 nNoLineBreak;
-    SwMinMaxArgs( OutputDevice* pOutI, SwViewShell const * pShI, sal_uLong& rMinI, sal_uLong &rMaxI, sal_uLong &rAbsI )
-        : pOut( pOutI ), pSh( pShI ), rMin( rMinI ), rMax( rMaxI ), rAbsMin( rAbsI )
+    SwMinMaxArgs( OutputDevice* pOutI, SwViewShell const * pShI, sal_uLong& rMinI, sal_uLong &rAbsI )
+        : pOut( pOutI ), pSh( pShI ), rMin( rMinI ), rAbsMin( rAbsI )
         { nRowWidth = nWordWidth = nWordAdd = 0; nNoLineBreak = COMPLETE_STRING; }
     void Minimum( long nNew ) const { if( (long)rMin < nNew ) rMin = nNew; }
     void NewWord() { nWordAdd = nWordWidth = 0; }
@@ -617,7 +616,7 @@ void SwTextNode::GetMinMaxSize( sal_uLong nIndex, sal_uLong& rMin, sal_uLong &rM
     sal_Int32 nLen = m_Text.getLength();
     long nAktWidth = 0;
     long nAdd = 0;
-    SwMinMaxArgs aArg( pOut, pSh, rMin, rMax, rAbsMin );
+    SwMinMaxArgs aArg( pOut, pSh, rMin, rAbsMin );
     while( nIdx < nLen )
     {
         sal_Int32 nNextChg = aIter.GetNextAttr();
diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx
index b1ca592..7d483f5 100644
--- a/sw/source/core/text/porlay.cxx
+++ b/sw/source/core/text/porlay.cxx
@@ -1955,13 +1955,6 @@ SwScriptInfo* SwScriptInfo::GetScriptInfo( const SwTextNode& rTNd,
 }
 
 SwParaPortion::SwParaPortion()
-    : m_bFlag00(false)
-    , m_bFlag11(false)
-    , m_bFlag12(false)
-    , m_bFlag13(false)
-    , m_bFlag14(false)
-    , m_bFlag15(false)
-    , m_bFlag16(false)
 {
     FormatReset();
     m_bFlys = m_bFootnoteNum = m_bMargin = false;
diff --git a/sw/source/core/text/porlay.hxx b/sw/source/core/text/porlay.hxx
index 868087d..3e6079b 100644
--- a/sw/source/core/text/porlay.hxx
+++ b/sw/source/core/text/porlay.hxx
@@ -247,16 +247,8 @@ class SwParaPortion : public SwLineLayout
     bool m_bFollowField   : 1; // We have a bit of field left for the Follow
 
     bool m_bFixLineHeight : 1; // Fixed line height
-    bool m_bFootnoteNum    : 1; // contains a footnotenumberportion
-    bool m_bMargin    : 1; // contains a hanging punctuation in the margin
-
-    bool m_bFlag00    : 1;
-    bool m_bFlag11    : 1;
-    bool m_bFlag12    : 1;
-    bool m_bFlag13    : 1;
-    bool m_bFlag14    : 1;
-    bool m_bFlag15    : 1;
-    bool m_bFlag16    : 1;
+    bool m_bFootnoteNum   : 1; // contains a footnotenumberportion
+    bool m_bMargin        : 1; // contains a hanging punctuation in the margin
 
 public:
     SwParaPortion();
diff --git a/sw/source/core/unocore/unofield.cxx b/sw/source/core/unocore/unofield.cxx
index a4d63b8..289bce5 100644
--- a/sw/source/core/unocore/unofield.cxx
+++ b/sw/source/core/unocore/unofield.cxx
@@ -427,12 +427,10 @@ public:
     OUString        m_sParam1;  // Content / Database / NumberingSeparator
     OUString        m_sParam2;  // -    /DataTablename
     OUString        m_sParam3;  // -    /DataFieldName
-    OUString        m_sParam4;
     OUString        m_sParam5;  // -    /DataBaseURL
-    OUString        m_sParam6;  // -    /DataBaseResource
     double          m_fParam1;  // Value / -
     sal_Int8        m_nParam1;  // ChapterNumberingLevel
-    bool        m_bParam1;  // IsExpression
+    bool            m_bParam1;  // IsExpression
     sal_Int32       m_nParam2;
 
     Impl(SwModify *const pModify,
@@ -1086,8 +1084,6 @@ struct SwFieldProperties_Impl
     OUString    sPar2;
     OUString    sPar3;
     OUString    sPar4;
-    OUString    sPar5;
-    OUString    sPar6;
     Date            aDate;
     double          fDouble;
     uno::Sequence<beans::PropertyValue> aPropSeq;
diff --git a/sw/source/core/view/viewimp.cxx b/sw/source/core/view/viewimp.cxx
index 36a9d9d..4d3206e 100644
--- a/sw/source/core/view/viewimp.cxx
+++ b/sw/source/core/view/viewimp.cxx
@@ -95,7 +95,6 @@ SwViewShellImp::SwViewShellImp( SwViewShell *pParent ) :
     m_pLayAction( nullptr ),
     m_pIdleAct( nullptr ),
     m_pAccessibleMap( nullptr ),
-    m_pSdrObjectCached(nullptr),
     m_bFirstPageInvalid( true ),
     m_bResetHdlHiddenPaint( false ),
     m_bSmoothUpdate( false ),
diff --git a/sw/source/filter/html/htmlatr.cxx b/sw/source/filter/html/htmlatr.cxx
index c053eb2..7b64486 100644
--- a/sw/source/filter/html/htmlatr.cxx
+++ b/sw/source/filter/html/htmlatr.cxx
@@ -232,7 +232,6 @@ SwHTMLFormatInfo::SwHTMLFormatInfo( const SwFormat *pF, SwDoc *pDoc, SwDoc *pTem
                               LanguageType eDfltLang,
                               sal_uInt16 nCSS1Script, bool bHardDrop )
     : pFormat(pF)
-    , pRefFormat(nullptr)
     , pItemSet(nullptr)
     , nLeftMargin(0)
     , nRightMargin(0)
diff --git a/sw/source/filter/html/swhtml.cxx b/sw/source/filter/html/swhtml.cxx
index 7e2ea57..54cfe67 100644
--- a/sw/source/filter/html/swhtml.cxx
+++ b/sw/source/filter/html/swhtml.cxx
@@ -284,7 +284,6 @@ SwHTMLParser::SwHTMLParser( SwDoc* pD, SwPaM& rCrsr, SvStream& rIn,
     m_bLBEntrySelected ( false ),
     m_bTAIgnoreNewPara ( false ),
     m_bFixMarqueeWidth ( false ),
-    m_bFixMarqueeHeight ( false ),
     m_bNoParSpace( false ),
     m_bInNoEmbed( false ),
     m_bInTitle( false ),
diff --git a/sw/source/filter/html/swhtml.hxx b/sw/source/filter/html/swhtml.hxx
index 4429254..da2a33a 100644
--- a/sw/source/filter/html/swhtml.hxx
+++ b/sw/source/filter/html/swhtml.hxx
@@ -359,7 +359,6 @@ class SwHTMLParser : public SfxHTMLParser, public SwClient
 
     OUString      m_aPathToFile;
     OUString      m_sBaseURL;
-    OUString      m_sSaveBaseURL;
     OUString      m_aBasicLib;
     OUString      m_aBasicModule;
     OUString      m_aScriptSource;  // Inhalt des aktuellen Script-Blocks
@@ -451,7 +450,6 @@ class SwHTMLParser : public SfxHTMLParser, public SwClient
     bool m_bLBEntrySelected : 1;  // Ist der aktuelle Listbox-Eintrag selekt.
     bool m_bTAIgnoreNewPara : 1;  // naechstes LF in TextArea ignorieren?
     bool m_bFixMarqueeWidth : 1;  // Groesse einer Laufschrift anpassen?
-    bool m_bFixMarqueeHeight : 1;
 
     bool m_bUpperSpace : 1;       // obererer Absatz-Abstand wird benoetigt
     bool m_bNoParSpace : 1;
diff --git a/sw/source/filter/html/wrthtml.cxx b/sw/source/filter/html/wrthtml.cxx
index 28f7c8f..f66e876 100644
--- a/sw/source/filter/html/wrthtml.cxx
+++ b/sw/source/filter/html/wrthtml.cxx
@@ -1417,7 +1417,6 @@ HTMLSaveData::HTMLSaveData(SwHTMLWriter& rWriter, sal_uLong nStt,
     , bOldOutHeader(rWrt.m_bOutHeader)
     , bOldOutFooter(rWrt.m_bOutFooter)
     , bOldOutFlyFrame(rWrt.m_bOutFlyFrame)
-    , pOldFlyFormat(nullptr)
 {
     bOldWriteAll = rWrt.bWriteAll;
 
diff --git a/sw/source/filter/html/wrthtml.hxx b/sw/source/filter/html/wrthtml.hxx
index 9a2704a..8a65c81 100644
--- a/sw/source/filter/html/wrthtml.hxx
+++ b/sw/source/filter/html/wrthtml.hxx
@@ -211,7 +211,6 @@ public:
 struct SwHTMLFormatInfo
 {
     const SwFormat *pFormat;      // das Format selbst
-    const SwFormat *pRefFormat;   // das Vergleichs-Format
 
     OString aToken;          // das auszugebende Token
     OUString aClass;          // die auszugebende Klasse
@@ -230,7 +229,6 @@ struct SwHTMLFormatInfo
     // Konstruktor fuer einen Dummy zum Suchen
     explicit SwHTMLFormatInfo( const SwFormat *pF ) :
         pFormat( pF ),
-        pRefFormat(nullptr),
         pItemSet( nullptr ),
         nLeftMargin( 0 ),
         nRightMargin( 0 ),
@@ -624,7 +622,6 @@ struct HTMLSaveData
     bool bOldOutHeader : 1;
     bool bOldOutFooter : 1;
     bool bOldOutFlyFrame : 1;
-    const SwFlyFrameFormat* pOldFlyFormat;
 
     HTMLSaveData( SwHTMLWriter&, sal_uLong nStt, sal_uLong nEnd,
                   bool bSaveNum=true,
diff --git a/sw/source/filter/inc/wrtswtbl.hxx b/sw/source/filter/inc/wrtswtbl.hxx
index 47ea399..5581971 100644
--- a/sw/source/filter/inc/wrtswtbl.hxx
+++ b/sw/source/filter/inc/wrtswtbl.hxx
@@ -251,7 +251,6 @@ protected:
     bool m_bGetLineHeightCalled : 1;
 #endif
 
-    bool bColsOption : 1;
     bool bColTags : 1;
     bool bLayoutExport : 1;
     bool bCollectBorderWidth : 1;
diff --git a/sw/source/filter/writer/wrtswtbl.cxx b/sw/source/filter/writer/wrtswtbl.cxx
index a9475d2..5cd0bd4 100644
--- a/sw/source/filter/writer/wrtswtbl.cxx
+++ b/sw/source/filter/writer/wrtswtbl.cxx
@@ -732,7 +732,7 @@ SwWriteTable::SwWriteTable(const SwTable* pTable, const SwTableLines& rLines, lo
 #ifdef DBG_UTIL
     m_bGetLineHeightCalled(false),
 #endif
-    bColsOption(false), bColTags(true), bLayoutExport(false),
+    bColTags(true), bLayoutExport(false),
     bCollectBorderWidth(true)
 {
     sal_uInt32 nParentWidth = nBaseWidth + nLeftSub + nRightSub;
@@ -765,7 +765,6 @@ SwWriteTable::SwWriteTable(const SwTable* pTable, const SwHTMLTableLayout *pLayo
 #ifdef DBG_UTIL
     m_bGetLineHeightCalled(false),
 #endif
-    bColsOption(pLayoutInfo->HasColsOption()),
     bColTags(pLayoutInfo->HasColTags()), bLayoutExport(true),
     bCollectBorderWidth(pLayoutInfo->HaveBordersChanged())
 {
diff --git a/sw/source/filter/ww8/wrtww8.hxx b/sw/source/filter/ww8/wrtww8.hxx
index d9eb627..9bfb0bd 100644
--- a/sw/source/filter/ww8/wrtww8.hxx
+++ b/sw/source/filter/ww8/wrtww8.hxx
@@ -437,7 +437,6 @@ struct MSWordSaveData
 
     bool bOldWriteAll : 1;          ///< WW8Export only
     bool bOldOutTable : 1;
-    bool bOldIsInTable: 1;
     bool bOldFlyFrmAttrs : 1;
     bool bOldStartTOX : 1;
     bool bOldInWriteTOX : 1;
diff --git a/sw/source/filter/ww8/ww8par3.cxx b/sw/source/filter/ww8/ww8par3.cxx
index b08071a..ba0d4f0 100644
--- a/sw/source/filter/ww8/ww8par3.cxx
+++ b/sw/source/filter/ww8/ww8par3.cxx
@@ -430,7 +430,6 @@ struct WW8LFOInfo   // unsortiert, d.h. Reihenfolge genau wie im WW8 Stream
 
     bool bOverride  :1;// Flag, ob die NumRule nicht in maLSTInfos steht,
                         //   sondern fuer m_LFOInfos NEU angelegt wurde
-    bool bSimpleList:1;// Flag, ob diese NumRule nur einen Level verwendet
     bool bUsedInDoc :1;// Flag, ob diese NumRule im Doc verwendet wird,
                                                      //   oder beim Reader-Ende geloescht werden sollte
     bool bLSTbUIDSet    :1;// Flag, ob bUsedInDoc in maLSTInfos gesetzt wurde,
@@ -445,7 +444,6 @@ WW8LFOInfo::WW8LFOInfo(const WW8LFO& rLFO)
     , nIdLst(rLFO.nIdLst)
     , nLfoLvl(rLFO.nLfoLvl)
     , bOverride(rLFO.nLfoLvl != 0)
-    , bSimpleList(rLFO.bSimpleList)
     , bUsedInDoc(false)
     , bLSTbUIDSet(false)
 {
diff --git a/sw/source/filter/xml/xmlexp.cxx b/sw/source/filter/xml/xmlexp.cxx
index dfce3ca..7dd8d1b 100644
--- a/sw/source/filter/xml/xmlexp.cxx
+++ b/sw/source/filter/xml/xmlexp.cxx
@@ -94,8 +94,7 @@ SwXMLExport::SwXMLExport(
     bSavedShowChanges( false ),
     doc( nullptr ),
     sNumberFormat("NumberFormat"),
-    sIsProtected("IsProtected"),
-    sCell("Cell")
+    sIsProtected("IsProtected")
 {
     _InitItemExport();
 }
diff --git a/sw/source/filter/xml/xmlexp.hxx b/sw/source/filter/xml/xmlexp.hxx
index c7450ae..1319bdc 100644
--- a/sw/source/filter/xml/xmlexp.hxx
+++ b/sw/source/filter/xml/xmlexp.hxx
@@ -101,7 +101,6 @@ class SwXMLExport : public SvXMLExport
     // string constants for table cell export
     const OUString sNumberFormat;
     const OUString sIsProtected;
-    const OUString sCell;
 
     void setBlockMode();
 private:
diff --git a/sw/source/filter/xml/xmltexte.cxx b/sw/source/filter/xml/xmltexte.cxx
index 1091ddd..d310886 100644
--- a/sw/source/filter/xml/xmltexte.cxx
+++ b/sw/source/filter/xml/xmltexte.cxx
@@ -174,7 +174,6 @@ SwXMLTextParagraphExport::SwXMLTextParagraphExport(
         SwXMLExport& rExp,
          SvXMLAutoStylePoolP& _rAutoStylePool ) :
     XMLTextParagraphExport( rExp, _rAutoStylePool ),
-    sTextTable( "TextTable" ),
     sEmbeddedObjectProtocol( "vnd.sun.star.EmbeddedObject:" ),
     sGraphicObjectProtocol( "vnd.sun.star.GraphicObject:" ),
     aAppletClassId( SO3_APPLET_CLASSID ),
diff --git a/sw/source/filter/xml/xmltexte.hxx b/sw/source/filter/xml/xmltexte.hxx
index a1a12b4..83140ac 100644
--- a/sw/source/filter/xml/xmltexte.hxx
+++ b/sw/source/filter/xml/xmltexte.hxx
@@ -32,7 +32,6 @@ namespace com { namespace sun { namespace star { namespace style {
 
 class SwXMLTextParagraphExport : public XMLTextParagraphExport
 {
-    const OUString sTextTable;
     const OUString sEmbeddedObjectProtocol;
     const OUString sGraphicObjectProtocol;
 
commit c65b2347648fc2c0752b981896cc6c2c7b7020f9
Author: Noel Grandin <noel at peralex.com>
Date:   Mon Nov 23 13:54:56 2015 +0200

    loplugin:unusedfields in sw/
    
    Change-Id: I975f35031b1833be376881d534dc6f91fae6072f

diff --git a/sw/source/ui/config/optcomp.cxx b/sw/source/ui/config/optcomp.cxx
index d0452ab..c3963c3 100644
--- a/sw/source/ui/config/optcomp.cxx
+++ b/sw/source/ui/config/optcomp.cxx
@@ -56,14 +56,13 @@ struct CompatibilityItem
     bool        m_bConsiderWrappingStyle;
     bool        m_bExpandWordSpace;
     bool        m_bIsDefault;
-    bool        m_bIsUser;
 
     CompatibilityItem( const OUString& _rName, const OUString& _rModule,
                        bool _bUsePrtMetrics, bool _bAddSpacing, bool _bAddSpacingAtPages,
                        bool _bUseOurTabStops, bool _bNoExtLeading, bool _bUseLineSpacing,
                        bool _bAddTableSpacing, bool _bUseObjPos, bool _bUseOurTextWrapping,
                        bool _bConsiderWrappingStyle, bool _bExpandWordSpace,
-                       bool _bIsDefault, bool _bIsUser ) :
+                       bool _bIsDefault ) :
 
         m_sName                 ( _rName ),
         m_sModule               ( _rModule ),
@@ -78,8 +77,7 @@ struct CompatibilityItem
         m_bUseOurTextWrapping   ( _bUseOurTextWrapping ),
         m_bConsiderWrappingStyle( _bConsiderWrappingStyle ),
         m_bExpandWordSpace      ( _bExpandWordSpace ),
-        m_bIsDefault            ( _bIsDefault ),
-        m_bIsUser               ( _bIsUser ) {}
+        m_bIsDefault            ( _bIsDefault ) {}
 };
 
 #include <vector>
@@ -275,8 +273,7 @@ void SwCompatibilityOptPage::InitControls( const SfxItemSet& rSet )
             bAddSpacingAtPages, bUseOurTabStops, bNoExtLeading,
             bUseLineSpacing, bAddTableSpacing, bUseObjPos,
             bUseOurTextWrapping, bConsiderWrappingStyle, bExpandWordSpace,
-            bIsDefaultEntry,
-            bIsUserEntry );
+            bIsDefaultEntry );
         m_pImpl->m_aList.push_back( aItem );
 
         if ( aItem.m_bIsDefault )
diff --git a/sw/source/ui/dbui/dbinsdlg.cxx b/sw/source/ui/dbui/dbinsdlg.cxx
index af571d1..24eb196 100644
--- a/sw/source/ui/dbui/dbinsdlg.cxx
+++ b/sw/source/ui/dbui/dbinsdlg.cxx
@@ -265,7 +265,7 @@ SwInsertDBColAutoPilot::SwInsertDBColAutoPilot( SwView& rView,
         sal_Int32 nCount = aColNames.getLength();
         for (sal_Int32 n = 0; n < nCount; ++n)
         {
-            SwInsDBColumn* pNew = new SwInsDBColumn( pColNames[n], (sal_uInt16)n );
+            SwInsDBColumn* pNew = new SwInsDBColumn( pColNames[n] );
             Any aCol = xCols->getByName(pColNames[n]);
             Reference <XPropertySet> xCol;
             aCol >>= xCol;
@@ -491,7 +491,7 @@ IMPL_LINK_TYPED( SwInsertDBColAutoPilot, DBFormatHdl, Button*, pButton, void )
                             : *m_pLbTableCol )
                         : *m_pLbTextDbColumn;
 
-    SwInsDBColumn aSrch( rBox.GetSelectEntry(), 0 );
+    SwInsDBColumn aSrch( rBox.GetSelectEntry() );
     SwInsDBColumns::const_iterator it = aDBColumns.find( &aSrch );
 
     bool bFromDB = m_pRbDbFormatFromDb == pButton;
@@ -547,7 +547,7 @@ IMPL_LINK_TYPED( SwInsertDBColAutoPilot, TableToFromHdl, Button*, pButton, void
                     nTopPos = m_pLbTableCol->GetTopEntry();
 
             // look for the right InsertPos!!
-            SwInsDBColumn aSrch( m_pLbTableCol->GetEntry( nDelPos ), 0 );
+            SwInsDBColumn aSrch( m_pLbTableCol->GetEntry( nDelPos ) );
             SwInsDBColumns::const_iterator it = aDBColumns.find( &aSrch );
             if( it == aDBColumns.begin() || (it+1) == aDBColumns.end() )
                 nInsPos = it - aDBColumns.begin();
@@ -795,7 +795,7 @@ IMPL_LINK_TYPED( SwInsertDBColAutoPilot, SelectHdl, ListBox&, rBox, void )
                                     : m_pLbTextDbColumn.get() )
                             : &rBox;
 
-    SwInsDBColumn aSrch( pGetBox->GetSelectEntry(), 0 );
+    SwInsDBColumn aSrch( pGetBox->GetSelectEntry() );
     SwInsDBColumns::const_iterator it = aDBColumns.find( &aSrch );
 
     if( &rBox == m_pLbDbFormatFromUsr )
@@ -890,7 +890,7 @@ bool SwInsertDBColAutoPilot::SplitTextToColArr( const OUString& rText,
         if( -1 != ( nEndPos = sText.indexOf( cDBFieldEnd, nSttPos+1 )))
         {
             // Text in <> brackets found: what is it:
-            SwInsDBColumn aSrch( sText.copy( nSttPos, nEndPos - nSttPos ), 0);
+            SwInsDBColumn aSrch( sText.copy( nSttPos, nEndPos - nSttPos ));
             SwInsDBColumns::const_iterator it = aDBColumns.find( &aSrch );
             if( it != aDBColumns.end() )
             {
@@ -1006,7 +1006,7 @@ void SwInsertDBColAutoPilot::DataToDoc( const Sequence<Any>& rSelection,
         std::vector<SwInsDBColumn*> aColFields;
         for( sal_Int32 n = 0; n < nCols; ++n )
         {
-            SwInsDBColumn aSrch( m_pLbTableCol->GetEntry( n ), 0 );
+            SwInsDBColumn aSrch( m_pLbTableCol->GetEntry( n ) );
             SwInsDBColumns::const_iterator it = aDBColumns.find( &aSrch );
             if (it != aDBColumns.end())
                 aColFields.push_back(*it);
@@ -1698,7 +1698,7 @@ void SwInsertDBColAutoPilot::Load()
                     continue;
                 sal_Int16 nIndex = 0;
                 pSubProps[1] >>= nIndex;
-                SwInsDBColumn* pInsDBColumn = new SwInsDBColumn(sColumn, nIndex);
+                SwInsDBColumn* pInsDBColumn = new SwInsDBColumn(sColumn);
                 if(pSubProps[2].hasValue())
                     pInsDBColumn->bHasFormat = *static_cast<sal_Bool const *>(pSubProps[2].getValue());
                 if(pSubProps[3].hasValue())
diff --git a/sw/source/ui/envelp/swuilabimp.hxx b/sw/source/ui/envelp/swuilabimp.hxx
index c7aff3e..0b6207f 100644
--- a/sw/source/ui/envelp/swuilabimp.hxx
+++ b/sw/source/ui/envelp/swuilabimp.hxx
@@ -90,8 +90,6 @@ class SwVisitingCardPage : public SfxTabPage
     VclPtr<ListBox>        m_pAutoTextGroupLB;
     VclPtr<vcl::Window>    m_pExampleWIN;
 
-    OUString        sTempURL;
-
     SwLabItem       aLabItem;
 
     SwOneExampleFrame*  pExampleFrame;
diff --git a/sw/source/ui/vba/vbastyles.cxx b/sw/source/ui/vba/vbastyles.cxx
index 2cebd3e..d460358 100644
--- a/sw/source/ui/vba/vbastyles.cxx
+++ b/sw/source/ui/vba/vbastyles.cxx
@@ -148,13 +148,12 @@ struct MSOStyleNameTable
 {
     const sal_Char* pMSOStyleName;
     const sal_Char* pOOoStyleName;
-    const sal_Char* pOOoStyleType;
 };
 
 static const MSOStyleNameTable aMSOStyleNameTable[] =
 {
-    { "Normal", "Default", "ParagraphStyles" },
-    { nullptr, nullptr, nullptr }
+    { "Normal", "Default" },
+    { nullptr, nullptr }
 };
 
 class StyleCollectionHelper : public ::cppu::WeakImplHelper< container::XNameAccess,
diff --git a/sw/source/uibase/dbui/dbtree.cxx b/sw/source/uibase/dbui/dbtree.cxx
index 2610609..a4eca98 100644
--- a/sw/source/uibase/dbui/dbtree.cxx
+++ b/sw/source/uibase/dbui/dbtree.cxx
@@ -63,7 +63,6 @@ using namespace ::com::sun::star::beans;
 
 struct SwConnectionData
 {
-    OUString                sSourceName;
     Reference<XConnection>  xConnection;
 };
 
diff --git a/sw/source/uibase/fldui/fldmgr.cxx b/sw/source/uibase/fldui/fldmgr.cxx
index cd0c9a0..673cac0 100644
--- a/sw/source/uibase/fldui/fldmgr.cxx
+++ b/sw/source/uibase/fldui/fldmgr.cxx
@@ -217,7 +217,6 @@ inline sal_uInt16 GetPackCount() {  return sizeof(aSwFields) / sizeof(SwFieldPac
 
 // FieldManager controls inserting and updating of fields
 SwFieldMgr::SwFieldMgr(SwWrtShell* pSh ) :
-    pModule(nullptr),
     pMacroItem(nullptr),
     pWrtShell(pSh),
     bEvalExp(true)
diff --git a/sw/source/uibase/inc/dbinsdlg.hxx b/sw/source/uibase/inc/dbinsdlg.hxx
index 59c1b5f..1313e4e 100644
--- a/sw/source/uibase/inc/dbinsdlg.hxx
+++ b/sw/source/uibase/inc/dbinsdlg.hxx
@@ -63,16 +63,14 @@ struct SwInsDBColumn
     sal_Int32 nDBNumFormat;
     sal_uInt32 nUsrNumFormat;
     LanguageType eUsrNumFormatLng;
-    sal_uInt16 nCol;
     bool bHasFormat : 1;
     bool bIsDBFormat : 1;
 
-    SwInsDBColumn( const OUString& rStr, sal_uInt16 nColumn )
+    SwInsDBColumn( const OUString& rStr )
         : sColumn( rStr ),
         nDBNumFormat( 0 ),
         nUsrNumFormat( 0 ),
         eUsrNumFormatLng( LANGUAGE_SYSTEM ),
-        nCol( nColumn ),
         bHasFormat(false),
         bIsDBFormat(true)
     {}
diff --git a/sw/source/uibase/inc/fldmgr.hxx b/sw/source/uibase/inc/fldmgr.hxx
index a8bdfc4..832dfd36 100644
--- a/sw/source/uibase/inc/fldmgr.hxx
+++ b/sw/source/uibase/inc/fldmgr.hxx
@@ -100,7 +100,6 @@ class SW_DLLPUBLIC SwFieldMgr
 {
 private:
     SwField*            pCurField;
-    SbModule*           pModule;
     const SvxMacroItem* pMacroItem;
     SwWrtShell*         pWrtShell; // can be ZERO too!
     OUString          aCurPar1;
diff --git a/sw/source/uibase/inc/formedt.hxx b/sw/source/uibase/inc/formedt.hxx
index 9439c4a..320d227 100644
--- a/sw/source/uibase/inc/formedt.hxx
+++ b/sw/source/uibase/inc/formedt.hxx
@@ -57,11 +57,6 @@ class SwIdxFormDlg : public SvxStandardDialog
     VclPtr<PushButton>      m_aAssignBT;
     VclPtr<FixedLine>       m_aFormatFL;
 
-    SwWrtShell     &m_rSh;
-    SwForm         *m_pForm;
-    sal_uInt16          m_nAktLevel;
-    bool            m_bLastLinkIsEnd;
-
 public:
     SwIdxFormDlg( vcl::Window* pParent, SwWrtShell &rShell, const SwForm& rForm );
     virtual ~SwIdxFormDlg();
diff --git a/sw/source/uibase/inc/navipi.hxx b/sw/source/uibase/inc/navipi.hxx
index 5d74116..761f495 100644
--- a/sw/source/uibase/inc/navipi.hxx
+++ b/sw/source/uibase/inc/navipi.hxx
@@ -90,7 +90,6 @@ class SwNavigationPI : public vcl::Window,
     short   m_nZoomOutInit;
     short   m_nZoomOut;
 
-    bool    m_bSmallMode : 1;
     bool    m_bIsZoomedIn : 1;
     bool    m_bPageCtrlsVisible : 1;
     bool    m_bGlobalMode : 1;
diff --git a/sw/source/uibase/inc/num.hxx b/sw/source/uibase/inc/num.hxx
index de8d9e5..fb5880b 100644
--- a/sw/source/uibase/inc/num.hxx
+++ b/sw/source/uibase/inc/num.hxx
@@ -36,13 +36,6 @@ class SwWrtShell;
 class SvxBrushItem;
 class SwOutlineTabDialog;
 
-struct SwBmpItemInfo
-{
-    SvxBrushItem*   pBrushItem;
-    sal_uInt16          nItemId;
-};
-
-
 class SwNumPositionTabPage : public SfxTabPage
 {
     VclPtr<ListBox> m_pLevelLB;
diff --git a/sw/source/uibase/inc/textsh.hxx b/sw/source/uibase/inc/textsh.hxx
index 9abef5b..e28067d 100644
--- a/sw/source/uibase/inc/textsh.hxx
+++ b/sw/source/uibase/inc/textsh.hxx
@@ -30,7 +30,6 @@ class SvxHyperlinkItem;
 
 class SW_DLLPUBLIC SwTextShell: public SwBaseShell
 {
-    SwFieldMgr*   pPostItFieldMgr;
     RotateTransliteration m_aRotateCase;
 
     void InsertSymbol( SfxRequest& );
diff --git a/sw/source/uibase/shells/textsh.cxx b/sw/source/uibase/shells/textsh.cxx
index c0d542e..2ea08ce 100644
--- a/sw/source/uibase/shells/textsh.cxx
+++ b/sw/source/uibase/shells/textsh.cxx
@@ -925,7 +925,7 @@ void SwTextShell::ExecRotateTransliteration( SfxRequest & rReq )
 }
 
 SwTextShell::SwTextShell(SwView &_rView) :
-    SwBaseShell(_rView), pPostItFieldMgr( nullptr )
+    SwBaseShell(_rView)
 {
     SetName("Text");
     SetHelpId(SW_TEXTSHELL);
diff --git a/sw/source/uibase/utlui/navipi.cxx b/sw/source/uibase/utlui/navipi.cxx
index 8a26ff7..149d047 100644
--- a/sw/source/uibase/utlui/navipi.cxx
+++ b/sw/source/uibase/utlui/navipi.cxx
@@ -665,7 +665,6 @@ SwNavigationPI::SwNavigationPI( SfxBindings* _pBindings,
     m_nAutoMarkIdx(1),
     m_nRegionMode(RegionMode::NONE),
 
-    m_bSmallMode(false),
     m_bIsZoomedIn(false),
     m_bPageCtrlsVisible(false),
     m_bGlobalMode(false)
commit c43ee8d54ad44e01d0bba404e719d2b03a73959e
Author: Noel Grandin <noel at peralex.com>
Date:   Mon Nov 23 13:47:22 2015 +0200

    loplugin:unusedfields in sw/
    
    Change-Id: I3e146c4287df70bbf58443caecfa62453c116ecb

diff --git a/sw/source/uibase/sidebar/StylePresetsPanel.cxx b/sw/source/uibase/sidebar/StylePresetsPanel.cxx
index 656054d..db3b760 100644
--- a/sw/source/uibase/sidebar/StylePresetsPanel.cxx
+++ b/sw/source/uibase/sidebar/StylePresetsPanel.cxx
@@ -144,24 +144,19 @@ BitmapEx CreatePreview(OUString& aUrl, OUString& aName)
 }
 
 VclPtr<vcl::Window> StylePresetsPanel::Create (vcl::Window* pParent,
-                                        const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                                        SfxBindings* pBindings)
+                                        const css::uno::Reference<css::frame::XFrame>& rxFrame)
 {
     if (pParent == nullptr)
         throw css::lang::IllegalArgumentException("no parent Window given to StylePresetsPanel::Create", nullptr, 0);
     if (!rxFrame.is())
         throw css::lang::IllegalArgumentException("no XFrame given to StylePresetsPanel::Create", nullptr, 1);
-    if (pBindings == nullptr)
-        throw css::lang::IllegalArgumentException("no SfxBindings given to StylePresetsPanel::Create", nullptr, 2);
 
-    return VclPtr<StylePresetsPanel>::Create(pParent, rxFrame, pBindings);
+    return VclPtr<StylePresetsPanel>::Create(pParent, rxFrame);
 }
 
 StylePresetsPanel::StylePresetsPanel(vcl::Window* pParent,
-                               const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                               SfxBindings* pBindings)
+                               const css::uno::Reference<css::frame::XFrame>& rxFrame)
     : PanelLayout(pParent, "StylePresetsPanel", "modules/swriter/ui/sidebarstylepresets.ui", rxFrame)
-    , mpBindings(pBindings)
 {
     get(mpValueSet, "valueset");
 
@@ -187,7 +182,7 @@ void StylePresetsPanel::RefreshList()
                 OUString aURL = aTemplates.GetPath(i,j);
                 BitmapEx aPreview = CreatePreview(aURL, aName);
                 mpValueSet->InsertItem(j, Image(aPreview), aName);
-                maTemplateEntries.push_back(std::unique_ptr<TemplateEntry>(new TemplateEntry(aName, aURL)));
+                maTemplateEntries.push_back(std::unique_ptr<TemplateEntry>(new TemplateEntry(aURL)));
                 mpValueSet->SetItemData(j, maTemplateEntries.back().get());
             }
         }
diff --git a/sw/source/uibase/sidebar/StylePresetsPanel.hxx b/sw/source/uibase/sidebar/StylePresetsPanel.hxx
index 921c056..d0ca775 100644
--- a/sw/source/uibase/sidebar/StylePresetsPanel.hxx
+++ b/sw/source/uibase/sidebar/StylePresetsPanel.hxx
@@ -48,8 +48,7 @@ class StylePresetsPanel : public PanelLayout,
     friend class VclPtr<StylePresetsPanel>;
 public:
     static VclPtr<vcl::Window> Create(vcl::Window* pParent,
-                                  const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                                  SfxBindings* pBindings);
+                                  const css::uno::Reference<css::frame::XFrame>& rxFrame);
 
     virtual void NotifyItemUpdate(const sal_uInt16 nSId,
                                   const SfxItemState eState,
@@ -59,26 +58,21 @@ public:
 private:
     struct TemplateEntry
     {
-        TemplateEntry(OUString& rName, OUString& rURL)
-            : maName(rName)
-            , maURL(rURL)
+        TemplateEntry(OUString& rURL)
+            : maURL(rURL)
         {}
 
-        OUString maName;
         OUString maURL;
     };
 
     void RefreshList();
 
     StylePresetsPanel(vcl::Window* pParent,
-                   const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                   SfxBindings* pBindings);
+                   const css::uno::Reference<css::frame::XFrame>& rxFrame);
 
     virtual ~StylePresetsPanel();
     virtual void dispose() override;
 
-    SfxBindings* mpBindings;
-
     VclPtr<ValueSet> mpValueSet;
 
     std::vector<std::unique_ptr<TemplateEntry>> maTemplateEntries;
diff --git a/sw/source/uibase/sidebar/SwPanelFactory.cxx b/sw/source/uibase/sidebar/SwPanelFactory.cxx
index 4a5d33a..dc048745 100644
--- a/sw/source/uibase/sidebar/SwPanelFactory.cxx
+++ b/sw/source/uibase/sidebar/SwPanelFactory.cxx
@@ -156,13 +156,13 @@ Reference<ui::XUIElement> SAL_CALL SwPanelFactory::createUIElement (
     }
     else if (rsResourceURL.endsWith("/StylePresetsPanel"))
     {
-        VclPtr<vcl::Window> pPanel = sw::sidebar::StylePresetsPanel::Create(pParentWindow, xFrame, pBindings);
+        VclPtr<vcl::Window> pPanel = sw::sidebar::StylePresetsPanel::Create(pParentWindow, xFrame);
         xElement = sfx2::sidebar::SidebarPanelBase::Create(
                         rsResourceURL, xFrame, pPanel, ui::LayoutSize(-1,-1,-1));
     }
     else if (rsResourceURL.endsWith("/ThemePanel"))
     {
-        VclPtr<vcl::Window> pPanel = sw::sidebar::ThemePanel::Create(pParentWindow, xFrame, pBindings);
+        VclPtr<vcl::Window> pPanel = sw::sidebar::ThemePanel::Create(pParentWindow, xFrame);
         xElement = sfx2::sidebar::SidebarPanelBase::Create(
                         rsResourceURL, xFrame, pPanel, ui::LayoutSize(-1,-1,-1));
     }
diff --git a/sw/source/uibase/sidebar/ThemePanel.cxx b/sw/source/uibase/sidebar/ThemePanel.cxx
index 90694ef..81bf6a4 100644
--- a/sw/source/uibase/sidebar/ThemePanel.cxx
+++ b/sw/source/uibase/sidebar/ThemePanel.cxx
@@ -108,13 +108,11 @@ public:
 
 class StyleSet
 {
-    OUString maName;
     std::vector<StyleRedefinition> maStyles;
 
 public:
-    explicit StyleSet(const OUString& aName)
-        : maName(aName)
-        , maStyles()
+    explicit StyleSet()
+        : maStyles()
     {}
 
     void add(StyleRedefinition aRedefinition)
@@ -137,7 +135,7 @@ public:
 
 StyleSet setupThemes()
 {
-    StyleSet aSet("Default");
+    StyleSet aSet;
 
     {
         StyleRedefinition aRedefinition("Heading 1");
@@ -428,24 +426,19 @@ BitmapEx GenerateColorPreview(const svx::ColorSet& rColorSet)
 namespace sw { namespace sidebar {
 
 VclPtr<vcl::Window> ThemePanel::Create (vcl::Window* pParent,
-                                        const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                                        SfxBindings* pBindings)
+                                        const css::uno::Reference<css::frame::XFrame>& rxFrame)
 {
     if (pParent == nullptr)
         throw css::lang::IllegalArgumentException("no parent Window given to PagePropertyPanel::Create", nullptr, 0);
     if (!rxFrame.is())
         throw css::lang::IllegalArgumentException("no XFrame given to PagePropertyPanel::Create", nullptr, 1);
-    if (pBindings == nullptr)
-        throw css::lang::IllegalArgumentException("no SfxBindings given to PagePropertyPanel::Create", nullptr, 2);
 
-    return VclPtr<ThemePanel>::Create(pParent, rxFrame, pBindings);
+    return VclPtr<ThemePanel>::Create(pParent, rxFrame);
 }
 
 ThemePanel::ThemePanel(vcl::Window* pParent,
-                       const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                       SfxBindings* pBindings)
+                       const css::uno::Reference<css::frame::XFrame>& rxFrame)
     : PanelLayout(pParent, "ThemePanel", "modules/swriter/ui/sidebartheme.ui", rxFrame)
-    , mpBindings(pBindings)
     , maColorSets()
 {
     get(mpListBoxFonts, "listbox_fonts");
diff --git a/sw/source/uibase/sidebar/ThemePanel.hxx b/sw/source/uibase/sidebar/ThemePanel.hxx
index ae8a37e..07d89da 100644
--- a/sw/source/uibase/sidebar/ThemePanel.hxx
+++ b/sw/source/uibase/sidebar/ThemePanel.hxx
@@ -48,8 +48,7 @@ class ThemePanel : public PanelLayout,
     friend class VclPtr<ThemePanel>;
 public:
     static VclPtr<vcl::Window> Create(vcl::Window* pParent,
-                                  const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                                  SfxBindings* pBindings);
+                                  const css::uno::Reference<css::frame::XFrame>& rxFrame);
 
     virtual void NotifyItemUpdate(const sal_uInt16 nSId,
                                   const SfxItemState eState,
@@ -58,14 +57,11 @@ public:
 
 private:
     ThemePanel(vcl::Window* pParent,
-                   const css::uno::Reference<css::frame::XFrame>& rxFrame,
-                   SfxBindings* pBindings);
+                   const css::uno::Reference<css::frame::XFrame>& rxFrame);
     virtual ~ThemePanel();
 
     virtual void dispose() override;
 
-    SfxBindings* mpBindings;
-
     VclPtr<ListBox> mpListBoxFonts;
     VclPtr<ValueSet> mpValueSetColors;
     VclPtr<PushButton> mpApplyButton;


More information about the Libreoffice-commits mailing list