[Libreoffice-commits] core.git: chart2/source sw/inc sw/source vcl/inc vcl/source vcl/unx xmlsecurity/inc xmlsecurity/source

Noel Grandin noel.grandin at collabora.co.uk
Tue Jan 10 06:28:46 UTC 2017


 chart2/source/model/template/BubbleChartTypeTemplate.cxx     |    2 -
 chart2/source/model/template/BubbleDataInterpreter.cxx       |    5 +---
 chart2/source/model/template/BubbleDataInterpreter.hxx       |    3 --
 chart2/source/model/template/ChartTypeTemplate.cxx           |    2 -
 chart2/source/model/template/ColumnLineChartTypeTemplate.cxx |    2 -
 chart2/source/model/template/ColumnLineDataInterpreter.cxx   |    5 +---
 chart2/source/model/template/ColumnLineDataInterpreter.hxx   |    3 --
 chart2/source/model/template/DataInterpreter.cxx             |    4 ---
 chart2/source/model/template/DataInterpreter.hxx             |    5 ----
 chart2/source/model/template/ScatterChartTypeTemplate.cxx    |    2 -
 chart2/source/model/template/StockChartTypeTemplate.cxx      |    2 -
 chart2/source/model/template/StockDataInterpreter.cxx        |    5 +---
 chart2/source/model/template/StockDataInterpreter.hxx        |    3 --
 chart2/source/model/template/XYDataInterpreter.cxx           |    5 +---
 chart2/source/model/template/XYDataInterpreter.hxx           |    2 -
 sw/inc/unocrsr.hxx                                           |   10 +++------
 sw/source/core/unocore/unoobj.cxx                            |    2 -
 vcl/inc/unx/fontmanager.hxx                                  |    1 
 vcl/inc/unx/glyphcache.hxx                                   |    6 -----
 vcl/source/gdi/pdfwriter_impl.hxx                            |   12 -----------
 vcl/unx/generic/fontmanager/fontmanager.cxx                  |    1 
 vcl/unx/generic/glyphs/freetype_glyphcache.cxx               |    1 
 xmlsecurity/inc/framework/signaturecreatorimpl.hxx           |    2 -
 xmlsecurity/inc/framework/signatureengine.hxx                |    5 ----
 xmlsecurity/inc/framework/signatureverifierimpl.hxx          |    3 --
 xmlsecurity/inc/pdfsignaturehelper.hxx                       |    3 --
 xmlsecurity/inc/xsecctl.hxx                                  |    6 -----
 xmlsecurity/source/framework/signaturecreatorimpl.cxx        |    8 +++----
 xmlsecurity/source/framework/signatureengine.cxx             |    4 +--
 xmlsecurity/source/framework/signatureverifierimpl.cxx       |    8 +++----
 xmlsecurity/source/helper/documentsignaturemanager.cxx       |    2 -
 xmlsecurity/source/helper/pdfsignaturehelper.cxx             |    3 --
 xmlsecurity/source/helper/xsecctl.cxx                        |    1 
 xmlsecurity/source/helper/xsecsign.cxx                       |    2 -
 xmlsecurity/source/helper/xsecverify.cxx                     |    2 -
 35 files changed, 43 insertions(+), 89 deletions(-)

New commits:
commit b0229855057ed4d73e73ecd8c501a4564f2237ce
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Mon Jan 9 09:22:34 2017 +0200

    loplugin:unusedfields
    
    Change-Id: I9611511cb3480734dea3c3cbaf0d659071366ad1
    Reviewed-on: https://gerrit.libreoffice.org/32873
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
    Tested-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/chart2/source/model/template/BubbleChartTypeTemplate.cxx b/chart2/source/model/template/BubbleChartTypeTemplate.cxx
index 1d03e50..dfda9be 100644
--- a/chart2/source/model/template/BubbleChartTypeTemplate.cxx
+++ b/chart2/source/model/template/BubbleChartTypeTemplate.cxx
@@ -206,7 +206,7 @@ Reference< chart2::XDataInterpreter > SAL_CALL BubbleChartTypeTemplate::getDataI
     throw (uno::RuntimeException, std::exception)
 {
     if( ! m_xDataInterpreter.is())
-        m_xDataInterpreter.set( new BubbleDataInterpreter( GetComponentContext()) );
+        m_xDataInterpreter.set( new BubbleDataInterpreter );
 
     return m_xDataInterpreter;
 }
