summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bridges/source/cpp_uno/gcc3_macosx_x86-64/abi.cxx4
-rw-r--r--bridges/source/cpp_uno/gcc3_macosx_x86-64/except.cxx4
-rw-r--r--connectivity/source/drivers/macab/MacabServices.cxx2
-rw-r--r--connectivity/source/drivers/macab/MacabStatement.cxx1
-rw-r--r--fpicker/source/aqua/resourceprovider.mm8
-rw-r--r--sfx2/source/appl/shutdowniconaqua.mm4
-rw-r--r--shell/source/backends/macbe/macbackend.mm7
-rw-r--r--vcl/osx/DataFlavorMapping.cxx25
-rw-r--r--vcl/osx/printaccessoryview.mm12
-rw-r--r--vcl/osx/salinst.cxx4
-rw-r--r--vcl/osx/salobj.cxx4
-rw-r--r--vcl/quartz/ctfonts.cxx4
-rw-r--r--vcl/quartz/salbmp.cxx9
-rw-r--r--vcl/quartz/salgdi.cxx4
14 files changed, 79 insertions, 13 deletions
diff --git a/bridges/source/cpp_uno/gcc3_macosx_x86-64/abi.cxx b/bridges/source/cpp_uno/gcc3_macosx_x86-64/abi.cxx
index 3da3adac5fc3..ceed901f9e11 100644
--- a/bridges/source/cpp_uno/gcc3_macosx_x86-64/abi.cxx
+++ b/bridges/source/cpp_uno/gcc3_macosx_x86-64/abi.cxx
@@ -58,6 +58,8 @@
using namespace x86_64;
+namespace {
+
/* Register class used for passing given 64bit part of the argument.
These represent classes as documented by the PS ABI, with the exception
of SSESF, SSEDF classes, that are basically SSE class, just gcc will
@@ -80,6 +82,8 @@ enum x86_64_reg_class
X86_64_MEMORY_CLASS
};
+}
+
#define MAX_CLASSES 4
/* x86-64 register passing implementation. See x86-64 ABI for details. Goal
diff --git a/bridges/source/cpp_uno/gcc3_macosx_x86-64/except.cxx b/bridges/source/cpp_uno/gcc3_macosx_x86-64/except.cxx
index c31cf180a704..c4cfe5123ec9 100644
--- a/bridges/source/cpp_uno/gcc3_macosx_x86-64/except.cxx
+++ b/bridges/source/cpp_uno/gcc3_macosx_x86-64/except.cxx
@@ -141,6 +141,8 @@ static OUString toUNOname( char const * p )
#endif
}
+namespace {
+
class RTTI
{
typedef std::unordered_map< OUString, std::type_info * > t_rtti_map;
@@ -158,6 +160,8 @@ public:
std::type_info * getRTTI( typelib_CompoundTypeDescription * );
};
+}
+
RTTI::RTTI()
: m_hApp( dlopen( nullptr, RTLD_LAZY ) )
{
diff --git a/connectivity/source/drivers/macab/MacabServices.cxx b/connectivity/source/drivers/macab/MacabServices.cxx
index 8642c03e61e3..a550fcb94f58 100644
--- a/connectivity/source/drivers/macab/MacabServices.cxx
+++ b/connectivity/source/drivers/macab/MacabServices.cxx
@@ -37,6 +37,7 @@ typedef Reference< XSingleServiceFactory > (*createFactoryFunc)
rtl_ModuleCount*
);
+namespace {
struct ProviderRequest
{
@@ -74,6 +75,7 @@ struct ProviderRequest
void* getProvider() const { return xRet.get(); }
};
+}
extern "C" SAL_DLLPUBLIC_EXPORT void* macab_component_getFactory(
const sal_Char* pImplementationName,
diff --git a/connectivity/source/drivers/macab/MacabStatement.cxx b/connectivity/source/drivers/macab/MacabStatement.cxx
index a418b85c2d94..db6e3876b993 100644
--- a/connectivity/source/drivers/macab/MacabStatement.cxx
+++ b/connectivity/source/drivers/macab/MacabStatement.cxx
@@ -27,6 +27,7 @@
#include "MacabResultSetMetaData.hxx"
#include "macabcondition.hxx"
#include "macaborder.hxx"
+#include "macabutilities.hxx"
#include <TConnection.hxx>
#include <cppuhelper/typeprovider.hxx>
#include <connectivity/dbexception.hxx>
diff --git a/fpicker/source/aqua/resourceprovider.mm b/fpicker/source/aqua/resourceprovider.mm
index b5ec09532ea2..4daa24b9ff07 100644
--- a/fpicker/source/aqua/resourceprovider.mm
+++ b/fpicker/source/aqua/resourceprovider.mm
@@ -37,17 +37,15 @@ using namespace ::com::sun::star::ui::dialogs::CommonFilePickerElementIds;
// we have to translate control ids to resource ids
+namespace {
+
struct Entry
{
sal_Int32 ctrlId;
const char* resId;
};
-struct OldEntry
-{
- sal_Int32 ctrlId;
- sal_Int16 resId;
-};
+}
Entry const CtrlIdToResIdTable[] = {
{ CHECKBOX_AUTOEXTENSION, STR_SVT_FILEPICKER_AUTO_EXTENSION },
diff --git a/sfx2/source/appl/shutdowniconaqua.mm b/sfx2/source/appl/shutdowniconaqua.mm
index 14bb2d2efeb9..4a0f61b5dcf5 100644
--- a/sfx2/source/appl/shutdowniconaqua.mm
+++ b/sfx2/source/appl/shutdowniconaqua.mm
@@ -122,6 +122,8 @@ static NSString* getAutoreleasedString( const OUString& rStr )
return [[[NSString alloc] initWithCharacters: reinterpret_cast<unichar const *>(rStr.getStr()) length: rStr.getLength()] autorelease];
}
+namespace {
+
struct RecentMenuEntry
{
OUString aURL;
@@ -142,6 +144,8 @@ class RecentFilesStringLength : public ::cppu::WeakImplHelper< css::util::XStrin
}
};
+}
+
@interface RecentMenuDelegate : NSObject
{
std::vector< RecentMenuEntry >* m_pRecentFilesItems;
diff --git a/shell/source/backends/macbe/macbackend.mm b/shell/source/backends/macbe/macbackend.mm
index cb730c93d66c..54bd4726c6e3 100644
--- a/shell/source/backends/macbe/macbackend.mm
+++ b/shell/source/backends/macbe/macbackend.mm
@@ -38,16 +38,15 @@
#define SPACE ' '
#define SEMI_COLON ';'
+namespace
+{
+
typedef enum {
sHTTP,
sHTTPS,
sFTP
} ServiceType;
-
-namespace
-{
-
/*
* Returns current proxy settings for selected service type (HTTP or
* FTP) as a C string (in the buffer specified by host and hostSize)
diff --git a/vcl/osx/DataFlavorMapping.cxx b/vcl/osx/DataFlavorMapping.cxx
index 48dc56a3037c..c63bc3321d16 100644
--- a/vcl/osx/DataFlavorMapping.cxx
+++ b/vcl/osx/DataFlavorMapping.cxx
@@ -146,8 +146,6 @@ SAL_WNODEPRECATED_DECLARATIONS_POP
return (theType == cppu::UnoType<OUString>::get() );
}
-} // unnamed namespace
-
/* A base class for other data provider.
*/
class DataProviderBaseImpl : public DataProvider
@@ -163,6 +161,8 @@ protected:
id mSystemData;
};
+} // unnamed namespace
+
DataProviderBaseImpl::DataProviderBaseImpl(const Any& data) :
mData(data),
mSystemData(nil)
@@ -183,6 +183,8 @@ DataProviderBaseImpl::~DataProviderBaseImpl()
}
}
+namespace {
+
class UniDataProvider : public DataProviderBaseImpl
{
public:
@@ -195,6 +197,8 @@ public:
virtual Any getOOoData() override;
};
+}
+
UniDataProvider::UniDataProvider(const Any& data) :
DataProviderBaseImpl(data)
{
@@ -234,6 +238,8 @@ Any UniDataProvider::getOOoData()
return oOOData;
}
+namespace {
+
class ByteSequenceDataProvider : public DataProviderBaseImpl
{
public:
@@ -246,6 +252,8 @@ public:
virtual Any getOOoData() override;
};
+}
+
ByteSequenceDataProvider::ByteSequenceDataProvider(const Any& data) :
DataProviderBaseImpl(data)
{
@@ -284,6 +292,8 @@ Any ByteSequenceDataProvider::getOOoData()
return oOOData;
}
+namespace {
+
class HTMLFormatDataProvider : public DataProviderBaseImpl
{
public:
@@ -294,6 +304,8 @@ public:
virtual Any getOOoData() override;
};
+}
+
HTMLFormatDataProvider::HTMLFormatDataProvider(NSData* data) :
DataProviderBaseImpl(data)
{
@@ -340,6 +352,9 @@ Any HTMLFormatDataProvider::getOOoData()
return oOOData;
}
+namespace {
+
+
class PNGDataProvider : public DataProviderBaseImpl
{
NSBitmapImageFileType meImageType;
@@ -353,6 +368,8 @@ public:
virtual Any getOOoData() override;
};
+}
+
PNGDataProvider::PNGDataProvider( const Any& data, NSBitmapImageFileType eImageType) :
DataProviderBaseImpl(data),
meImageType( eImageType )
@@ -404,6 +421,8 @@ Any PNGDataProvider::getOOoData()
return oOOData;
}
+namespace {
+
class FileListDataProvider : public DataProviderBaseImpl
{
public:
@@ -414,6 +433,8 @@ public:
virtual Any getOOoData() override;
};
+}
+
FileListDataProvider::FileListDataProvider(const Any& data) :
DataProviderBaseImpl(data)
{
diff --git a/vcl/osx/printaccessoryview.mm b/vcl/osx/printaccessoryview.mm
index c494ec7b2b7c..48d99ec384ba 100644
--- a/vcl/osx/printaccessoryview.mm
+++ b/vcl/osx/printaccessoryview.mm
@@ -46,8 +46,12 @@ using namespace com::sun::star;
using namespace com::sun::star::beans;
using namespace com::sun::star::uno;
+namespace {
+
class ControllerProperties;
+}
+
@interface ControlTarget : NSObject
{
ControllerProperties* mpController;
@@ -149,6 +153,8 @@ class ControllerProperties;
@end
+namespace {
+
class ControllerProperties
{
std::map< int, OUString > maTagToPropertyName;
@@ -315,6 +321,8 @@ public:
};
+}
+
static OUString filterAccelerator( OUString const & rText )
{
OUStringBuffer aBuf( rText.getLength() );
@@ -419,6 +427,8 @@ static OUString filterAccelerator( OUString const & rText )
@end
+namespace {
+
struct ColumnItem
{
NSControl* pControl;
@@ -450,6 +460,8 @@ struct ColumnItem
}
};
+}
+
static void adjustViewAndChildren( NSView* pNSView, NSSize& rMaxSize,
std::vector< ColumnItem >& rLeftColumn,
std::vector< ColumnItem >& rRightColumn
diff --git a/vcl/osx/salinst.cxx b/vcl/osx/salinst.cxx
index ae8074295c59..6b5c177bc755 100644
--- a/vcl/osx/salinst.cxx
+++ b/vcl/osx/salinst.cxx
@@ -83,6 +83,8 @@ static int* gpnInit = nullptr;
static NSMenu* pDockMenu = nil;
static bool bLeftMain = false;
+namespace {
+
class AquaDelayedSettingsChanged : public Idle
{
bool mbInvalidate;
@@ -113,6 +115,8 @@ public:
}
};
+}
+
void AquaSalInstance::delayedSettingsChanged( bool bInvalidate )
{
osl::Guard< comphelper::SolarMutex > aGuard( *GetYieldMutex() );
diff --git a/vcl/osx/salobj.cxx b/vcl/osx/salobj.cxx
index 34679dcdbaf7..75969d4e6b8c 100644
--- a/vcl/osx/salobj.cxx
+++ b/vcl/osx/salobj.cxx
@@ -287,6 +287,8 @@ const SystemEnvData* AquaSalObject::GetSystemData() const
return &maSysData;
}
+namespace {
+
class AquaOpenGLContext : public OpenGLContext
{
public:
@@ -310,6 +312,8 @@ SAL_WNODEPRECATED_DECLARATIONS_POP
virtual void swapBuffers() override;
};
+}
+
void AquaOpenGLContext::resetCurrent()
{
OSX_SALDATA_RUNINMAIN( resetCurrent() )
diff --git a/vcl/quartz/ctfonts.cxx b/vcl/quartz/ctfonts.cxx
index 252720a0aa4e..d100e03b8910 100644
--- a/vcl/quartz/ctfonts.cxx
+++ b/vcl/quartz/ctfonts.cxx
@@ -143,9 +143,13 @@ bool CoreTextStyle::ImplGetGlyphBoundRect(sal_GlyphId nId, tools::Rectangle& rRe
return true;
}
+namespace {
+
// callbacks from CTFontCreatePathForGlyph+CGPathApply for GetGlyphOutline()
struct GgoData { basegfx::B2DPolygon maPolygon; basegfx::B2DPolyPolygon* mpPolyPoly; };
+}
+
static void MyCGPathApplierFunc( void* pData, const CGPathElement* pElement )
{
basegfx::B2DPolygon& rPolygon = static_cast<GgoData*>(pData)->maPolygon;
diff --git a/vcl/quartz/salbmp.cxx b/vcl/quartz/salbmp.cxx
index 117c038c844e..2f6820b2877e 100644
--- a/vcl/quartz/salbmp.cxx
+++ b/vcl/quartz/salbmp.cxx
@@ -599,13 +599,18 @@ sal_uInt16 QuartzSalBitmap::GetBitCount() const
return mnBits;
}
-static struct pal_entry
+namespace {
+
+struct pal_entry
{
sal_uInt8 mnRed;
sal_uInt8 mnGreen;
sal_uInt8 mnBlue;
+};
+
}
-const aImplSalSysPalEntryAry[ 16 ] =
+
+static pal_entry const aImplSalSysPalEntryAry[ 16 ] =
{
{ 0, 0, 0 },
{ 0, 0, 0x80 },
diff --git a/vcl/quartz/salgdi.cxx b/vcl/quartz/salgdi.cxx
index b6df53319e28..000141123d7e 100644
--- a/vcl/quartz/salgdi.cxx
+++ b/vcl/quartz/salgdi.cxx
@@ -57,6 +57,8 @@
using namespace vcl;
+namespace {
+
class CoreTextGlyphFallbackSubstititution
: public ImplGlyphFallbackFontSubstitution
{
@@ -64,6 +66,8 @@ public:
bool FindFontSubstitute(FontSelectPattern&, LogicalFontInstance* pLogicalFont, OUString&) const override;
};
+}
+
bool CoreTextGlyphFallbackSubstititution::FindFontSubstitute(FontSelectPattern& rPattern, LogicalFontInstance* pLogicalFont,
OUString& rMissingChars) const
{