summaryrefslogtreecommitdiff
path: root/sot
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2019-04-26 10:46:02 +0900
committerTomaž Vajngerl <quikee@gmail.com>2019-04-26 17:12:08 +0200
commit814e1da4db65c3cf97e2b8dec246bf25c7f51189 (patch)
treeee40b9565f9d392a41f49789ffa0687e4189e583 /sot
parent615202cab983f1f13407f6515aeb047e4e09f6ed (diff)
cleanup files in SOT, not change
Change-Id: Ie3a2390a40214e61b05a57ebd5fbfa5f49a5e1fd Reviewed-on: https://gerrit.libreoffice.org/71351 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'sot')
-rw-r--r--sot/source/base/filelist.cxx13
-rw-r--r--sot/source/base/object.cxx32
2 files changed, 14 insertions, 31 deletions
diff --git a/sot/source/base/filelist.cxx b/sot/source/base/filelist.cxx
index 9db281b7d3ce..ac3388858643 100644
--- a/sot/source/base/filelist.cxx
+++ b/sot/source/base/filelist.cxx
@@ -23,11 +23,7 @@
#include <sot/filelist.hxx>
#include <osl/thread.h>
-/******************************************************************************
-|*
-|* Stream operators
-|*
-\******************************************************************************/
+/* Stream operators */
/* #i28176#
The Windows clipboard bridge now provides a double '\0'
@@ -63,12 +59,7 @@ SvStream& ReadFileList( SvStream& rIStm, FileList& rFileList )
return rIStm;
}
-/******************************************************************************
-|*
-|* Fill in / check the list
-|*
-\******************************************************************************/
-
+/* Fill in / check the list */
void FileList::AppendFile( const OUString& rStr )
{
aStrList.push_back( rStr );
diff --git a/sot/source/base/object.cxx b/sot/source/base/object.cxx
index a33e16f7c281..5c91afeccba9 100644
--- a/sot/source/base/object.cxx
+++ b/sot/source/base/object.cxx
@@ -20,46 +20,40 @@
#include <sot/object.hxx>
SotObject::SotObject()
- : nOwnerLockCount( 0 )
- , bInClose ( false )
+ : nOwnerLockCount(0)
+ , bInClose(false)
{
}
-SotObject::~SotObject()
-{
-}
+SotObject::~SotObject() = default;
-void SotObject::OwnerLock
-(
- bool bLock /* true, lock. false, unlock. */
-)
-/* [Description]
-
- * When the OwnerLock is decremented to zero, the DoClose method is called.
+/** When the OwnerLock is decremented to zero, the DoClose method is called.
* This happens independently of the lock or RefCount. If the OwnerLock
* counter != zero, no DoClose is called by <SotObject::FuzzyLock>.
+ *
+ * bLock - true, lock. false, unlock.
*/
+void SotObject::OwnerLock(bool bLock)
{
- if( bLock )
+ if (bLock)
{
nOwnerLockCount++;
AddFirstRef();
}
- else if ( nOwnerLockCount )
+ else if (nOwnerLockCount)
{
- if( 0 == --nOwnerLockCount )
+ if (0 == --nOwnerLockCount)
DoClose();
ReleaseRef();
}
}
-
bool SotObject::DoClose()
{
bool bRet = false;
- if( !bInClose )
+ if (!bInClose)
{
- tools::SvRef<SotObject> xHoldAlive( this );
+ tools::SvRef<SotObject> xHoldAlive(this);
bInClose = true;
bRet = Close();
bInClose = false;
@@ -67,11 +61,9 @@ bool SotObject::DoClose()
return bRet;
}
-
bool SotObject::Close()
{
return true;
}
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */