[Libreoffice-commits] core.git: bridges/source extensions/source fpicker/source lingucomponent/source shell/source vcl/osx vcl/quartz

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Tue Sep 18 12:42:20 UTC 2018


 bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx       |    2 +-
 extensions/source/macosx/spotlight/OOoSpotlightImporter.m   |    2 +-
 extensions/source/macosx/spotlight/main.m                   |   10 +++++-----
 fpicker/source/aqua/resourceprovider.mm                     |    4 ++--
 lingucomponent/source/spellcheck/macosxspell/macspellimp.mm |    2 +-
 shell/source/backends/macbe/macbackend.mm                   |    4 ++--
 vcl/osx/DragSource.cxx                                      |    4 ++--
 vcl/osx/DropTarget.cxx                                      |    4 ++--
 vcl/osx/a11ylistener.cxx                                    |    2 +-
 vcl/osx/a11ywrapper.mm                                      |    2 +-
 vcl/osx/clipboard.cxx                                       |    4 ++--
 vcl/quartz/ctfonts.cxx                                      |    2 +-
 vcl/quartz/salbmp.cxx                                       |    2 +-
 13 files changed, 22 insertions(+), 22 deletions(-)

New commits:
commit e19a21add0d1f559edc28451eddeb11335cffd21
Author:     Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Tue Sep 18 10:39:46 2018 +0200
Commit:     Stephan Bergmann <sbergman at redhat.com>
CommitDate: Tue Sep 18 14:41:57 2018 +0200

    loplugin:external (macOS)
    
    Change-Id: Ib06572a844d2999e9ecd91e26abd98ecec06a0ae
    Reviewed-on: https://gerrit.libreoffice.org/60665
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx b/bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx
index 54f0598d9ef9..8f453e4aeb53 100644
--- a/bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx
@@ -402,7 +402,7 @@ const int codeSnippetSize = 24;
 // Note: The code snippet we build here must not create a stack frame,
 // otherwise the UNO exceptions stop working thanks to non-existing
 // unwinding info.
-unsigned char * codeSnippet( unsigned char * code,
+static unsigned char * codeSnippet( unsigned char * code,
         sal_Int32 nFunctionIndex, sal_Int32 nVtableOffset,
         bool bHasHiddenParam )
 {
diff --git a/extensions/source/macosx/spotlight/OOoSpotlightImporter.m b/extensions/source/macosx/spotlight/OOoSpotlightImporter.m
index dde2c473437b..07e19332060a 100644
--- a/extensions/source/macosx/spotlight/OOoSpotlightImporter.m
+++ b/extensions/source/macosx/spotlight/OOoSpotlightImporter.m
@@ -284,7 +284,7 @@ static bool findDataStream(NSFileHandle *file, CentralDirectoryEntry *entry, NSS
     return true;
 }
 
-NSData *getUncompressedData(NSFileHandle *file, NSString *name)
+static NSData *getUncompressedData(NSFileHandle *file, NSString *name)
 {
     CentralDirectoryEntry entry;
     if (!findDataStream(file, &entry, name))
diff --git a/extensions/source/macosx/spotlight/main.m b/extensions/source/macosx/spotlight/main.m
index 7bbf2c75cbe9..b1a6381a7363 100644
--- a/extensions/source/macosx/spotlight/main.m
+++ b/extensions/source/macosx/spotlight/main.m
@@ -64,11 +64,11 @@ typedef struct
 //    Forward declaration for the IUnknown implementation.
 //
 
-MetadataImporterPluginType  *AllocMetadataImporterPluginType(CFUUIDRef inFactoryID);
-void                      DeallocMetadataImporterPluginType(MetadataImporterPluginType *thisInstance);
-HRESULT                   MetadataImporterQueryInterface(void *thisInstance,REFIID iid,LPVOID *ppv);
-ULONG                     MetadataImporterPluginAddRef(void *thisInstance);
-ULONG                     MetadataImporterPluginRelease(void *thisInstance);
+static MetadataImporterPluginType  *AllocMetadataImporterPluginType(CFUUIDRef inFactoryID);
+static void                      DeallocMetadataImporterPluginType(MetadataImporterPluginType *thisInstance);
+static HRESULT                   MetadataImporterQueryInterface(void *thisInstance,REFIID iid,LPVOID *ppv);
+static ULONG                     MetadataImporterPluginAddRef(void *thisInstance);
+static ULONG                     MetadataImporterPluginRelease(void *thisInstance);
 //    testInterfaceFtbl    definition
 //    The TestInterface function table.
 //
diff --git a/fpicker/source/aqua/resourceprovider.mm b/fpicker/source/aqua/resourceprovider.mm
index 49009ca16136..1f07273da954 100644
--- a/fpicker/source/aqua/resourceprovider.mm
+++ b/fpicker/source/aqua/resourceprovider.mm
@@ -75,7 +75,7 @@ Entry const CtrlIdToResIdTable[] = {
 
 const sal_Int32 SIZE_TABLE = SAL_N_ELEMENTS( CtrlIdToResIdTable );
 
-const char* CtrlIdToResId(sal_Int32 aControlId)
+static const char* CtrlIdToResId(sal_Int32 aControlId)
 {
     const char *pResId = nullptr;
 
@@ -93,7 +93,7 @@ const char* CtrlIdToResId(sal_Int32 aControlId)
 
 namespace CResourceProvider_Impl
 {
-    NSString* getResString(sal_Int16 aId)
+    static NSString* getResString(sal_Int16 aId)
     {
         OUString aResString;
 
diff --git a/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm b/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm
index 96cb56529db5..5b3e30487d7d 100644
--- a/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm
+++ b/lingucomponent/source/spellcheck/macosxspell/macspellimp.mm
@@ -485,7 +485,7 @@ Reference< XSpellAlternatives > SAL_CALL
 }
 
 /// @throws Exception
-Reference< XInterface > MacSpellChecker_CreateInstance(
+static Reference< XInterface > MacSpellChecker_CreateInstance(
             const Reference< XMultiServiceFactory > & /*rSMgr*/ )
 {
 
diff --git a/shell/source/backends/macbe/macbackend.mm b/shell/source/backends/macbe/macbackend.mm
index 1ed71f1c4e36..59c34daad271 100644
--- a/shell/source/backends/macbe/macbackend.mm
+++ b/shell/source/backends/macbe/macbackend.mm
@@ -156,7 +156,7 @@ MacOSXBackend* MacOSXBackend::createInstance()
     return new MacOSXBackend;
 }
 
-rtl::OUString CFStringToOUString(const CFStringRef sOrig) {
+static rtl::OUString CFStringToOUString(const CFStringRef sOrig) {
     CFRetain(sOrig);
 
     CFIndex nStringLen = CFStringGetLength(sOrig)+1;
@@ -171,7 +171,7 @@ rtl::OUString CFStringToOUString(const CFStringRef sOrig) {
     return rtl::OUString::createFromAscii(sBuffer);
 }
 
-rtl::OUString GetOUString( NSString* pStr )
+static rtl::OUString GetOUString( NSString* pStr )
 {
     if( ! pStr )
         return rtl::OUString();
diff --git a/vcl/osx/DragSource.cxx b/vcl/osx/DragSource.cxx
index 6fa4b9d12f4d..11ba53d9ee6c 100644
--- a/vcl/osx/DragSource.cxx
+++ b/vcl/osx/DragSource.cxx
@@ -54,12 +54,12 @@ NSView* DragSource::g_DragSourceView = nil;
 bool DragSource::g_DropSuccessSet = false;
 bool DragSource::g_DropSuccess = false;
 
-OUString dragSource_getImplementationName()
+static OUString dragSource_getImplementationName()
 {
   return OUString("com.sun.star.comp.datatransfer.dnd.OleDragSource_V1");
 }
 
-Sequence<OUString> dragSource_getSupportedServiceNames()
+static Sequence<OUString> dragSource_getSupportedServiceNames()
 {
   return { OUString("com.sun.star.datatransfer.dnd.OleDragSource") };
 }
diff --git a/vcl/osx/DropTarget.cxx b/vcl/osx/DropTarget.cxx
index 4d99f3c69982..c294a3157f46 100644
--- a/vcl/osx/DropTarget.cxx
+++ b/vcl/osx/DropTarget.cxx
@@ -44,12 +44,12 @@ using namespace com::sun::star::uno;
 using namespace com::sun::star;
 using namespace comphelper;
 
-OUString dropTarget_getImplementationName()
+static OUString dropTarget_getImplementationName()
 {
     return OUString("com.sun.star.comp.datatransfer.dnd.OleDropTarget_V1");
 }
 
-Sequence<OUString> dropTarget_getSupportedServiceNames()
+static Sequence<OUString> dropTarget_getSupportedServiceNames()
 {
     return { OUString("com.sun.star.datatransfer.dnd.OleDropTarget") };
 }
diff --git a/vcl/osx/a11ylistener.cxx b/vcl/osx/a11ylistener.cxx
index 7bb794f65b27..b8220c07d933 100644
--- a/vcl/osx/a11ylistener.cxx
+++ b/vcl/osx/a11ylistener.cxx
@@ -35,7 +35,7 @@ using namespace ::com::sun::star::awt;
 using namespace ::com::sun::star::lang;
 using namespace ::com::sun::star::uno;
 
-NSString * getTableNotification( const AccessibleEventObject& aEvent )
+static NSString * getTableNotification( const AccessibleEventObject& aEvent )
 {
     AccessibleTableModelChange aChange;
     NSString * notification = nil;
diff --git a/vcl/osx/a11ywrapper.mm b/vcl/osx/a11ywrapper.mm
index f2f6148acc4b..92ccc7c750fe 100644
--- a/vcl/osx/a11ywrapper.mm
+++ b/vcl/osx/a11ywrapper.mm
@@ -972,7 +972,7 @@ static std::ostream &operator<<(std::ostream &s, NSObject *obj) {
     return hit;
 }
 
-Reference < XAccessibleContext > hitTestRunner ( css::awt::Point point,
+static Reference < XAccessibleContext > hitTestRunner ( css::awt::Point point,
                                                  Reference < XAccessibleContext > const & rxAccessibleContext ) {
     Reference < XAccessibleContext > hitChild;
     Reference < XAccessibleContext > emptyReference;
diff --git a/vcl/osx/clipboard.cxx b/vcl/osx/clipboard.cxx
index c31fd9fa491e..1e055100eed8 100644
--- a/vcl/osx/clipboard.cxx
+++ b/vcl/osx/clipboard.cxx
@@ -66,12 +66,12 @@ using namespace comphelper;
 
 @end
 
-OUString clipboard_getImplementationName()
+static OUString clipboard_getImplementationName()
 {
   return OUString("com.sun.star.datatransfer.clipboard.AquaClipboard");
 }
 
-Sequence<OUString> clipboard_getSupportedServiceNames()
+static Sequence<OUString> clipboard_getSupportedServiceNames()
 {
   return { OUString("com.sun.star.datatransfer.clipboard.SystemClipboard") };
 }
diff --git a/vcl/quartz/ctfonts.cxx b/vcl/quartz/ctfonts.cxx
index 7894cfef0c8f..6ceec8a0295d 100644
--- a/vcl/quartz/ctfonts.cxx
+++ b/vcl/quartz/ctfonts.cxx
@@ -40,7 +40,7 @@
 #include <sallayout.hxx>
 #include <hb-coretext.h>
 
-inline double toRadian(int nDegree)
+static inline double toRadian(int nDegree)
 {
     return nDegree * (M_PI / 1800.0);
 }
diff --git a/vcl/quartz/salbmp.cxx b/vcl/quartz/salbmp.cxx
index 3cde1f380955..e8df35c712bf 100644
--- a/vcl/quartz/salbmp.cxx
+++ b/vcl/quartz/salbmp.cxx
@@ -696,7 +696,7 @@ const aImplSalSysPalEntryAry[ 16 ] =
 { 0xFF, 0xFF, 0xFF }
 };
 
-const BitmapPalette& GetDefaultPalette( int mnBits, bool bMonochrome )
+static const BitmapPalette& GetDefaultPalette( int mnBits, bool bMonochrome )
 {
     if( bMonochrome )
         return Bitmap::GetGreyPalette( 1U << mnBits );


More information about the Libreoffice-commits mailing list