summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-02-08 13:54:53 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-02-09 21:04:42 +0100
commit45f4de6d333aa3fa5873cf8e1146286c74960557 (patch)
tree463a497d6132e44d82294772be4aa3f487ad13e7
parent34f333445c54c87f3afe777fa467f7a2bb122208 (diff)
loplugin:indentation in sfx2..slideshow
Change-Id: I3bd23a8f6237d0887a4782b6179a413dd2f03e02 Reviewed-on: https://gerrit.libreoffice.org/67564 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--sfx2/source/appl/app.cxx2
-rw-r--r--sfx2/source/appl/appuno.cxx6
-rw-r--r--sfx2/source/appl/helpinterceptor.cxx2
-rw-r--r--sfx2/source/appl/newhelp.cxx2
-rw-r--r--sfx2/source/appl/sfxhelp.cxx8
-rw-r--r--sfx2/source/appl/shutdownicon.cxx2
-rw-r--r--sfx2/source/dialog/filedlghelper.cxx23
-rw-r--r--sfx2/source/dialog/printopt.cxx2
-rw-r--r--sfx2/source/dialog/templdlg.cxx30
-rw-r--r--sfx2/source/doc/doctemplates.cxx12
-rw-r--r--sfx2/source/doc/guisaveas.cxx10
-rw-r--r--sfx2/source/doc/sfxbasemodel.cxx2
-rw-r--r--sfx2/source/sidebar/SidebarController.cxx2
-rw-r--r--sfx2/source/view/sfxbasecontroller.cxx2
-rw-r--r--shell/source/cmdmail/cmdmailmsg.cxx2
-rw-r--r--slideshow/source/engine/opengl/TransitionImpl.cxx18
-rw-r--r--slideshow/source/engine/shapes/shapeimporter.cxx2
-rw-r--r--slideshow/source/engine/slide/targetpropertiescreator.cxx2
-rw-r--r--slideshow/source/engine/slide/userpaintoverlay.cxx4
-rw-r--r--slideshow/source/inc/tools.hxx2
20 files changed, 68 insertions, 67 deletions
diff --git a/sfx2/source/appl/app.cxx b/sfx2/source/appl/app.cxx
index 6ff4e5c5cea6..ff66aad976c2 100644
--- a/sfx2/source/appl/app.cxx
+++ b/sfx2/source/appl/app.cxx
@@ -507,7 +507,7 @@ SfxApplication::ChooseScript()
SAL_INFO( "sfx.appl", "done, now exec it");
- sal_uInt16 nRet = pDlg->Execute();
+ sal_uInt16 nRet = pDlg->Execute();
SAL_INFO( "sfx.appl", "has returned");
diff --git a/sfx2/source/appl/appuno.cxx b/sfx2/source/appl/appuno.cxx
index 0de7be3c144c..2fef73c3df21 100644
--- a/sfx2/source/appl/appuno.cxx
+++ b/sfx2/source/appl/appuno.cxx
@@ -1223,11 +1223,11 @@ void TransformItems( sal_uInt16 nSlotId, const SfxItemSet& rSet, uno::Sequence<b
continue;
if ( nId == SID_SAVEACOPYITEM )
continue;
- if ( nId == SID_MODIFYPASSWORDINFO )
+ if ( nId == SID_MODIFYPASSWORDINFO )
continue;
- if ( nId == SID_SUGGESTEDSAVEASDIR )
+ if ( nId == SID_SUGGESTEDSAVEASDIR )
continue;
- if ( nId == SID_SUGGESTEDSAVEASNAME )
+ if ( nId == SID_SUGGESTEDSAVEASNAME )
continue;
}
diff --git a/sfx2/source/appl/helpinterceptor.cxx b/sfx2/source/appl/helpinterceptor.cxx
index 7b8c1f98ddb2..8c782108857a 100644
--- a/sfx2/source/appl/helpinterceptor.cxx
+++ b/sfx2/source/appl/helpinterceptor.cxx
@@ -51,7 +51,7 @@ HelpInterceptor_Impl::~HelpInterceptor_Impl()
void HelpInterceptor_Impl::addURL( const OUString& rURL )
{
- if ( !m_pHistory )
+ if ( !m_pHistory )
m_pHistory.reset( new std::vector<std::unique_ptr<HelpHistoryEntry_Impl>> );
size_t nCount = m_pHistory->size();
diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx
index 45cfaeeb9937..0035877b1bff 100644
--- a/sfx2/source/appl/newhelp.cxx
+++ b/sfx2/source/appl/newhelp.cxx
@@ -2698,7 +2698,7 @@ void SfxHelpWindow_Impl::InitSizes()
void SfxHelpWindow_Impl::LoadConfig()
{
- SvtViewOptions aViewOpt( EViewType::Window, CONFIGNAME_HELPWIN );
+ SvtViewOptions aViewOpt( EViewType::Window, CONFIGNAME_HELPWIN );
if ( !aViewOpt.Exists() )
return;
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx
index 0510d7f537a2..ce484741909d 100644
--- a/sfx2/source/appl/sfxhelp.cxx
+++ b/sfx2/source/appl/sfxhelp.cxx
@@ -844,7 +844,7 @@ bool rewriteFlatpakHelpRootUrl(OUString * helpRootUrl) {
"sfx.appl",
"LIBO_FLATPAK mode /.flatpak-info [Instance] app-path \"" << path
<< "\" doesn't contain /app/org.libreoffice.LibreOffice/");
- throw Failure();
+ throw Failure();
}
auto const i2 = i1 + segments.size;
auto i3 = path.indexOf('/', i2);
@@ -853,7 +853,7 @@ bool rewriteFlatpakHelpRootUrl(OUString * helpRootUrl) {
"sfx.appl",
"LIBO_FLATPAK mode /.flatpak-info [Instance] app-path \"" << path
<< "\" doesn't contain branch segment");
- throw Failure();
+ throw Failure();
}
i3 = path.indexOf('/', i3 + 1);
if (i3 == -1) {
@@ -861,7 +861,7 @@ bool rewriteFlatpakHelpRootUrl(OUString * helpRootUrl) {
"sfx.appl",
"LIBO_FLATPAK mode /.flatpak-info [Instance] app-path \"" << path
<< "\" doesn't contain sha segment");
- throw Failure();
+ throw Failure();
}
++i3;
auto const i4 = path.indexOf('/', i3);
@@ -870,7 +870,7 @@ bool rewriteFlatpakHelpRootUrl(OUString * helpRootUrl) {
"sfx.appl",
"LIBO_FLATPAK mode /.flatpak-info [Instance] app-path \"" << path
<< "\" doesn't contain files segment");
- throw Failure();
+ throw Failure();
}
path = path.copy(0, i1) + "/runtime/org.libreoffice.LibreOffice.Help/"
+ path.copy(i2, i3 - i2) + sha + path.copy(i4);
diff --git a/sfx2/source/appl/shutdownicon.cxx b/sfx2/source/appl/shutdownicon.cxx
index a05579fbdd89..da830474037a 100644
--- a/sfx2/source/appl/shutdownicon.cxx
+++ b/sfx2/source/appl/shutdownicon.cxx
@@ -716,7 +716,7 @@ css::uno::Any SAL_CALL ShutdownIcon::getFastPropertyValue( ::sal_Int32 nHandle )
case PROPHANDLE_TERMINATEVETOSTATE :
{
bool bState = (m_bListenForTermination && m_bVeto);
- aValue <<= bState;
+ aValue <<= bState;
}
break;
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index 5405c991948e..154f742b1fc2 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -398,18 +398,19 @@ bool FileDialogHelper_Impl::CheckFilterOptionsCapability( const std::shared_ptr<
if( mxFilterCFG.is() && _pFilter )
{
- try {
- Sequence < PropertyValue > aProps;
- Any aAny = mxFilterCFG->getByName( _pFilter->GetName() );
- if ( aAny >>= aProps )
- {
- OUString aServiceName;
- sal_Int32 nPropertyCount = aProps.getLength();
- for( sal_Int32 nProperty=0; nProperty < nPropertyCount; ++nProperty )
+ try
+ {
+ Sequence < PropertyValue > aProps;
+ Any aAny = mxFilterCFG->getByName( _pFilter->GetName() );
+ if ( aAny >>= aProps )
+ {
+ OUString aServiceName;
+ sal_Int32 nPropertyCount = aProps.getLength();
+ for( sal_Int32 nProperty=0; nProperty < nPropertyCount; ++nProperty )
{
- if( aProps[nProperty].Name == "UIComponent" )
- {
- aProps[nProperty].Value >>= aServiceName;
+ if( aProps[nProperty].Name == "UIComponent" )
+ {
+ aProps[nProperty].Value >>= aServiceName;
if( !aServiceName.isEmpty() )
bResult = true;
}
diff --git a/sfx2/source/dialog/printopt.cxx b/sfx2/source/dialog/printopt.cxx
index 92a3047aafd6..f35ce309e93a 100644
--- a/sfx2/source/dialog/printopt.cxx
+++ b/sfx2/source/dialog/printopt.cxx
@@ -265,7 +265,7 @@ void SfxCommonPrintOptionsTabPage::ImplSaveControls( PrinterOptions* pCurrentOpt
if (bOrigBackEnd != m_pPDFCB->IsChecked())
{
pCurrentOptions->SetPDFAsStandardPrintJobFormat( m_pPDFCB->IsChecked() );
- svtools::executeRestartDialog(
+ svtools::executeRestartDialog(
comphelper::getProcessComponentContext(), nullptr,
svtools::RESTART_REASON_PDF_AS_STANDARD_JOB_FORMAT);
}
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index a92ebe458bfa..c638c8be836a 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1330,10 +1330,10 @@ void SfxCommonTemplateDialog_Impl::Update_Impl()
// nothing is allowed
return;
- SfxTemplateItem *pItem = nullptr;
- // current region not within the allowed region or default
- if(nActFamily == 0xffff || nullptr == (pItem = pFamilyState[nActFamily-1].get() ) )
- {
+ SfxTemplateItem *pItem = nullptr;
+ // current region not within the allowed region or default
+ if(nActFamily == 0xffff || nullptr == (pItem = pFamilyState[nActFamily-1].get() ) )
+ {
CheckItem(nActFamily, false);
const size_t nFamilyCount = pStyleFamilies->size();
size_t n;
@@ -1344,9 +1344,9 @@ void SfxCommonTemplateDialog_Impl::Update_Impl()
nAppFilter = pNewItem->GetValue();
FamilySelect( StyleNrToInfoOffset(n) + 1 );
pItem = pNewItem.get();
- }
- else if( bDocChanged )
- {
+ }
+ else if( bDocChanged )
+ {
// other DocShell -> all new
CheckItem( nActFamily );
nActFilter = static_cast< sal_uInt16 >( LoadFactoryStyleFilter( pDocShell ) );
@@ -1360,9 +1360,9 @@ void SfxCommonTemplateDialog_Impl::Update_Impl()
}
else
FillTreeBox();
- }
- else
- {
+ }
+ else
+ {
// other filters for automatic
CheckItem( nActFamily );
const SfxStyleFamilyItem *pStyleItem = GetFamilyItem_Impl();
@@ -1377,11 +1377,11 @@ void SfxCommonTemplateDialog_Impl::Update_Impl()
}
else
nAppFilter = pItem->GetValue();
- }
- const OUString aStyle(pItem->GetStyleName());
- SelectStyle(aStyle);
- EnableDelete();
- EnableNew( bCanNew );
+ }
+ const OUString aStyle(pItem->GetStyleName());
+ SelectStyle(aStyle);
+ EnableDelete();
+ EnableNew( bCanNew );
}
IMPL_LINK_NOARG( SfxCommonTemplateDialog_Impl, TimeOut, Timer *, void )
diff --git a/sfx2/source/doc/doctemplates.cxx b/sfx2/source/doc/doctemplates.cxx
index cc6a7110c24c..085205a36a1a 100644
--- a/sfx2/source/doc/doctemplates.cxx
+++ b/sfx2/source/doc/doctemplates.cxx
@@ -808,8 +808,8 @@ bool SfxDocTplService_Impl::CreateNewUniqueFolderWithPrefix( const OUString& aPa
Content aParent;
uno::Reference< XCommandEnvironment > aQuietEnv;
- if ( Content::create( aDirPath.GetMainURL( INetURLObject::DecodeMechanism::NONE ), aQuietEnv, comphelper::getProcessComponentContext(), aParent ) )
- {
+ if ( Content::create( aDirPath.GetMainURL( INetURLObject::DecodeMechanism::NONE ), aQuietEnv, comphelper::getProcessComponentContext(), aParent ) )
+ {
for ( sal_Int32 nInd = 0; nInd < 32000; nInd++ )
{
OUString aTryName = aPrefix;
@@ -864,7 +864,7 @@ OUString SfxDocTplService_Impl::CreateNewUniqueFileWithPrefix( const OUString& a
OUString aNewFileURL;
INetURLObject aDirPath( aPath );
- Content aParent;
+ Content aParent;
uno::Reference< XCommandEnvironment > aQuietEnv;
if ( Content::create( aDirPath.GetMainURL( INetURLObject::DecodeMechanism::NONE ), aQuietEnv, comphelper::getProcessComponentContext(), aParent ) )
@@ -1591,9 +1591,9 @@ bool SfxDocTplService_Impl::renameGroup( const OUString& rOldName,
// create the group url
Content aGroup;
INetURLObject aGroupObj( maRootURL );
- aGroupObj.insertName( rNewName, false,
- INetURLObject::LAST_SEGMENT,
- INetURLObject::EncodeMechanism::All );
+ aGroupObj.insertName( rNewName, false,
+ INetURLObject::LAST_SEGMENT,
+ INetURLObject::EncodeMechanism::All );
OUString aGroupURL = aGroupObj.GetMainURL( INetURLObject::DecodeMechanism::NONE );
// Check, if there is a group with the new name, return false
diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx
index 9e0a5649e473..f925d71bfa17 100644
--- a/sfx2/source/doc/guisaveas.cxx
+++ b/sfx2/source/doc/guisaveas.cxx
@@ -997,7 +997,7 @@ bool ModelData_Impl::OutputFileDialog( sal_Int16 nStoreMode,
INetURLObject aURL( pFileDlg->GetPath() );
// the path should be provided outside since it might be used for further calls to the dialog
aSuggestedName = aURL.GetName( INetURLObject::DecodeMechanism::WithCharset );
- aSuggestedDir = pFileDlg->GetDisplayDirectory();
+ aSuggestedDir = pFileDlg->GetDisplayDirectory();
// old filter options should be cleared in case different filter is used
@@ -1125,14 +1125,14 @@ bool ModelData_Impl::ShowDocumentInfoDialog(const std::function< void () >& aFun
OUString ModelData_Impl::GetRecommendedExtension( const OUString& aTypeName )
{
- if ( aTypeName.isEmpty() )
+ if ( aTypeName.isEmpty() )
return OUString();
- uno::Reference< container::XNameAccess > xTypeDetection(
+ uno::Reference< container::XNameAccess > xTypeDetection(
comphelper::getProcessServiceFactory()->createInstance("com.sun.star.document.TypeDetection"),
uno::UNO_QUERY );
- if ( xTypeDetection.is() )
- {
+ if ( xTypeDetection.is() )
+ {
uno::Sequence< beans::PropertyValue > aTypeNameProps;
if ( ( xTypeDetection->getByName( aTypeName ) >>= aTypeNameProps ) && aTypeNameProps.getLength() )
{
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index e220b8eee639..ebf5ff841a7e 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -1010,7 +1010,7 @@ Sequence< beans::PropertyValue > SAL_CALL SfxBaseModel::getArgs()
for ( sal_Int32 nOrg = 0; nOrg < nOrgLength; nOrg++ )
{
- sal_Int32 nOldInd = 0;
+ sal_Int32 nOldInd = 0;
while ( nOldInd < nOldLength )
{
if ( m_pData->m_seqArguments[nOrg].Name == seqArgsOld[nOldInd].Name )
diff --git a/sfx2/source/sidebar/SidebarController.cxx b/sfx2/source/sidebar/SidebarController.cxx
index 650bcefd3cab..9aa8fc0859ca 100644
--- a/sfx2/source/sidebar/SidebarController.cxx
+++ b/sfx2/source/sidebar/SidebarController.cxx
@@ -611,7 +611,7 @@ void SidebarController::CreateDeck(const OUString& rDeckId, const Context& rCont
void SidebarController::CreatePanels(const OUString& rDeckId, const Context& rContext)
{
- std::shared_ptr<DeckDescriptor> xDeckDescriptor = mpResourceManager->GetDeckDescriptor(rDeckId);
+ std::shared_ptr<DeckDescriptor> xDeckDescriptor = mpResourceManager->GetDeckDescriptor(rDeckId);
// init panels bounded to that deck, do not wait them being displayed as may be accessed through API
diff --git a/sfx2/source/view/sfxbasecontroller.cxx b/sfx2/source/view/sfxbasecontroller.cxx
index 79f720f18143..280529855614 100644
--- a/sfx2/source/view/sfxbasecontroller.cxx
+++ b/sfx2/source/view/sfxbasecontroller.cxx
@@ -892,7 +892,7 @@ awt::Rectangle SAL_CALL SfxBaseController::queryBorderedArea( const awt::Rectang
void SfxBaseController::BorderWidthsChanged_Impl()
{
- ::cppu::OInterfaceContainerHelper* pContainer = m_pData->m_aListenerContainer.getContainer(
+ ::cppu::OInterfaceContainerHelper* pContainer = m_pData->m_aListenerContainer.getContainer(
cppu::UnoType<frame::XBorderResizeListener>::get());
if ( !pContainer )
return;
diff --git a/shell/source/cmdmail/cmdmailmsg.cxx b/shell/source/cmdmail/cmdmailmsg.cxx
index e1e8f1829635..1127e8d47ebe 100644
--- a/shell/source/cmdmail/cmdmailmsg.cxx
+++ b/shell/source/cmdmail/cmdmailmsg.cxx
@@ -138,7 +138,7 @@ Any SAL_CALL CmdMailMsg::getByName( const OUString& aName )
else if( aName == "attachment" && m_Attachments.getLength() )
return makeAny( m_Attachments );
- throw NoSuchElementException("key not found: " + aName,
+ throw NoSuchElementException("key not found: " + aName,
static_cast < XNameAccess * > (this) );
}
diff --git a/slideshow/source/engine/opengl/TransitionImpl.cxx b/slideshow/source/engine/opengl/TransitionImpl.cxx
index f73237e16baf..62127de1d93e 100644
--- a/slideshow/source/engine/opengl/TransitionImpl.cxx
+++ b/slideshow/source/engine/opengl/TransitionImpl.cxx
@@ -1467,12 +1467,12 @@ int permutation256 [256]= {
void initPermTexture(GLuint *texID)
{
CHECK_GL_ERROR();
- glGenTextures(1, texID);
- glBindTexture(GL_TEXTURE_2D, *texID);
+ glGenTextures(1, texID);
+ glBindTexture(GL_TEXTURE_2D, *texID);
- static bool initialized = false;
- static unsigned char permutation2D[256*256*4];
- if( !initialized ) {
+ static bool initialized = false;
+ static unsigned char permutation2D[256*256*4];
+ if( !initialized ) {
int x, y;
for( y=0; y < 256; y++ )
@@ -1480,11 +1480,11 @@ void initPermTexture(GLuint *texID)
permutation2D[x*4 + y*1024] = permutation256[(y + permutation256[x]) & 0xff];
initialized = true;
- }
+ }
- glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, 256, 256, 0, GL_RGBA, GL_UNSIGNED_BYTE, permutation2D );
- glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
- glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
+ glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, 256, 256, 0, GL_RGBA, GL_UNSIGNED_BYTE, permutation2D );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
+ glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
CHECK_GL_ERROR();
}
diff --git a/slideshow/source/engine/shapes/shapeimporter.cxx b/slideshow/source/engine/shapes/shapeimporter.cxx
index d556edd24aaf..67cd654f3e63 100644
--- a/slideshow/source/engine/shapes/shapeimporter.cxx
+++ b/slideshow/source/engine/shapes/shapeimporter.cxx
@@ -476,7 +476,7 @@ ShapeSharedPtr ShapeImporter::importShape() // throw (ShapeLoadFailedException)
uno::Reference< drawing::XLayerManager > xLayerManager(xNameAccess, uno::UNO_QUERY);
- xDrawnInSlideshow = xLayerManager->getLayerForShape(xCurrShape);
+ xDrawnInSlideshow = xLayerManager->getLayerForShape(xCurrShape);
}
OUString const shapeType( xCurrShape->getShapeType());
diff --git a/slideshow/source/engine/slide/targetpropertiescreator.cxx b/slideshow/source/engine/slide/targetpropertiescreator.cxx
index a50b81f276d9..c76fd6a1b1a4 100644
--- a/slideshow/source/engine/slide/targetpropertiescreator.cxx
+++ b/slideshow/source/engine/slide/targetpropertiescreator.cxx
@@ -306,7 +306,7 @@ namespace internal
//xAnimateNode->getAttributeName(),
"visibility",
uno::makeAny( bVisible ) ) ) );
- break;
+ break;
}
}
}
diff --git a/slideshow/source/engine/slide/userpaintoverlay.cxx b/slideshow/source/engine/slide/userpaintoverlay.cxx
index 9dc527a10727..fbad7fdd7fc0 100644
--- a/slideshow/source/engine/slide/userpaintoverlay.cxx
+++ b/slideshow/source/engine/slide/userpaintoverlay.cxx
@@ -171,8 +171,8 @@ namespace slideshow
repaintWithoutPolygons();
maPolygons.clear();
}
- mbIsEraseAllModeActivated=false;
- return true;
+ mbIsEraseAllModeActivated=false;
+ return true;
}
bool eraseInkWidthChanged( sal_Int32 rEraseInkSize ) override
diff --git a/slideshow/source/inc/tools.hxx b/slideshow/source/inc/tools.hxx
index 8ed353d5d503..0a15008e797e 100644
--- a/slideshow/source/inc/tools.hxx
+++ b/slideshow/source/inc/tools.hxx
@@ -389,7 +389,7 @@ namespace slideshow
css::uno::UNO_QUERY_THROW );
rFunctor( xChildNode );
}
- return true;
+ return true;
}
catch( css::uno::Exception& )
{