Kaydet (Commit) 24ada656 authored tarafından Noel Grandin's avatar Noel Grandin Kaydeden (comit) Noel Grandin

loplugin:unusedmethods unused return value in include/unotools

Change-Id: I3b2281dc713bff92eb3d80fddef04a8a39838aa8
Reviewed-on: https://gerrit.libreoffice.org/21484Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
üst cdaee607
......@@ -51,7 +51,7 @@ class UNOTOOLS_DLLPUBLIC CollatorWrapper
loadDefaultCollator (
const css::lang::Locale& rLocale, sal_Int32 nOption);
sal_Int32
void
loadCollatorAlgorithm (
const OUString& rAlgorithm,
const css::lang::Locale& rLocale, sal_Int32 nOption);
......
......@@ -193,7 +193,7 @@ class SAL_WARN_UNUSED UNOTOOLS_DLLPUBLIC SvtSecurityOptions : public utl::detail
// for bool options only!
bool IsOptionSet ( EOption eOption ) const;
bool SetOption ( EOption eOption, bool bValue );
void SetOption ( EOption eOption, bool bValue );
bool IsOptionEnabled ( EOption eOption ) const;
// xmlsec05 deprecated methods
......
......@@ -150,13 +150,9 @@ class SAL_WARN_UNUSED UNOTOOLS_DLLPUBLIC SvtViewOptions : public utl::detail::Op
your view will die relay in configuration...
@seealso method Exist()
@return True if delete OK, False otherwise.
@onerror We return sal_False.
*//*-*****************************************************************************************************/
bool Delete();
void Delete();
/*-****************************************************************************************************
@short use it to set/get the window state of your view
......
......@@ -1079,10 +1079,10 @@ bool SvtSecurityOptions::IsOptionSet( EOption eOption ) const
return m_pDataContainer->IsOptionSet( eOption );
}
bool SvtSecurityOptions::SetOption( EOption eOption, bool bValue )
void SvtSecurityOptions::SetOption( EOption eOption, bool bValue )
{
MutexGuard aGuard( GetInitMutex() );
return m_pDataContainer->SetOption( eOption, bValue );
m_pDataContainer->SetOption( eOption, bValue );
}
bool SvtSecurityOptions::IsOptionEnabled( EOption eOption ) const
......
......@@ -726,32 +726,22 @@ bool SvtViewOptions::Exists() const
// public method
bool SvtViewOptions::Delete()
void SvtViewOptions::Delete()
{
// Ready for multithreading
::osl::MutexGuard aGuard( GetOwnStaticMutex() );
bool bState = false;
switch( m_eViewType )
{
case E_DIALOG : {
bState = m_pDataContainer_Dialogs->Delete( m_sViewName );
}
break;
case E_TABDIALOG : {
bState = m_pDataContainer_TabDialogs->Delete( m_sViewName );
}
break;
case E_TABPAGE : {
bState = m_pDataContainer_TabPages->Delete( m_sViewName );
}
break;
case E_WINDOW : {
bState = m_pDataContainer_Windows->Delete( m_sViewName );
}
break;
case E_DIALOG : m_pDataContainer_Dialogs->Delete( m_sViewName );
break;
case E_TABDIALOG : m_pDataContainer_TabDialogs->Delete( m_sViewName );
break;
case E_TABPAGE : m_pDataContainer_TabPages->Delete( m_sViewName );
break;
case E_WINDOW : m_pDataContainer_Windows->Delete( m_sViewName );
break;
}
return bState;
}
// public method
......
......@@ -82,23 +82,20 @@ CollatorWrapper::loadDefaultCollator (const lang::Locale& rLocale, sal_Int32 nOp
return 0;
}
sal_Int32
void
CollatorWrapper::loadCollatorAlgorithm (const OUString& rAlgorithm,
const lang::Locale& rLocale, sal_Int32 nOptions)
{
try
{
if (mxInternationalCollator.is())
return mxInternationalCollator->loadCollatorAlgorithm (
mxInternationalCollator->loadCollatorAlgorithm (
rAlgorithm, rLocale, nOptions);
}
catch (const uno::RuntimeException&)
{
SAL_WARN( "unotools.i18n","CollatorWrapper: loadCollatorAlgorithm failed");
}
return 0;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
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