From 8c7bf264f50885b9aef730ab16eec8ce499a9bf5 Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Mon, 25 May 2009 23:32:53 +0000 Subject: [PATCH] The 'extern "C"' was missing for the C function replacement of the Version() method. Rather reintroduced the method (private) instead. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30854 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- headers/os/translation/TranslatorRoster.h | 8 ++++++-- src/kits/translation/TranslatorRoster.cpp | 10 +++++++--- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/headers/os/translation/TranslatorRoster.h b/headers/os/translation/TranslatorRoster.h index fcda94163c..f7bcd22c2e 100644 --- a/headers/os/translation/TranslatorRoster.h +++ b/headers/os/translation/TranslatorRoster.h @@ -1,5 +1,5 @@ /* - * Copyright 2002-2007, Haiku, Inc. All Rights Reserved. + * Copyright 2002-2009, Haiku, Inc. All Rights Reserved. * Distributed under the terms of the MIT License. */ #ifndef _TRANSLATOR_ROSTER_H @@ -41,7 +41,7 @@ class BTranslatorRoster : public BArchivable { const char* hintMIME = NULL, uint32 wantType = 0); virtual status_t GetTranslators(BPositionIO* source, - BMessage* ioExtension, translator_info** _info, int32* _numInfo, + BMessage* ioExtension, translator_info** _info, int32* _numInfo, uint32 hintType = 0, const char* hintMIME = NULL, uint32 wantType = 0); @@ -94,6 +94,10 @@ class BTranslatorRoster : public BArchivable { void _Initialize(); + static const char* Version(int32* outCurVersion, int32* outMinVersion, + int32 inAppVersion); + // for backward compatiblity only + private: friend class Private; diff --git a/src/kits/translation/TranslatorRoster.cpp b/src/kits/translation/TranslatorRoster.cpp index 82399939c2..61bbbf7d28 100644 --- a/src/kits/translation/TranslatorRoster.cpp +++ b/src/kits/translation/TranslatorRoster.cpp @@ -1,5 +1,5 @@ /* - * Copyright 2002-2007, Haiku, Inc. All Rights Reserved. + * Copyright 2002-2009, Haiku, Inc. All Rights Reserved. * Distributed under the terms of the MIT License. * * Authors: @@ -1700,8 +1700,10 @@ BTranslatorRoster::operator=(const BTranslatorRoster &tr) } -const char * -Version__17BTranslatorRosterPlT1l(int32 *outCurVersion, int32 *outMinVersion, +#if __GNUC__ == 2 // gcc 2 + +/*static*/ const char* +BTranslatorRoster::Version(int32* outCurVersion, int32* outMinVersion, int32 inAppVersion) { if (!outCurVersion || !outMinVersion) @@ -1721,6 +1723,8 @@ Version__17BTranslatorRosterPlT1l(int32 *outCurVersion, int32 *outMinVersion, return vString; } +#endif // gcc 2 + void BTranslatorRoster::ReservedTranslatorRoster1() {} void BTranslatorRoster::ReservedTranslatorRoster2() {}