desktop: sal_Bool->bool

Change-Id: Id2606a2024d62de1882da18a1e438fb626655ff4
This commit is contained in:
Noel Grandin
2014-04-17 11:33:18 +02:00
parent 9b0a75c7b1
commit 133b4d9729
10 changed files with 36 additions and 36 deletions

View File

@@ -50,7 +50,7 @@ namespace dp_gui {
class LicenseView : public MultiLineEdit, public SfxListener
{
sal_Bool mbEndReached;
bool mbEndReached;
Link maEndReachedHdl;
Link maScrolledHdl;
@@ -60,8 +60,8 @@ public:
void ScrollDown( ScrollType eScroll );
sal_Bool IsEndReached() const;
sal_Bool EndReached() const { return mbEndReached; }
bool IsEndReached() const;
bool EndReached() const { return mbEndReached; }
void SetEndReachedHdl( const Link& rHdl ) { maEndReachedHdl = rHdl; }
@@ -134,9 +134,9 @@ void LicenseView::ScrollDown( ScrollType eScroll )
pScroll->DoScrollAction( eScroll );
}
sal_Bool LicenseView::IsEndReached() const
bool LicenseView::IsEndReached() const
{
sal_Bool bEndReached;
bool bEndReached;
ExtTextView* pView = GetTextView();
ExtTextEngine* pEdit = GetTextEngine();
@@ -145,9 +145,9 @@ sal_Bool LicenseView::IsEndReached() const
Point aBottom( 0, aOutSize.Height() );
if ( (sal_uLong) pView->GetDocPos( aBottom ).Y() >= nHeight - 1 )
bEndReached = sal_True;
bEndReached = true;
else
bEndReached = sal_False;
bEndReached = false;
return bEndReached;
}
@@ -156,7 +156,7 @@ void LicenseView::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
if ( rHint.IsA( TYPE(TextHint) ) )
{
sal_Bool bLastVal = EndReached();
bool bLastVal = EndReached();
sal_uLong nId = ((const TextHint&)rHint).GetId();
if ( nId == TEXT_HINT_PARAINSERTED )

View File

@@ -205,7 +205,7 @@ public:
/**
Returns the URL for the icon image.
*/
OUString getIconURL( sal_Bool bHighContrast ) const;
OUString getIconURL( bool bHighContrast ) const;
bool hasDescription() const;

View File

@@ -63,7 +63,7 @@ namespace desktop {
// checks the lockfile, asks user when lockfile is
// found (iff gui) and returns false when we may not continue
sal_Bool check( fpExecWarning execWarning );
bool check( fpExecWarning execWarning );
// removes the lockfile
~Lockfile(void);
@@ -73,14 +73,14 @@ namespace desktop {
// full qualified name (file://-url) of the lockfile
OUString m_aLockname;
// flag whether the d'tor should delete the lock
sal_Bool m_bRemove;
sal_Bool m_bIsLocked;
bool m_bRemove;
bool m_bIsLocked;
// ID
OUString m_aId;
OUString m_aDate;
// access to data in file
void syncToFile(void) const;
sal_Bool isStale(void) const;
bool isStale(void) const;
friend bool Lockfile_execWarning( Lockfile * that );
};

View File

@@ -1309,13 +1309,13 @@ sal_Bool ExtensionManager::synchronize(
OUString sSynchronizingShared(StrSyncRepository::get());
sSynchronizingShared = sSynchronizingShared.replaceAll("%NAME", "shared");
dp_misc::ProgressLevel progressShared(xCmdEnv, sSynchronizingShared);
sal_Bool bModified = getSharedRepository()->synchronize(xAbortChannel, xCmdEnv);
bool bModified = getSharedRepository()->synchronize(xAbortChannel, xCmdEnv);
progressShared.update("\n\n");
OUString sSynchronizingBundled(StrSyncRepository::get());
sSynchronizingBundled = sSynchronizingBundled.replaceAll("%NAME", "bundled");
dp_misc::ProgressLevel progressBundled(xCmdEnv, sSynchronizingBundled);
bModified |= getBundledRepository()->synchronize(xAbortChannel, xCmdEnv);
bModified |= (bool)getBundledRepository()->synchronize(xAbortChannel, xCmdEnv);
progressBundled.update("\n\n");
//Always determine the active extension.

View File

@@ -530,7 +530,7 @@ DescriptionInfoset::getUpdateDownloadUrls() const
return getUrls("desc:update-download/desc:src/@xlink:href");
}
OUString DescriptionInfoset::getIconURL( sal_Bool bHighContrast ) const
OUString DescriptionInfoset::getIconURL( bool bHighContrast ) const
{
css::uno::Sequence< OUString > aStrList = getUrls( "desc:icon/desc:default/@xlink:href" );
css::uno::Sequence< OUString > aStrListHC = getUrls( "desc:icon/desc:high-contrast/@xlink:href" );

View File

@@ -547,7 +547,7 @@ void syncRepositories(
Reference<deployment::XExtensionManager> xExtensionManager;
//synchronize shared before bundled otherewise there are
//more revoke and registration calls.
sal_Bool bModified = false;
bool bModified = false;
if (force || needToSyncRepository("shared") || needToSyncRepository("bundled"))
{
xExtensionManager =

View File

@@ -74,8 +74,8 @@ namespace desktop {
Lockfile::Lockfile( bool bIPCserver )
:m_bIPCserver(bIPCserver)
,m_bRemove(sal_False)
,m_bIsLocked(sal_False)
,m_bRemove(false)
,m_bIsLocked(false)
{
// build the file-url to use for the lock
OUString aUserPath;
@@ -108,16 +108,16 @@ namespace desktop {
// try to create file
File aFile(m_aLockname);
if (aFile.open( osl_File_OpenFlag_Create ) == File::E_EXIST) {
m_bIsLocked = sal_True;
m_bIsLocked = true;
} else {
// new lock created
aFile.close( );
syncToFile( );
m_bRemove = sal_True;
m_bRemove = true;
}
}
sal_Bool Lockfile::check( fpExecWarning execWarning )
bool Lockfile::check( fpExecWarning execWarning )
{
if (m_bIsLocked) {
@@ -130,20 +130,20 @@ namespace desktop {
aFile.open( osl_File_OpenFlag_Create );
aFile.close( );
syncToFile( );
m_bRemove = sal_True;
return sal_True;
m_bRemove = true;
return true;
} else {
//leave alone and return false
m_bRemove = sal_False;
return sal_False;
m_bRemove = false;
return false;
}
} else {
// lock was created by us
return sal_True;
return true;
}
}
sal_Bool Lockfile::isStale( void ) const
bool Lockfile::isStale( void ) const
{
// this checks whether the lockfile was created on the same
// host by the same user. Should this be the case it is safe
@@ -167,9 +167,9 @@ namespace desktop {
aSecurity.getUserName( myUserName );
OString myUser(OUStringToOString(myUserName, RTL_TEXTENCODING_ASCII_US));
if (aUser == myUser)
return sal_True;
return true;
}
return sal_False;
return false;
}
void Lockfile::syncToFile( void ) const

View File

@@ -74,7 +74,7 @@ void ComponentBackendDb::addEntry(OUString const & url, Data const & data)
{
Reference<css::xml::dom::XNode> componentNode = writeKeyElement(url);
writeSimpleElement("java-type-library",
OUString::boolean((sal_Bool) data.javaTypeLibrary),
OUString::boolean(data.javaTypeLibrary),
componentNode);
writeSimpleList(

View File

@@ -1367,7 +1367,7 @@ BackendImpl::ComponentPackageImpl::isRegistered_(
//the rest of the path is different).
//If the caller cannot precisely determine that this package was registered, then it must
//call registerPackage.
sal_Bool bAmbiguous = m_registered == REG_VOID // REG_VOID == we are in the progress of unregistration
bool bAmbiguous = m_registered == REG_VOID // REG_VOID == we are in the progress of unregistration
|| m_registered == REG_MAYBE_REGISTERED;
return beans::Optional< beans::Ambiguous<sal_Bool> >(
true /* IsPresent */,

View File

@@ -100,7 +100,7 @@ class BackendImpl : public ImplBaseT
Reference<deployment::XPackage> bindBundleItem(
OUString const & url, OUString const & mediaType,
sal_Bool bRemoved, //that is, using data base information
bool bRemoved, //that is, using data base information
OUString const & identifier,
Reference<ucb::XCommandEnvironment> const & xCmdEnv,
bool notifyDetectionError = true );
@@ -128,7 +128,7 @@ class BackendImpl : public ImplBaseT
// throws css::uno::RuntimeException,
// css::deployment::DeploymentException
sal_Bool checkLicense(
bool checkLicense(
Reference< ucb::XCommandEnvironment > const & xCmdEnv,
DescriptionInfoset const & description, bool bNoLicenseChecking)
throw (deployment::DeploymentException,
@@ -651,7 +651,7 @@ bool BackendImpl::PackageImpl::checkDependencies(
}
}
sal_Bool BackendImpl::PackageImpl::checkLicense(
bool BackendImpl::PackageImpl::checkLicense(
css::uno::Reference< css::ucb::XCommandEnvironment > const & xCmdEnv,
DescriptionInfoset const & info, bool alreadyInstalled)
throw (css::deployment::DeploymentException,
@@ -1348,7 +1348,7 @@ inline bool isBundle_( OUString const & mediaType )
Reference<deployment::XPackage> BackendImpl::PackageImpl::bindBundleItem(
OUString const & url, OUString const & mediaType,
sal_Bool bRemoved, OUString const & identifier,
bool bRemoved, OUString const & identifier,
Reference<ucb::XCommandEnvironment> const & xCmdEnv,
bool notifyDetectionError )
{