diff --git a/chart2/source/model/template/BubbleDataInterpreter.cxx b/chart2/source/model/template/BubbleDataInterpreter.cxx
index ac29630..76b2028 100644
--- a/chart2/source/model/template/BubbleDataInterpreter.cxx
+++ b/chart2/source/model/template/BubbleDataInterpreter.cxx
@@ -36,9 +36,8 @@ using ::com::sun::star::uno::Sequence;
 namespace chart
 {
 
-BubbleDataInterpreter::BubbleDataInterpreter(
-    const uno::Reference< uno::XComponentContext > & xContext ) :
-        DataInterpreter( xContext )
+BubbleDataInterpreter::BubbleDataInterpreter() :
+        DataInterpreter()
 {
 }
 
diff --git a/chart2/source/model/template/BubbleDataInterpreter.hxx b/chart2/source/model/template/BubbleDataInterpreter.hxx
index 4f08d05..59ad9a8 100644
--- a/chart2/source/model/template/BubbleDataInterpreter.hxx
+++ b/chart2/source/model/template/BubbleDataInterpreter.hxx
@@ -27,8 +27,7 @@ namespace chart
 class BubbleDataInterpreter : public DataInterpreter
 {
 public:
-    explicit BubbleDataInterpreter(
-        const css::uno::Reference< css::uno::XComponentContext > & xContext );
+    explicit BubbleDataInterpreter();
     virtual ~BubbleDataInterpreter() override;
 
 protected:
diff --git a/chart2/source/model/template/ChartTypeTemplate.cxx b/chart2/source/model/template/ChartTypeTemplate.cxx
index 1b62e7a..06915ba 100644
--- a/chart2/source/model/template/ChartTypeTemplate.cxx
+++ b/chart2/source/model/template/ChartTypeTemplate.cxx
@@ -376,7 +376,7 @@ Reference< chart2::XDataInterpreter > SAL_CALL ChartTypeTemplate::getDataInterpr
     throw (uno::RuntimeException, std::exception)
 {
     if( ! m_xDataInterpreter.is())
-        m_xDataInterpreter.set( new DataInterpreter( GetComponentContext() ) );
+        m_xDataInterpreter.set( new DataInterpreter );
 
     return m_xDataInterpreter;
 }
diff --git a/chart2/source/model/template/ColumnLineChartTypeTemplate.cxx b/chart2/source/model/template/ColumnLineChartTypeTemplate.cxx
index 100b628..4868df4 100644
--- a/chart2/source/model/template/ColumnLineChartTypeTemplate.cxx
+++ b/chart2/source/model/template/ColumnLineChartTypeTemplate.cxx
@@ -394,7 +394,7 @@ Reference< XDataInterpreter > SAL_CALL ColumnLineChartTypeTemplate::getDataInter
     {
         sal_Int32 nNumberOfLines = 1;
         getFastPropertyValue( PROP_COL_LINE_NUMBER_OF_LINES ) >>= nNumberOfLines;
-        m_xDataInterpreter.set( new ColumnLineDataInterpreter( nNumberOfLines, GetComponentContext() ) );
+        m_xDataInterpreter.set( new ColumnLineDataInterpreter( nNumberOfLines ) );
     }
     else
     {
diff --git a/chart2/source/model/template/ColumnLineDataInterpreter.cxx b/chart2/source/model/template/ColumnLineDataInterpreter.cxx
index aba77b1..3f41a70 100644
--- a/chart2/source/model/template/ColumnLineDataInterpreter.cxx
+++ b/chart2/source/model/template/ColumnLineDataInterpreter.cxx
@@ -41,9 +41,8 @@ namespace chart
 
 // explicit
 ColumnLineDataInterpreter::ColumnLineDataInterpreter(
-    sal_Int32 nNumberOfLines,
-    const Reference< uno::XComponentContext > & xContext ) :
-        DataInterpreter( xContext ),
+    sal_Int32 nNumberOfLines ) :
+        DataInterpreter(),
         m_nNumberOfLines( nNumberOfLines )
 {}
 
diff --git a/chart2/source/model/template/ColumnLineDataInterpreter.hxx b/chart2/source/model/template/ColumnLineDataInterpreter.hxx
index ea7ef0a..5d113be 100644
--- a/chart2/source/model/template/ColumnLineDataInterpreter.hxx
+++ b/chart2/source/model/template/ColumnLineDataInterpreter.hxx
@@ -28,8 +28,7 @@ class ColumnLineDataInterpreter : public DataInterpreter
 {
 public:
     explicit ColumnLineDataInterpreter(
-        sal_Int32 nNumberOfLines,
-        const css::uno::Reference< css::uno::XComponentContext > & xContext );
+        sal_Int32 nNumberOfLines );
     virtual ~ColumnLineDataInterpreter() override;
 
 protected:
diff --git a/chart2/source/model/template/DataInterpreter.cxx b/chart2/source/model/template/DataInterpreter.cxx
index 6ed1547..052fe51 100644
--- a/chart2/source/model/template/DataInterpreter.cxx
+++ b/chart2/source/model/template/DataInterpreter.cxx
@@ -48,9 +48,7 @@ void lcl_ShowDataSource( const Reference< data::XDataSource > & xSource );
 namespace chart
 {
 
-DataInterpreter::DataInterpreter(
-    const Reference< uno::XComponentContext > & xContext ) :
-        m_xContext( xContext )
+DataInterpreter::DataInterpreter()
 {}
 
 DataInterpreter::~DataInterpreter()
diff --git a/chart2/source/model/template/DataInterpreter.hxx b/chart2/source/model/template/DataInterpreter.hxx
index 0a1900a..15bd958 100644
--- a/chart2/source/model/template/DataInterpreter.hxx
+++ b/chart2/source/model/template/DataInterpreter.hxx
@@ -32,7 +32,7 @@ class DataInterpreter : public ::cppu::WeakImplHelper<
         css::lang::XServiceInfo >
 {
 public:
-    explicit DataInterpreter( const css::uno::Reference< css::uno::XComponentContext > & xContext );
+    explicit DataInterpreter();
     virtual ~DataInterpreter() override;
 
     /// XServiceInfo declarations
@@ -77,9 +77,6 @@ protected:
     virtual css::uno::Reference< css::chart2::data::XDataSource > SAL_CALL mergeInterpretedData(
         const css::chart2::InterpretedData& aInterpretedData )
         throw (css::uno::RuntimeException, std::exception) override;
-
-    css::uno::Reference< css::uno::XComponentContext >
-        m_xContext;
 };
 
 } // namespace chart
diff --git a/chart2/source/model/template/ScatterChartTypeTemplate.cxx b/chart2/source/model/template/ScatterChartTypeTemplate.cxx
index 44703f6..3f98f72 100644
--- a/chart2/source/model/template/ScatterChartTypeTemplate.cxx
+++ b/chart2/source/model/template/ScatterChartTypeTemplate.cxx
@@ -387,7 +387,7 @@ Reference< chart2::XDataInterpreter > SAL_CALL ScatterChartTypeTemplate::getData
     throw (uno::RuntimeException, std::exception)
 {
     if( ! m_xDataInterpreter.is())
-        m_xDataInterpreter.set( new XYDataInterpreter( GetComponentContext()) );
+        m_xDataInterpreter.set( new XYDataInterpreter );
 
     return m_xDataInterpreter;
 }
diff --git a/chart2/source/model/template/StockChartTypeTemplate.cxx b/chart2/source/model/template/StockChartTypeTemplate.cxx
index 8d580b6..aa4d41b 100644
--- a/chart2/source/model/template/StockChartTypeTemplate.cxx
+++ b/chart2/source/model/template/StockChartTypeTemplate.cxx
@@ -508,7 +508,7 @@ Reference< XDataInterpreter > SAL_CALL StockChartTypeTemplate::getDataInterprete
     throw (uno::RuntimeException, std::exception)
 {
     if( ! m_xDataInterpreter.is())
-        m_xDataInterpreter.set( new StockDataInterpreter( m_eStockVariant, GetComponentContext() ) );
+        m_xDataInterpreter.set( new StockDataInterpreter( m_eStockVariant ) );
 
     return m_xDataInterpreter;
 }
diff --git a/chart2/source/model/template/StockDataInterpreter.cxx b/chart2/source/model/template/StockDataInterpreter.cxx
index cbd77c7..2e2f5c0 100644
--- a/chart2/source/model/template/StockDataInterpreter.cxx
+++ b/chart2/source/model/template/StockDataInterpreter.cxx
@@ -41,9 +41,8 @@ namespace chart
 
 // explicit
 StockDataInterpreter::StockDataInterpreter(
-    StockChartTypeTemplate::StockVariant eVariant,
-    const Reference< uno::XComponentContext > & xContext ) :
-        DataInterpreter( xContext ),
+    StockChartTypeTemplate::StockVariant eVariant ) :
+        DataInterpreter(),
         m_eStockVariant( eVariant )
 {}
 
diff --git a/chart2/source/model/template/StockDataInterpreter.hxx b/chart2/source/model/template/StockDataInterpreter.hxx
index 9e054af..0fb4df9 100644
--- a/chart2/source/model/template/StockDataInterpreter.hxx
+++ b/chart2/source/model/template/StockDataInterpreter.hxx
@@ -30,8 +30,7 @@ class StockDataInterpreter : public DataInterpreter
 {
 public:
     explicit StockDataInterpreter(
-        StockChartTypeTemplate::StockVariant eVariant,
-        const css::uno::Reference< css::uno::XComponentContext > & xContext );
+        StockChartTypeTemplate::StockVariant eVariant );
     virtual ~StockDataInterpreter() override;
 
 protected:
diff --git a/chart2/source/model/template/XYDataInterpreter.cxx b/chart2/source/model/template/XYDataInterpreter.cxx
index c008a1e..1ecce05 100644
--- a/chart2/source/model/template/XYDataInterpreter.cxx
+++ b/chart2/source/model/template/XYDataInterpreter.cxx
@@ -36,9 +36,8 @@ using ::com::sun::star::uno::Sequence;
 namespace chart
 {
 
-XYDataInterpreter::XYDataInterpreter(
-    const uno::Reference< uno::XComponentContext > & xContext ) :
-        DataInterpreter( xContext )
+XYDataInterpreter::XYDataInterpreter() :
+        DataInterpreter()
 {
 }
 
diff --git a/chart2/source/model/template/XYDataInterpreter.hxx b/chart2/source/model/template/XYDataInterpreter.hxx
index cf8017a..5b730c4 100644
--- a/chart2/source/model/template/XYDataInterpreter.hxx
+++ b/chart2/source/model/template/XYDataInterpreter.hxx
@@ -27,7 +27,7 @@ namespace chart
 class XYDataInterpreter : public DataInterpreter
 {
 public:
-    explicit XYDataInterpreter( const css::uno::Reference< css::uno::XComponentContext > & xContext );
+    explicit XYDataInterpreter();
     virtual ~XYDataInterpreter() override;
 
 protected:
diff --git a/sw/inc/unocrsr.hxx b/sw/inc/unocrsr.hxx
index 55a91cc..f0a5ca3 100644
--- a/sw/inc/unocrsr.hxx
+++ b/sw/inc/unocrsr.hxx
@@ -117,17 +117,16 @@ namespace sw
     {
         public:
             UnoCursorPointer()
-                : m_pCursor(nullptr), m_bSectionRestricted(false)
-            {}
-            UnoCursorPointer(std::shared_ptr<SwUnoCursor> pCursor, bool bSectionRestricted=false)
-                : m_pCursor(pCursor), m_bSectionRestricted(bSectionRestricted)
+                : m_pCursor(nullptr)
+           {}
+            UnoCursorPointer(std::shared_ptr<SwUnoCursor> pCursor)
+                : m_pCursor(pCursor)
             {
                 StartListening(m_pCursor->m_aNotifier);
             }
             UnoCursorPointer(const UnoCursorPointer& rOther)
                 : SfxListener()
                 , m_pCursor(rOther.m_pCursor)
-                , m_bSectionRestricted(rOther.m_bSectionRestricted)
             {
                 if(m_pCursor)
                     StartListening(m_pCursor->m_aNotifier);
@@ -172,7 +171,6 @@ namespace sw
             }
         private:
             std::shared_ptr<SwUnoCursor> m_pCursor;
-            const bool m_bSectionRestricted;
     };
 }
 #endif
diff --git a/sw/source/core/unocore/unoobj.cxx b/sw/source/core/unocore/unoobj.cxx
index c3b1300..e24f886 100644
--- a/sw/source/core/unocore/unoobj.cxx
+++ b/sw/source/core/unocore/unoobj.cxx
@@ -670,7 +670,7 @@ public:
         : m_rPropSet(*aSwMapProvider.GetPropertySet(PROPERTY_MAP_TEXT_CURSOR))
         , m_eType(eType)
         , m_xParentText(xParent)
-        , m_pUnoCursor(rDoc.CreateUnoCursor(rPoint), true)
+        , m_pUnoCursor(rDoc.CreateUnoCursor(rPoint))
     {
         if (pMark)
         {
diff --git a/vcl/inc/unx/fontmanager.hxx b/vcl/inc/unx/fontmanager.hxx
index bf5e7b0..dc714f80 100644
--- a/vcl/inc/unx/fontmanager.hxx
+++ b/vcl/inc/unx/fontmanager.hxx
@@ -142,7 +142,6 @@ class VCL_PLUGIN_PUBLIC PrintFontManager
         int               m_nYMin;
         int               m_nXMax;
         int               m_nYMax;
-        bool              m_bUserOverride;
 
         int               m_nDirectory;       // atom containing system dependent path
         OString           m_aFontFile;        // relative to directory
diff --git a/vcl/inc/unx/glyphcache.hxx b/vcl/inc/unx/glyphcache.hxx
index 935837d..4e31a71 100644
--- a/vcl/inc/unx/glyphcache.hxx
+++ b/vcl/inc/unx/glyphcache.hxx
@@ -176,8 +176,7 @@ private:
     int                     mnWidth;
     int                     mnPrioEmbedded;
     int                     mnPrioAntiAlias;
-    int                     mnPrioAutoHint;
-    FreetypeFontInfo*             mpFontInfo;
+    FreetypeFontInfo*       mpFontInfo;
     FT_Int                  mnLoadFlags;
     double                  mfStretch;
     FT_FaceRec_*            maFaceFT;
@@ -190,9 +189,6 @@ private:
     bool                    mbArtBold;
     bool                    mbUseGamma;
 
-    typedef std::unordered_map<int,int> GlyphSubstitution;
-    GlyphSubstitution       maGlyphSubstitution;
-
     hb_font_t*              mpHbFont;
 };
 
diff --git a/vcl/source/gdi/pdfwriter_impl.hxx b/vcl/source/gdi/pdfwriter_impl.hxx
index b50dc4d..e6c2855 100644
--- a/vcl/source/gdi/pdfwriter_impl.hxx
+++ b/vcl/source/gdi/pdfwriter_impl.hxx
@@ -335,21 +335,9 @@ public:
         FontMapping         m_aMapping;
     };
     typedef std::map< const PhysicalFontFace*, FontSubset > FontSubsetData;
-    struct EmbedCode
-    {
-        sal_Ucs             m_aUnicode;
-        OString        m_aName;
-    };
-    struct EmbedEncoding
-    {
-        sal_Int32                       m_nFontID;
-        std::vector< EmbedCode >        m_aEncVector;
-        std::map< sal_Ucs, sal_Int8 >   m_aCMap;
-    };
     struct EmbedFont
     {
         sal_Int32                       m_nNormalFontID;
-        std::list< EmbedEncoding >      m_aExtendedEncodings;
 
         EmbedFont() : m_nNormalFontID( 0 ) {}
     };
diff --git a/vcl/unx/generic/fontmanager/fontmanager.cxx b/vcl/unx/generic/fontmanager/fontmanager.cxx
index bff7e4e..4e7a22c8 100644
--- a/vcl/unx/generic/fontmanager/fontmanager.cxx
+++ b/vcl/unx/generic/fontmanager/fontmanager.cxx
@@ -106,7 +106,6 @@ PrintFontManager::PrintFont::PrintFont()
 ,   m_nYMin(0)
 ,   m_nXMax(0)
 ,   m_nYMax(0)
-,   m_bUserOverride( false )
 ,   m_nDirectory(0)
 ,   m_nCollectionEntry(0)
 ,   m_nTypeFlags(TYPEFLAG_INVALID)
diff --git a/vcl/unx/generic/glyphs/freetype_glyphcache.cxx b/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
index 50c5eba..6295636 100644
--- a/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
+++ b/vcl/unx/generic/glyphs/freetype_glyphcache.cxx
@@ -375,7 +375,6 @@ FreetypeFont::FreetypeFont( const FontSelectPattern& rFSD, FreetypeFontInfo* pFI
     mnSin( 0 ),
     mnPrioEmbedded(nDefaultPrioEmbedded),
     mnPrioAntiAlias(nDefaultPrioAntiAlias),
-    mnPrioAutoHint(nDefaultPrioAutoHint),
     mpFontInfo( pFI ),
     mnLoadFlags( 0 ),
     maFaceFT( nullptr ),
diff --git a/xmlsecurity/inc/framework/signaturecreatorimpl.hxx b/xmlsecurity/inc/framework/signaturecreatorimpl.hxx
index ce5e01f..cdf0da4 100644
--- a/xmlsecurity/inc/framework/signaturecreatorimpl.hxx
+++ b/xmlsecurity/inc/framework/signaturecreatorimpl.hxx
@@ -67,7 +67,7 @@ private:
         throw (css::uno::Exception, css::uno::RuntimeException) override;
 
 public:
-    explicit SignatureCreatorImpl( const css::uno::Reference< css::uno::XComponentContext > & xContext );
+    explicit SignatureCreatorImpl();
     virtual ~SignatureCreatorImpl() override;
 
     /* XBlockerMonitor */
diff --git a/xmlsecurity/inc/framework/signatureengine.hxx b/xmlsecurity/inc/framework/signatureengine.hxx
index ee6c79a..3793016 100644
--- a/xmlsecurity/inc/framework/signatureengine.hxx
+++ b/xmlsecurity/inc/framework/signatureengine.hxx
@@ -54,9 +54,6 @@ class XSECFW_DLLPUBLIC SignatureEngine : public cppu::ImplInheritanceHelper
  *  Maintains common members and methods related with signature operation.
  ******************************************************************************/
 {
-private:
-    css::uno::Reference< css::uno::XComponentContext > m_xContext;
-
 protected:
 
     /*
@@ -86,7 +83,7 @@ protected:
     std::vector< css::uno::Reference< css::io::XInputStream > > m_vXInputStreams;
 
 protected:
-    explicit SignatureEngine( const css::uno::Reference< css::uno::XComponentContext > & xContext);
+    explicit SignatureEngine();
     virtual ~SignatureEngine() override {};
 
     virtual void tryToPerform( )
diff --git a/xmlsecurity/inc/framework/signatureverifierimpl.hxx b/xmlsecurity/inc/framework/signatureverifierimpl.hxx
index f31f7ac..70bbb41 100644
--- a/xmlsecurity/inc/framework/signatureverifierimpl.hxx
+++ b/xmlsecurity/inc/framework/signatureverifierimpl.hxx
@@ -61,8 +61,7 @@ private:
         throw (css::uno::Exception, css::uno::RuntimeException) override;
 
 public:
-    explicit SignatureVerifierImpl( const css::uno::Reference<
-        css::uno::XComponentContext >& rxContext);
+    explicit SignatureVerifierImpl();
     virtual ~SignatureVerifierImpl() override;
 
     /* XSignatureVerifyResultBroadcaster */
diff --git a/xmlsecurity/inc/pdfsignaturehelper.hxx b/xmlsecurity/inc/pdfsignaturehelper.hxx
index 7efdbfb..463961a 100644
--- a/xmlsecurity/inc/pdfsignaturehelper.hxx
+++ b/xmlsecurity/inc/pdfsignaturehelper.hxx
@@ -24,14 +24,13 @@
 /// Handles signatures of a PDF file.
 class XMLSECURITY_DLLPUBLIC PDFSignatureHelper
 {
-    css::uno::Reference<css::uno::XComponentContext> m_xComponentContext;
     SignatureInformations m_aSignatureInfos;
 
     css::uno::Reference<css::security::XCertificate> m_xCertificate;
     OUString m_aDescription;
 
 public:
-    PDFSignatureHelper(const css::uno::Reference<css::uno::XComponentContext>& xComponentContext);
+    PDFSignatureHelper();
     bool ReadAndVerifySignature(const css::uno::Reference<css::io::XInputStream>& xInputStream);
     css::uno::Sequence<css::security::DocumentSignatureInformation> GetDocumentSignatureInformations(const css::uno::Reference<css::xml::crypto::XSecurityEnvironment>& xSecEnv) const;
     SignatureInformations GetSignatureInformations() const;
diff --git a/xmlsecurity/inc/xsecctl.hxx b/xmlsecurity/inc/xsecctl.hxx
index 8e1fc1b..686d23d 100644
--- a/xmlsecurity/inc/xsecctl.hxx
+++ b/xmlsecurity/inc/xsecctl.hxx
@@ -255,12 +255,6 @@ private:
      */
     bool m_bVerifyCurrentSignature;
 
-    /*
-     * the type of signature to generate (from the css::xml::crypto::DigestID alternatives) when there is a choice,
-     * in practice currently SHA1 or SHA256 for ODF.
-     */
-    sal_Int32 m_nDigestID;
-
 public:
     /*
      * An xUriBinding is provided to map Uris to XInputStream interfaces.
diff --git a/xmlsecurity/source/framework/signaturecreatorimpl.cxx b/xmlsecurity/source/framework/signaturecreatorimpl.cxx
index e9269c2..3e289b9 100644
--- a/xmlsecurity/source/framework/signaturecreatorimpl.cxx
+++ b/xmlsecurity/source/framework/signaturecreatorimpl.cxx
@@ -34,8 +34,8 @@ namespace cssxw = com::sun::star::xml::wrapper;
 
 #define IMPLEMENTATION_NAME "com.sun.star.xml.security.framework.SignatureCreatorImpl"
 
-SignatureCreatorImpl::SignatureCreatorImpl( const Reference<XComponentContext> & xContext )
-    : SignatureCreatorImpl_Base(xContext), m_nIdOfBlocker(-1)
+SignatureCreatorImpl::SignatureCreatorImpl()
+    : SignatureCreatorImpl_Base(), m_nIdOfBlocker(-1)
 {
 }
 
@@ -200,10 +200,10 @@ cssu::Sequence< OUString > SAL_CALL SignatureCreatorImpl_getSupportedServiceName
 }
 
 cssu::Reference< cssu::XInterface > SAL_CALL SignatureCreatorImpl_createInstance(
-    const cssu::Reference< cssl::XMultiServiceFactory >& xMSF )
+    const cssu::Reference< cssl::XMultiServiceFactory >& /*xMSF*/ )
     throw( cssu::Exception )
 {
-    return static_cast<cppu::OWeakObject*>(new SignatureCreatorImpl( comphelper::getComponentContext( xMSF ) ));
+    return static_cast<cppu::OWeakObject*>(new SignatureCreatorImpl);
 }
 
 /* XServiceInfo */
diff --git a/xmlsecurity/source/framework/signatureengine.cxx b/xmlsecurity/source/framework/signatureengine.cxx
index 27dd705..b22d97c 100644
--- a/xmlsecurity/source/framework/signatureengine.cxx
+++ b/xmlsecurity/source/framework/signatureengine.cxx
@@ -29,8 +29,8 @@ namespace cssu = com::sun::star::uno;
 namespace cssxc = com::sun::star::xml::crypto;
 namespace cssxw = com::sun::star::xml::wrapper;
 
-SignatureEngine::SignatureEngine( const Reference<XComponentContext> & xContext)
-    : m_xContext(xContext), m_nTotalReferenceNumber(-1)
+SignatureEngine::SignatureEngine()
+    : m_nTotalReferenceNumber(-1)
 {
 }
 
diff --git a/xmlsecurity/source/framework/signatureverifierimpl.cxx b/xmlsecurity/source/framework/signatureverifierimpl.cxx
index bbbef86..b399af1 100644
--- a/xmlsecurity/source/framework/signatureverifierimpl.cxx
+++ b/xmlsecurity/source/framework/signatureverifierimpl.cxx
@@ -32,8 +32,8 @@ namespace cssxc = com::sun::star::xml::crypto;
 
 #define IMPLEMENTATION_NAME "com.sun.star.xml.security.framework.SignatureVerifierImpl"
 
-SignatureVerifierImpl::SignatureVerifierImpl( const cssu::Reference< css::uno::XComponentContext >& xContext)
-  : SignatureVerifierImpl_Base(xContext)
+SignatureVerifierImpl::SignatureVerifierImpl()
+  : SignatureVerifierImpl_Base()
 {
 }
 
@@ -153,10 +153,10 @@ cssu::Sequence< OUString > SAL_CALL SignatureVerifierImpl_getSupportedServiceNam
 }
 
 cssu::Reference< cssu::XInterface > SAL_CALL SignatureVerifierImpl_createInstance(
-    const cssu::Reference< cssl::XMultiServiceFactory >& rSMgr)
+    const cssu::Reference< cssl::XMultiServiceFactory >& /*rSMgr*/)
     throw( cssu::Exception )
 {
-    return static_cast<cppu::OWeakObject*>(new SignatureVerifierImpl( comphelper::getComponentContext(rSMgr) ));
+    return static_cast<cppu::OWeakObject*>(new SignatureVerifierImpl);
 }
 
 /* XServiceInfo */
diff --git a/xmlsecurity/source/helper/documentsignaturemanager.cxx b/xmlsecurity/source/helper/documentsignaturemanager.cxx
index 76e0b0a..7a26344 100644
--- a/xmlsecurity/source/helper/documentsignaturemanager.cxx
+++ b/xmlsecurity/source/helper/documentsignaturemanager.cxx
@@ -70,7 +70,7 @@ PDFSignatureHelper& DocumentSignatureManager::getPDFSignatureHelper()
     SAL_WARN_IF(!bInit, "xmlsecurity.comp", "Error initializing security context!");
 
     if (!mpPDFSignatureHelper)
-        mpPDFSignatureHelper.reset(new PDFSignatureHelper(mxContext));
+        mpPDFSignatureHelper.reset(new PDFSignatureHelper);
 
     return *mpPDFSignatureHelper;
 }
diff --git a/xmlsecurity/source/helper/pdfsignaturehelper.cxx b/xmlsecurity/source/helper/pdfsignaturehelper.cxx
index 4218a83..120bd3d 100644
--- a/xmlsecurity/source/helper/pdfsignaturehelper.cxx
+++ b/xmlsecurity/source/helper/pdfsignaturehelper.cxx
@@ -23,8 +23,7 @@
 
 using namespace ::com::sun::star;
 
-PDFSignatureHelper::PDFSignatureHelper(const uno::Reference<uno::XComponentContext>& xComponentContext)
-    : m_xComponentContext(xComponentContext)
+PDFSignatureHelper::PDFSignatureHelper()
 {
 }
 
diff --git a/xmlsecurity/source/helper/xsecctl.cxx b/xmlsecurity/source/helper/xsecctl.cxx
index ffd2f15..e27101b 100644
--- a/xmlsecurity/source/helper/xsecctl.cxx
+++ b/xmlsecurity/source/helper/xsecctl.cxx
@@ -58,7 +58,6 @@ XSecController::XSecController( const cssu::Reference<cssu::XComponentContext>&
     , m_bIsSAXEventKeeperSticky(false)
     , m_nReservedSignatureId(0)
     , m_bVerifyCurrentSignature(false)
-    , m_nDigestID(cssxc::DigestID::SHA1)
 {
 }
 
diff --git a/xmlsecurity/source/helper/xsecsign.cxx b/xmlsecurity/source/helper/xsecsign.cxx
index eabae47..f2db1bd 100644
--- a/xmlsecurity/source/helper/xsecsign.cxx
+++ b/xmlsecurity/source/helper/xsecsign.cxx
@@ -69,7 +69,7 @@ cssu::Reference< cssxc::sax::XReferenceResolvedListener > XSecController::prepar
 
     m_xSAXEventKeeper->setSecurityId(nIdOfSignatureElementCollector, nSecurityId);
 
-    uno::Reference<xml::crypto::sax::XReferenceResolvedListener> xReferenceResolvedListener(new SignatureCreatorImpl(mxCtx));
+    uno::Reference<xml::crypto::sax::XReferenceResolvedListener> xReferenceResolvedListener(new SignatureCreatorImpl);
 
     cssu::Reference<cssl::XInitialization> xInitialization(xReferenceResolvedListener, cssu::UNO_QUERY);
 
diff --git a/xmlsecurity/source/helper/xsecverify.cxx b/xmlsecurity/source/helper/xsecverify.cxx
index 8eb2273..d6ce85b 100644
--- a/xmlsecurity/source/helper/xsecverify.cxx
+++ b/xmlsecurity/source/helper/xsecverify.cxx
@@ -60,7 +60,7 @@ cssu::Reference< cssxc::sax::XReferenceResolvedListener > XSecController::prepar
          * create a SignatureVerifier
          */
     cssu::Reference< cssl::XMultiComponentFactory > xMCF( mxCtx->getServiceManager() );
-    xReferenceResolvedListener = new SignatureVerifierImpl(mxCtx);
+    xReferenceResolvedListener = new SignatureVerifierImpl;
 
     cssu::Reference<cssl::XInitialization> xInitialization(xReferenceResolvedListener, cssu::UNO_QUERY);
 


More information about the Libreoffice-commits mailing list