Kaydet (Commit) d5630adf authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:checkunusedparams in various

Change-Id: I4f54940a9ebdcd47776b2a5f7bae6e49b633ee44
Reviewed-on: https://gerrit.libreoffice.org/40706Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 70d0425d
......@@ -403,7 +403,8 @@ bool CheckUnusedParams::VisitFunctionDecl(FunctionDecl const * decl) {
return true;
// used in template magic
if (fqn == "MtfRenderer::MtfRenderer" || fqn == "shell::sessioninstall::SyncDbusSessionHelper::SyncDbusSessionHelper"
|| fqn == "dp_gui::LicenseDialog::LicenseDialog")
|| fqn == "dp_gui::LicenseDialog::LicenseDialog"
|| fqn == "(anonymous namespace)::OGLTransitionFactoryImpl::OGLTransitionFactoryImpl")
return true;
// FIXME
if (fqn == "GtkSalDisplay::filterGdkEvent" || fqn == "SvXMLEmbeddedObjectHelper::ImplReadObject"
......
......@@ -115,10 +115,8 @@ void RptMLMasterStylesContext_Impl::EndElement()
ErrCode ReadThroughComponent(
const uno::Reference<XInputStream>& xInputStream,
const uno::Reference<XComponent>& xModelComponent,
const sal_Char* /*pStreamName*/,
const uno::Reference<XComponentContext> & rContext,
const uno::Reference< XDocumentHandler >& _xFilter,
bool /*bEncrypted*/ )
const uno::Reference< XDocumentHandler >& _xFilter )
{
OSL_ENSURE(xInputStream.is(), "input stream missing");
OSL_ENSURE(xModelComponent.is(), "document missing");
......@@ -255,10 +253,8 @@ ErrCode ReadThroughComponent(
// read from the stream
return ReadThroughComponent( xInputStream
,xModelComponent
,pStreamName
,rxContext
,xDocHandler
,bEncrypted );
,xDocHandler );
}
// TODO/LATER: better error handling
......@@ -642,7 +638,7 @@ SvXMLImportContext* ORptFilter::CreateContext( sal_uInt16 nPrefix,
break;
case XML_TOK_DOC_META:
GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
pContext = CreateMetaContext( rLocalName,xAttrList );
pContext = CreateMetaContext( rLocalName );
break;
default:
break;
......@@ -983,7 +979,7 @@ void ORptFilter::insertFunction(const css::uno::Reference< css::report::XFunctio
m_aFunctions.insert(TGroupFunctionMap::value_type(_xFunction->getName(),_xFunction));
}
SvXMLImportContext* ORptFilter::CreateMetaContext(const OUString& rLocalName,const uno::Reference<xml::sax::XAttributeList>&)
SvXMLImportContext* ORptFilter::CreateMetaContext(const OUString& rLocalName)
{
SvXMLImportContext* pContext = nullptr;
......
......@@ -96,8 +96,7 @@ private:
SvXMLImportContext* CreateStylesContext(const OUString& rLocalName,
const Reference< XAttributeList>& xAttrList, bool bIsAutoStyle );
SvXMLImportContext* CreateMetaContext(const OUString& rLocalName,
const css::uno::Reference< css::xml::sax::XAttributeList > & xAttrList );
SvXMLImportContext* CreateMetaContext(const OUString& rLocalName);
SvXMLImportContext* CreateFontDeclsContext(const OUString& rLocalName,
const css::uno::Reference< css::xml::sax::XAttributeList > & xAttrList );
protected:
......
......@@ -989,7 +989,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
case css::presentation::EffectNodeType::TIMING_ROOT : nPPTNodeType = DFF_ANIM_NODE_TYPE_TIMING_ROOT; break;
case css::presentation::EffectNodeType::INTERACTIVE_SEQUENCE: nPPTNodeType = DFF_ANIM_NODE_TYPE_INTERACTIVE_SEQ; break;
}
exportAnimPropertyuInt32( rStrm, DFF_ANIM_NODE_TYPE, nPPTNodeType, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_NODE_TYPE, nPPTNodeType );
}
}
sal_uInt32 nPresetId = 0;
......@@ -1036,11 +1036,11 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
}
}
if ( bPresetId )
exportAnimPropertyuInt32( rStrm, DFF_ANIM_PRESET_ID, nPresetId, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_PRESET_ID, nPresetId );
if ( bPresetSubType )
exportAnimPropertyuInt32( rStrm, DFF_ANIM_PRESET_SUB_TYPE, nPresetSubType, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_PRESET_SUB_TYPE, nPresetSubType );
if ( bPresetClass )
exportAnimPropertyuInt32( rStrm, DFF_ANIM_PRESET_CLASS, nPresetClass, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_PRESET_CLASS, nPresetClass );
if ( pAny[ DFF_ANIM_ID ] )
{
......@@ -1058,7 +1058,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
{
sal_Int32 nRunTimeContext = 0;
if ( *pAny[ DFF_ANIM_RUNTIMECONTEXT ] >>= nRunTimeContext )
exportAnimPropertyuInt32( rStrm, DFF_ANIM_RUNTIMECONTEXT, nRunTimeContext, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_RUNTIMECONTEXT, nRunTimeContext );
}
if ( pAny[ DFF_ANIM_PATH_EDIT_MODE ] )
{
......@@ -1072,7 +1072,7 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
{
bool bDirection = !xColor->getDirection();
exportAnimPropertyuInt32( rStrm, DFF_ANIM_DIRECTION, bDirection ? 1 : 0, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_DIRECTION, bDirection ? 1 : 0 );
}
}
......@@ -1080,14 +1080,14 @@ sal_Int16 AnimationExporter::exportAnimPropertySet( SvStream& rStrm, const Refer
{
sal_Int32 nOverride = 0;
if ( *pAny[ DFF_ANIM_OVERRIDE ] >>= nOverride )
exportAnimPropertyuInt32( rStrm, DFF_ANIM_OVERRIDE, nOverride, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_OVERRIDE, nOverride );
}
if ( pAny[ DFF_ANIM_MASTERREL ] )
{
sal_Int32 nMasterRel = 0;
if ( *pAny[ DFF_ANIM_MASTERREL ] >>= nMasterRel )
exportAnimPropertyuInt32( rStrm, DFF_ANIM_MASTERREL, nMasterRel, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, DFF_ANIM_MASTERREL, nMasterRel );
}
/* todo
......@@ -1130,7 +1130,7 @@ bool AnimationExporter::exportAnimProperty( SvStream& rStrm, const sal_uInt16 nP
sal_Int32 nVal = 0;
if ( rAny >>= nVal )
{
exportAnimPropertyuInt32( rStrm, nPropertyId, nVal, eTranslateMode );
exportAnimPropertyuInt32( rStrm, nPropertyId, nVal );
bRet = true;
}
}
......@@ -1198,7 +1198,7 @@ void AnimationExporter::exportAnimPropertyFloat( SvStream& rStrm, const sal_uInt
.WriteFloat( fFloat );
}
void AnimationExporter::exportAnimPropertyuInt32( SvStream& rStrm, const sal_uInt16 nPropertyId, const sal_uInt32 nVal, const TranslateMode )
void AnimationExporter::exportAnimPropertyuInt32( SvStream& rStrm, const sal_uInt16 nPropertyId, const sal_uInt32 nVal )
{
EscherExAtom aExAtom( rStrm, DFF_msofbtAnimAttributeValue, nPropertyId );
rStrm.WriteUChar( DFF_ANIM_PROP_TYPE_INT32 )
......@@ -1690,11 +1690,11 @@ void AnimationExporter::exportAnimateTarget( SvStream& rStrm, const Reference< X
if( nAfterEffectType != AFTEREFFECT_NONE )
{
EscherExContainer aAnimPropertySet( rStrm, DFF_msofbtAnimPropertySet );
exportAnimPropertyuInt32( rStrm, 6, 1, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, 6, 1 );
if( nAfterEffectType == AFTEREFFECT_COLOR )
{
exportAnimPropertyuInt32( rStrm, 4, 0, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, 5, 0, TRANSLATE_NONE );
exportAnimPropertyuInt32( rStrm, 4, 0 );
exportAnimPropertyuInt32( rStrm, 5, 0 );
}
}
exportAnimateTargetElement( rStrm, aTarget.hasValue() ? aTarget : xAnimate->getTarget(), false );
......
......@@ -72,7 +72,7 @@ class AnimationExporter
static bool exportAnimProperty( SvStream& rStrm, const sal_uInt16 nPropertyId, const css::uno::Any& rAny, const TranslateMode eTranslateMode );
static void exportAnimPropertyString( SvStream& rStrm, const sal_uInt16 nPropertyId, const OUString& rVal, const TranslateMode eTranslateMode );
static void exportAnimPropertyFloat( SvStream& rStrm, const sal_uInt16 nPropertyId, const double& rVal );
static void exportAnimPropertyuInt32( SvStream& rStrm, const sal_uInt16 nPropertyId, const sal_uInt32 nVal, const TranslateMode eTranslateMode );
static void exportAnimPropertyuInt32( SvStream& rStrm, const sal_uInt16 nPropertyId, const sal_uInt32 nVal );
static void exportAnimPropertyByte( SvStream& rStrm, const sal_uInt16 nPropertyId, const sal_uInt8 nVal );
/** if available exportAnimPropertySet
......
......@@ -132,7 +132,6 @@ void SAL_CALL ResourceManager::notifyConfigurationChange (
// resource managed by this ResourceManager accordingly.
HandleMainViewSwitch(
rEvent.ResourceId->getResourceURL(),
rEvent.Configuration,
true);
}
}
......@@ -150,7 +149,6 @@ void SAL_CALL ResourceManager::notifyConfigurationChange (
{
HandleMainViewSwitch(
OUString(),
rEvent.Configuration,
false);
}
else if (rEvent.ResourceId->compareTo(mxResourceId) == 0)
......@@ -166,7 +164,6 @@ void SAL_CALL ResourceManager::notifyConfigurationChange (
void ResourceManager::HandleMainViewSwitch (
const OUString& rsViewURL,
const Reference<XConfiguration>& /*rxConfiguration*/,
const bool bIsActivated)
{
if (bIsActivated)
......
......@@ -86,7 +86,6 @@ private:
void HandleMainViewSwitch (
const OUString& rsViewURL,
const css::uno::Reference<css::drawing::framework::XConfiguration>& rxConfiguration,
const bool bIsActivated);
void HandleResourceRequest(
bool bActivation,
......
......@@ -49,8 +49,7 @@ static Reference<lang::XEventListener> mxControllerDisposeListener;
//----- PanelFactory --------------------------------------------------------
PanelFactory::PanelFactory(
const css::uno::Reference<css::uno::XComponentContext>& /*rxContext*/)
PanelFactory::PanelFactory()
: PanelFactoryInterfaceBase(m_aMutex)
{
}
......@@ -144,10 +143,10 @@ Reference<ui::XUIElement> SAL_CALL PanelFactory::createUIElement (
extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* SAL_CALL
org_openoffice_comp_Draw_framework_PanelFactory_get_implementation(css::uno::XComponentContext* context,
org_openoffice_comp_Draw_framework_PanelFactory_get_implementation(css::uno::XComponentContext* /*context*/,
css::uno::Sequence<css::uno::Any> const &)
{
return cppu::acquire(new sd::sidebar::PanelFactory(context));
return cppu::acquire(new sd::sidebar::PanelFactory);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
......@@ -46,7 +46,7 @@ class PanelFactory
public PanelFactoryInterfaceBase
{
public:
explicit PanelFactory (const css::uno::Reference<css::uno::XComponentContext>& rxContext);
explicit PanelFactory ();
virtual ~PanelFactory() override;
PanelFactory(const PanelFactory&) = delete;
PanelFactory& operator=(const PanelFactory&) = delete;
......
......@@ -223,7 +223,6 @@ class PresenterTheme::Theme
{
public:
Theme (
const OUString& rsName,
const Reference<container::XHierarchicalNameAccess>& rThemeRoot,
const OUString& rsNodeName);
......@@ -572,7 +571,6 @@ double PresenterTheme::FontDescriptor::GetCellSizeForDesignSize (
//===== Theme =================================================================
PresenterTheme::Theme::Theme (
const OUString& /*rsName*/,
const Reference<container::XHierarchicalNameAccess>& rxThemeRoot,
const OUString& rsNodeName)
: msConfigurationNodeName(rsNodeName),
......@@ -785,7 +783,7 @@ std::shared_ptr<PresenterTheme::Theme> ReadContext::ReadTheme (
>>= sThemeName;
if (sThemeName == sCurrentThemeName)
{
pTheme.reset(new PresenterTheme::Theme(sThemeName,xTheme,rsKey));
pTheme.reset(new PresenterTheme::Theme(xTheme,rsKey));
break;
}
}
......
......@@ -99,129 +99,67 @@ public:
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList) override;
SvXMLImportContext *CreateRowContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateEncloseContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateFracContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateNumberContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateTextContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateAnnotationContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateStringContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateIdentifierContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateOperatorContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateSpaceContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateSqrtContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateRootContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateStyleContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreatePaddedContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreatePhantomContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateFencedContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateErrorContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateSubContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateSupContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateSubSupContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateUnderContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateOverContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateUnderOverContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateMultiScriptsContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateNoneContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreatePrescriptsContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateTableContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateTableRowContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateTableCellContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateAlignGroupContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
SvXMLImportContext *CreateActionContext(sal_uInt16 nPrefix,
const OUString &rLocalName,
const css::uno::Reference <
css::xml::sax::XAttributeList> &xAttrList);
const OUString &rLocalName);
const SvXMLTokenMap &GetPresLayoutElemTokenMap();
const SvXMLTokenMap &GetPresLayoutAttrTokenMap();
......
......@@ -226,8 +226,7 @@ private:
cairo_t *cr,
const tools::Rectangle& rControlRectangle,
ControlType nType,
ControlPart nPart,
const ImplControlValue& aValue);
ControlPart nPart);
static void PaintCheckOrRadio(cairo_t *cr, GtkStyleContext *context,
const tools::Rectangle& rControlRectangle,
bool bIsCheck, bool bInMenu);
......@@ -303,7 +302,6 @@ protected:
const std::list< tools::Rectangle >& aClip,
ControlState nState,
const ImplControlValue& aValue,
const OUString& rCaption,
ControlCacheKey& rControlCacheKey);
bool NWPaintGTKArrow( GdkDrawable* gdkDrawable,
......@@ -342,21 +340,18 @@ protected:
bool NWPaintGTKScrollbar( ControlPart nPart,
const tools::Rectangle& rControlRectangle,
ControlState nState, const ImplControlValue& aValue );
bool NWPaintGTKEditBox( GdkDrawable* gdkDrawable, ControlType nType, ControlPart nPart,
bool NWPaintGTKEditBox( GdkDrawable* gdkDrawable, ControlType nType,
const tools::Rectangle& rControlRectangle,
const std::list< tools::Rectangle >& rClipList,
ControlState nState, const ImplControlValue& aValue,
const OUString& rCaption );
ControlState nState );
bool NWPaintGTKSpinBox(ControlType nType, ControlPart nPart,
const tools::Rectangle& rControlRectangle,
ControlState nState, const ImplControlValue& aValue,
const OUString& rCaption,
ControlCacheKey& rControlCacheKey);
bool NWPaintGTKComboBox( GdkDrawable* gdkDrawable, ControlType nType, ControlPart nPart,
const tools::Rectangle& rControlRectangle,
const std::list< tools::Rectangle >& rClipList,
ControlState nState, const ImplControlValue& aValue,
const OUString& rCaption );
ControlState nState );
bool NWPaintGTKTabItem( ControlType nType,
const tools::Rectangle& rControlRectangle,
ControlState nState, const ImplControlValue& aValue );
......
......@@ -1197,8 +1197,7 @@ tools::Rectangle GtkSalGraphics::NWGetComboBoxButtonRect(
void GtkSalGraphics::PaintCombobox( GtkStateFlags flags, cairo_t *cr,
const tools::Rectangle& rControlRectangle,
ControlType nType,
ControlPart nPart,
const ImplControlValue& /*rValue*/ )
ControlPart nPart )
{
tools::Rectangle areaRect;
tools::Rectangle buttonRect;
......@@ -2487,7 +2486,7 @@ bool GtkSalGraphics::drawNativeControl( ControlType nType, ControlPart nPart, co
PaintSpinButton(flags, cr, rControlRegion, nPart, rValue);
break;
case RenderType::Combobox:
PaintCombobox(flags, cr, rControlRegion, nType, nPart, rValue);
PaintCombobox(flags, cr, rControlRegion, nType, nPart);
break;
case RenderType::Icon:
gtk_render_icon(context, cr, pixbuf, nX, nY);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment