Permalink
Browse files

loplugin:unusedfields

Change-Id: I96634c18ba6600f8f7d5d04a162dcd7e1e312923
Reviewed-on: https://gerrit.libreoffice.org/30474
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
  • Loading branch information...
1 parent 2db81e7 commit 3fea7ac94b986ba5e3632d1bbb383c65ced79f1a Noel Grandin committed Nov 2, 2016
@@ -52,7 +52,7 @@ def normalizeTypeParams( line ):
if len(definitions) > 1:
for d in definitions:
definitionSet.remove(d)
-
+
untouchedSet = set()
for d in definitionSet:
if d in callSet:
@@ -87,15 +87,15 @@ def normalizeTypeParams( line ):
or srcLoc.startswith("lotuswordpro/source/filter/lwpsdwdrawheader.hxx")
or srcLoc.startswith("hwpfilter/")
or srcLoc.startswith("embeddedobj/source/inc/")
- or srcLoc.startswith("svtools/source/dialogs/insdlg.cxx")):
+ or srcLoc.startswith("svtools/source/dialogs/insdlg.cxx")
or srcLoc.startswith("bridges/")):
continue
if d[0] in set([ "AtkObjectWrapperClass", "AtkObjectWrapper", "GLOMenu", "GLOAction", "_XRegion", "SalMenuButtonItem", "Vertex",
"OOoMountOperationClass", "SwCSS1ItemIds", "ScCompiler::AddInMap", "MemoryByteGrabber", "textcat_t", "fp_t", "ngram_t",
"ImplPPTParaPropSet", "DataNode"]):
continue
# unit testing code
- if (srcLoc.startswith("cppu/source/uno/check.cxx"):
+ if srcLoc.startswith("cppu/source/uno/check.cxx"):
continue
fieldType = definitionToTypeMap[d]
if fieldType in set([ "class rptui::OModuleClient" ]):
@@ -119,12 +119,6 @@ namespace dbaccess
m_pData->xHandler->characters( i_rCharacters );
}
- // StorageXMLInputStream_Data
- struct StorageXMLInputStream_Data
- {
- Reference< XParser > xParser;
- };
-
// StorageXMLInputStream
StorageXMLInputStream::StorageXMLInputStream( const Reference<XComponentContext>& i_rContext,
const Reference< XStorage >& i_rParentStorage,
@@ -55,12 +55,6 @@ protected:
using SequenceRecordObjectBase::construct;
virtual bool implReadRecordHeader( BinaryInputStream& rBaseStrm, sal_Int64& ornRecId, sal_Int64& ornRecSize ) override;
-
-private:
- typedef std::shared_ptr< SequenceInputStream > SequenceInputStreamRef;
-
- SequenceInputStreamRef mxBiffStrm;
- NameListRef mxErrCodes;
};
View
@@ -223,7 +223,6 @@ public:
class SAL_WARN_UNUSED SVX_DLLPUBLIC HatchingLB : public ListBox
{
- XHatchListRef mpList;
public:
explicit HatchingLB(vcl::Window* pParent, WinBits aWB);
};
@@ -232,7 +231,6 @@ public:
class SAL_WARN_UNUSED SVX_DLLPUBLIC GradientLB : public ListBox
{
- XGradientListRef mpList;
public:
explicit GradientLB(vcl::Window* pParent, WinBits aWB);
};
@@ -243,11 +241,6 @@ class SAL_WARN_UNUSED SVX_DLLPUBLIC BitmapLB : public ListBox
{
public:
explicit BitmapLB(vcl::Window* pParent, WinBits aWB);
-
-private:
- BitmapEx maBitmapEx;
-
- XBitmapListRef mpList;
};
/************************************************************************/
View
@@ -158,7 +158,6 @@ class SAL_WARN_UNUSED SVX_DLLPUBLIC FmSearchEngine
// the formatter
css::uno::Reference< css::util::XNumberFormatsSupplier > m_xFormatSupplier;
- css::uno::Reference< css::util::XNumberFormatter > m_xFormatter;
CharClass m_aCharacterClassficator;
CollatorWrapper m_aStringCompare;
View
@@ -79,11 +79,9 @@ class SVX_DLLPUBLIC BulletsSettings
public:
bool bIsCustomized;
rtl::OUString sDescription;
- NBType eType;
public:
- BulletsSettings(NBType eTy) :
- bIsCustomized(false),
- eType(eTy)
+ BulletsSettings() :
+ bIsCustomized(false)
{}
virtual ~BulletsSettings(){}
};
@@ -95,9 +93,8 @@ class SVX_DLLPUBLIC BulletsSettings_Impl:public BulletsSettings
vcl::Font aFont;
public:
- BulletsSettings_Impl(NBType eTy)
- : BulletsSettings(eTy)
- , cBulletChar(0)
+ BulletsSettings_Impl()
+ : cBulletChar(0)
{}
virtual ~BulletsSettings_Impl() override {}
};
@@ -154,8 +154,6 @@ protected:
std::unique_ptr< XFillFloatTransparenceItem > mpFloatTransparenceItem;
std::unique_ptr< SfxUInt16Item > mpTransparanceItem;
- css::uno::Reference<css::frame::XFrame> mxFrame;
-
DECL_LINK(SelectFillTypeHdl, ListBox&, void );
DECL_LINK(SelectFillAttrHdl, ListBox&, void );
DECL_LINK(ChangeGradientAngle, Edit&, void);
View
@@ -334,13 +334,6 @@ int macxp_resolveAlias(char *path, int buflen);
# define SA_FAMILY_DECL short sa_family
#endif
-typedef struct sockaddr_ipx {
- SA_FAMILY_DECL;
- char sa_netnum[4];
- char sa_nodenum[6];
- unsigned short sa_socket;
-} SOCKADDR_IPX;
-
#define NSPROTO_IPX 1000
#define NSPROTO_SPX 1256
#define NSPROTO_SPXII 1257
View
@@ -81,13 +81,6 @@
# define SA_FAMILY_DECL short sa_family
# endif
- typedef struct sockaddr_ipx {
- SA_FAMILY_DECL;
- char sa_netnum[4];
- char sa_nodenum[6];
- unsigned short sa_socket;
- } SOCKADDR_IPX;
-
# define NSPROTO_IPX 1000
# define NSPROTO_SPX 1256
# define NSPROTO_SPXII 1257
@@ -32,13 +32,6 @@ using namespace ::sd;
struct FadeEffectLBImpl
{
- // The set id of each entry
- std::vector< OUString > maSet;
-
- // How many variants each transition set has
- std::map< OUString, int > maNumVariants;
-
- std::vector< TransitionPresetPtr > maPresets;
};
FadeEffectLB::FadeEffectLB(vcl::Window* pParent, WinBits nStyle)
@@ -24,7 +24,7 @@ class SafeModeUI : public ::cppu::WeakImplHelper< css::lang::XServiceInfo,
css::frame::XSynchronousDispatch > // => XDispatch!
{
public:
- explicit SafeModeUI(const css::uno::Reference< css::uno::XComponentContext >& xContext);
+ SafeModeUI();
virtual ~SafeModeUI() override;
// css.lang.XServiceInfo
@@ -41,15 +41,10 @@ class SafeModeUI : public ::cppu::WeakImplHelper< css::lang::XServiceInfo,
virtual css::uno::Any SAL_CALL dispatchWithReturnValue(const css::util::URL& aURL,
const css::uno::Sequence< css::beans::PropertyValue >& lArguments )
throw(css::uno::RuntimeException, std::exception) override;
-
-private:
- css::uno::Reference< css::uno::XComponentContext > mxContext;
};
-SafeModeUI::SafeModeUI(const css::uno::Reference<css::uno::XComponentContext>& xContext):
- mxContext(xContext)
+SafeModeUI::SafeModeUI()
{
-
}
SafeModeUI::~SafeModeUI()
@@ -90,10 +85,10 @@ css::uno::Any SAL_CALL SafeModeUI::dispatchWithReturnValue(const css::util::URL&
extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface * SAL_CALL
com_sun_star_comp_svx_SafeModeUI_get_implementation(
- css::uno::XComponentContext *context,
+ css::uno::XComponentContext * /*context*/,
css::uno::Sequence<css::uno::Any> const &)
{
- return cppu::acquire(new SafeModeUI(context));
+ return cppu::acquire(new SafeModeUI);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
@@ -1152,8 +1152,7 @@ void ColorLB::Modify( const XColorEntry& rEntry, sal_Int32 nPos )
// Fills the listbox (provisional) with strings
HatchingLB::HatchingLB( vcl::Window* pParent, WinBits nWinStyle)
-: ListBox( pParent, nWinStyle ),
- mpList ( nullptr )
+: ListBox( pParent, nWinStyle )
{
SetEdgeBlending(true);
}
@@ -1193,8 +1192,7 @@ void FillAttrLB::Fill( const XHatchListRef &pList )
// Fills the listbox (provisional) with strings
GradientLB::GradientLB( vcl::Window* pParent, WinBits aWB)
-: ListBox( pParent, aWB ),
- mpList(nullptr)
+: ListBox( pParent, aWB )
{
SetEdgeBlending(true);
}
@@ -1234,9 +1232,7 @@ void FillAttrLB::Fill( const XGradientListRef &pList )
// BitmapLB Constructor
BitmapLB::BitmapLB( vcl::Window* pParent, WinBits aWB)
-: ListBox( pParent, aWB ),
- maBitmapEx(),
- mpList(nullptr)
+: ListBox( pParent, aWB )
{
SetEdgeBlending(true);
}
@@ -92,8 +92,7 @@ AreaPropertyPanelBase::AreaPropertyPanelBase(
maImgSquare(SVX_RES(IMG_SQUARE)),
maImgLinear(SVX_RES(IMG_LINEAR)),
mpFloatTransparenceItem(),
- mpTransparanceItem(),
- mxFrame(rxFrame)
+ mpTransparanceItem()
{
get(mpColorTextFT, "filllabel");
get(mpLbFillType, "fillstyle");
@@ -260,7 +260,7 @@ void BulletsTypeMgr::Init()
for (sal_uInt16 i=0;i<DEFAULT_BULLET_TYPES;i++)
{
- pActualBullets[i] = new BulletsSettings_Impl(NBType::Bullets);
+ pActualBullets[i] = new BulletsSettings_Impl;
pActualBullets[i]->cBulletChar = aDefaultBulletTypes[i];
pActualBullets[i]->aFont =rActBulletFont;
pActualBullets[i]->sDescription = SVX_RESSTR( RID_SVXSTR_BULLET_DESCRIPTION_0 + i );
@@ -136,9 +136,6 @@ class SvxXMLBitmapEntryExporter : public SvxXMLTableEntryExporter
virtual ~SvxXMLBitmapEntryExporter() override;
virtual void exportEntry( const OUString& rStrName, const Any& rValue ) override;
-
-private:
- XMLImageStyle maImageStyle;
};
@@ -41,7 +41,6 @@ struct JPEGCreateBitmapParam
unsigned long Y_density;
bool bGray;
- bool bTopDown; // CreateBitmap method in svtools
};
class JPEGReader : public GraphicReader

0 comments on commit 3fea7ac

Please sign in to comment.