diff options
author | vboxsync <vboxsync@cfe28804-0f27-0410-a406-dd0f0b0b656f> | 2021-09-24 17:37:23 +0000 |
---|---|---|
committer | vboxsync <vboxsync@cfe28804-0f27-0410-a406-dd0f0b0b656f> | 2021-09-24 17:37:23 +0000 |
commit | dd584db6429705202a60b1a6a20938dab2145bab (patch) | |
tree | 185fe5e3d1c14ed1be3a9ad70bccea003869c47f | |
parent | 3247aa1ded576ec234c4ef1e5fed7140c7cdecf3 (diff) | |
download | VirtualBox-svn-dd584db6429705202a60b1a6a20938dab2145bab.tar.gz |
Main: bugref: 1909: Reverted changes about translation in non-member functions
git-svn-id: https://www.virtualbox.org/svn/vbox/trunk@91373 cfe28804-0f27-0410-a406-dd0f0b0b656f
-rw-r--r-- | src/VBox/Main/include/VirtualBoxBase.h | 2 | ||||
-rw-r--r-- | src/VBox/Main/include/VirtualBoxClientImpl.h | 2 | ||||
-rw-r--r-- | src/VBox/Main/include/VirtualBoxTranslator.h (renamed from include/VBox/VirtualBoxTranslator.h) | 38 | ||||
-rw-r--r-- | src/VBox/Main/src-all/VirtualBoxBase.cpp | 3 | ||||
-rw-r--r-- | src/VBox/Main/src-all/VirtualBoxTranslator.cpp | 2 | ||||
-rw-r--r-- | src/VBox/Main/src-server/SystemPropertiesImpl.cpp | 2 |
6 files changed, 7 insertions, 42 deletions
diff --git a/src/VBox/Main/include/VirtualBoxBase.h b/src/VBox/Main/include/VirtualBoxBase.h index 04e368231ed..b483e59b432 100644 --- a/src/VBox/Main/include/VirtualBoxBase.h +++ b/src/VBox/Main/include/VirtualBoxBase.h @@ -35,7 +35,7 @@ #include "VBox/com/VirtualBox.h" -#include <VBox/VirtualBoxTranslator.h> +#include "VirtualBoxTranslator.h" // avoid including VBox/settings.h and VBox/xml.h; only declare the classes namespace xml diff --git a/src/VBox/Main/include/VirtualBoxClientImpl.h b/src/VBox/Main/include/VirtualBoxClientImpl.h index 7f0c3c24f47..970ad13eee9 100644 --- a/src/VBox/Main/include/VirtualBoxClientImpl.h +++ b/src/VBox/Main/include/VirtualBoxClientImpl.h @@ -23,7 +23,7 @@ #include "VirtualBoxClientWrap.h" #include "EventImpl.h" -#include <VBox/VirtualBoxTranslator.h> +#include "VirtualBoxTranslator.h" #ifdef RT_OS_WINDOWS # include "win/resource.h" diff --git a/include/VBox/VirtualBoxTranslator.h b/src/VBox/Main/include/VirtualBoxTranslator.h index d7f2bd6968c..b1801b5756b 100644 --- a/include/VBox/VirtualBoxTranslator.h +++ b/src/VBox/Main/include/VirtualBoxTranslator.h @@ -21,45 +21,13 @@ # pragma once #endif -#include <iprt/cdefs.h> -#include <iprt/thread.h> - -#include <VBox/com/defs.h> -#include <VBox/com/ptr.h> -#include <VBox/com/Guid.h> -#include <VBox/com/string.h> - -#include <VBox/com/AutoLock.h> +#include <list> #include <iprt/cpp/lock.h> - -#ifdef VBOX_WITH_MAIN_NLS -#define DECLARE_TRANSLATION_CONTEXT(ctx) \ -struct ctx \ -{\ - static const char *tr(const char *pszSource, const char *pszComment = NULL, const int iNum = -1) \ - { \ - return VirtualBoxTranslator::translate(NULL, #ctx, pszSource, pszComment, iNum); \ - } \ -}; -#else -#define DECLARE_TRANSLATION_CONTEXT(ctx) \ -struct ctx \ -{\ - static const char *tr(const char *pszSource, const char *pszComment = NULL, const int iNum = -1) \ - { \ - NOREF(pszComment); \ - NOREF(iNum); \ - return pszSource; \ - } \ -}; -#endif +#include <VBox/com/AutoLock.h> typedef void *TRCOMPONENT; -#ifdef VBOX_WITH_MAIN_NLS - -COM_STRUCT_OR_CLASS(IVirtualBox); class QMTranslator; class VirtualBoxTranslator @@ -170,7 +138,5 @@ private: const int aNum = -1); }; -#endif /* !VBOX_WITH_MAIN_NLS */ - #endif /* !MAIN_INCLUDED_VirtualBoxTranslator_h */ /* vi: set tabstop=4 shiftwidth=4 expandtab: */ diff --git a/src/VBox/Main/src-all/VirtualBoxBase.cpp b/src/VBox/Main/src-all/VirtualBoxBase.cpp index 480693319e8..341bb50457b 100644 --- a/src/VBox/Main/src-all/VirtualBoxBase.cpp +++ b/src/VBox/Main/src-all/VirtualBoxBase.cpp @@ -33,13 +33,12 @@ #include "VirtualBoxBase.h" #include "AutoCaller.h" #include "VirtualBoxErrorInfoImpl.h" +#include "VirtualBoxTranslator.h" #include "Global.h" #include "LoggingNew.h" #include "VBox/com/ErrorInfo.h" #include "VBox/com/MultiResult.h" -#include <VBox/VirtualBoxTranslator.h> - //////////////////////////////////////////////////////////////////////////////// // diff --git a/src/VBox/Main/src-all/VirtualBoxTranslator.cpp b/src/VBox/Main/src-all/VirtualBoxTranslator.cpp index 2f6768f6896..f46a3485548 100644 --- a/src/VBox/Main/src-all/VirtualBoxTranslator.cpp +++ b/src/VBox/Main/src-all/VirtualBoxTranslator.cpp @@ -28,7 +28,7 @@ #include "Global.h" #include "VirtualBoxBase.h" #include "QMTranslator.h" -#include <VBox/VirtualBoxTranslator.h> +#include "VirtualBoxTranslator.h" #define TRANSLATOR_CACHE_SIZE 32 diff --git a/src/VBox/Main/src-server/SystemPropertiesImpl.cpp b/src/VBox/Main/src-server/SystemPropertiesImpl.cpp index b64583d7f18..8c7a3fc6764 100644 --- a/src/VBox/Main/src-server/SystemPropertiesImpl.cpp +++ b/src/VBox/Main/src-server/SystemPropertiesImpl.cpp @@ -27,7 +27,7 @@ #include "Global.h" #include "LoggingNew.h" #include "AutostartDb.h" -#include <VBox/VirtualBoxTranslator.h> +#include "VirtualBoxTranslator.h" // generated header #include "SchemaDefs.h" |