mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-21 01:29:50 +00:00
Update headers in i18n
Remove external_libraries headers for icu and tinygettext, as they neither add any workarounds needed and as quite a few other libraries don't have such a header either. As for the warnings suppressed, this is no longer needed as they were fixed and with vs2019 added support for -isystem or equivalent would make this useless eitherway. Further make include-what-you-use happy with files in source/118n and fix what needs to be fixed after. Ref: #8086 Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
This commit is contained in:
+21
-2
@@ -25,17 +25,36 @@
|
||||
#include "i18n/L10n.h"
|
||||
|
||||
#include "gui/GUIManager.h"
|
||||
#include "lib/external_libraries/tinygettext.h"
|
||||
#include "lib/file/file_system.h"
|
||||
#include "lib/code_annotation.h"
|
||||
#include "lib/debug.h"
|
||||
#include "lib/file/vfs/vfs_util.h"
|
||||
#include "lib/path.h"
|
||||
#include "lib/utf8.h"
|
||||
#include "ps/CLogger.h"
|
||||
#include "ps/CStr.h"
|
||||
#include "ps/ConfigDB.h"
|
||||
#include "ps/Errors.h"
|
||||
#include "ps/Filesystem.h"
|
||||
#include "ps/GameSetup/GameSetup.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <boost/algorithm/string/predicate.hpp>
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <exception>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <tinygettext/dictionary.hpp>
|
||||
#include <tinygettext/log.hpp>
|
||||
#include <tinygettext/po_parser.hpp>
|
||||
#include <unicode/bytestream.h>
|
||||
#include <unicode/calendar.h>
|
||||
#include <unicode/numfmt.h>
|
||||
#include <unicode/smpdtfmt.h>
|
||||
#include <unicode/timezone.h>
|
||||
#include <unicode/unistr.h>
|
||||
#include <unicode/unum.h>
|
||||
#include <utility>
|
||||
|
||||
namespace
|
||||
{
|
||||
|
||||
+5
-3
@@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 2022 Wildfire Games.
|
||||
/* Copyright (C) 2025 Wildfire Games.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files (the
|
||||
@@ -23,13 +23,15 @@
|
||||
#ifndef INCLUDED_L10N
|
||||
#define INCLUDED_L10N
|
||||
|
||||
#include "lib/code_annotation.h"
|
||||
#include "lib/external_libraries/icu.h"
|
||||
#include "lib/file/vfs/vfs_path.h"
|
||||
#include "lib/status.h"
|
||||
#include "ps/Singleton.h"
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <unicode/datefmt.h>
|
||||
#include <unicode/locid.h>
|
||||
#include <unicode/utypes.h>
|
||||
#include <vector>
|
||||
|
||||
namespace tinygettext
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 2021 Wildfire Games.
|
||||
/* Copyright (C) 2025 Wildfire Games.
|
||||
* This file is part of 0 A.D.
|
||||
*
|
||||
* 0 A.D. is free software: you can redistribute it and/or modify
|
||||
@@ -20,10 +20,15 @@
|
||||
#include "JSInterface_L10n.h"
|
||||
|
||||
#include "i18n/L10n.h"
|
||||
#include "lib/utf8.h"
|
||||
#include "ps/CLogger.h"
|
||||
#include "scriptinterface/FunctionWrapper.h"
|
||||
#include "scriptinterface/ScriptRequest.h"
|
||||
|
||||
#include <js/PropertyAndElement.h>
|
||||
#include <unicode/utypes.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace JS { class CallArgs; }
|
||||
|
||||
namespace JSI_L10n
|
||||
{
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
/* Copyright (C) 2013 Wildfire Games.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files (the
|
||||
* "Software"), to deal in the Software without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Software, and to
|
||||
* permit persons to whom the Software is furnished to do so, subject to
|
||||
* the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef INCLUDED_ICU
|
||||
#define INCLUDED_ICU
|
||||
|
||||
#include <unicode/smpdtfmt.h>
|
||||
|
||||
#endif // #ifndef INCLUDED_ICU
|
||||
@@ -1,44 +0,0 @@
|
||||
/* Copyright (C) 2013 Wildfire Games.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files (the
|
||||
* "Software"), to deal in the Software without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Software, and to
|
||||
* permit persons to whom the Software is furnished to do so, subject to
|
||||
* the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Bring in the TinyGettext header file.
|
||||
*/
|
||||
|
||||
#ifndef INCLUDED_TINYGETTEXT
|
||||
#define INCLUDED_TINYGETTEXT
|
||||
|
||||
#if MSC_VERSION
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable:4251) // "class X needs to have dll-interface to be used by clients of class Y"
|
||||
# pragma warning(disable:4800) // "forcing value to bool 'true' or 'false' (performance warning)"
|
||||
#endif
|
||||
|
||||
#include <tinygettext/tinygettext.hpp>
|
||||
#include <tinygettext/po_parser.hpp>
|
||||
#include <tinygettext/log.hpp>
|
||||
|
||||
#if MSC_VERSION
|
||||
# pragma warning(pop)
|
||||
#endif
|
||||
|
||||
#endif // INCLUDED_TINYGETTEXT
|
||||
@@ -25,6 +25,7 @@
|
||||
#include "scriptinterface/FunctionWrapper.h"
|
||||
#include "scriptinterface/ScriptRequest.h"
|
||||
|
||||
#include <unicode/smpdtfmt.h>
|
||||
#include <ctime>
|
||||
#include <string>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user