aboutsummaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorSupSuper2019-09-01 23:24:50 +0100
committerFilippos Karapetis2019-09-02 08:01:18 +0300
commit1c1cc91ad5ae2e67a33d7c7ae896f74153477ec5 (patch)
tree8b9246a697062af4c912b18c64885ecf2c5ac267 /common
parente6e70b2042d222b81498fc2cc6be2aa6d7655f39 (diff)
downloadscummvm-rg350-1c1cc91ad5ae2e67a33d7c7ae896f74153477ec5.tar.gz
scummvm-rg350-1c1cc91ad5ae2e67a33d7c7ae896f74153477ec5.tar.bz2
scummvm-rg350-1c1cc91ad5ae2e67a33d7c7ae896f74153477ec5.zip
COMMON: Don't include win32.h in common/encoding.h
Diffstat (limited to 'common')
-rw-r--r--common/encoding.h29
1 files changed, 11 insertions, 18 deletions
diff --git a/common/encoding.h b/common/encoding.h
index 8a77c81b08..2b079ad962 100644
--- a/common/encoding.h
+++ b/common/encoding.h
@@ -28,10 +28,6 @@
#include "common/system.h"
-#ifdef WIN32
-#include "backends/platform/sdl/win32/win32.h"
-#endif
-
namespace Common {
/**
@@ -40,9 +36,6 @@ namespace Common {
* ScummVM is compiled with or without iconv.
*/
class Encoding {
-#ifdef WIN32
- friend char *OSystem_Win32::convertEncoding(const char*, const char *, const char *, size_t);
-#endif
public:
/**
* Constructs everything needed for the conversion between 2 encodings
@@ -104,6 +97,17 @@ class Encoding {
* @param to The encoding, to convert to
*/
void setTo(const String &to) {_to = to;};
+
+ /**
+ * Switches the endianity of a string.
+ *
+ * @param string Array containing the characters of a string.
+ * @param length Length of the string in bytes
+ * @param bitCount Number of bits used for each character.
+ *
+ * @return Array of characters with the opposite endianity
+ */
+ static char *switchEndian(const char *string, int length, int bitCount);
private:
/** The encoding, which is currently being converted to */
@@ -211,17 +215,6 @@ class Encoding {
* @return Transliterated string in UTF-32 (must be freed) or nullptr on fail.
*/
static uint32 *transliterateUTF32(const uint32 *string, size_t length);
-
- /**
- * Switches the endianity of a string.
- *
- * @param string Array containing the characters of a string.
- * @param length Length of the string in bytes
- * @param bitCount Number of bits used for each character.
- *
- * @return Array of characters with the opposite endianity
- */
- static char *switchEndian(const char *string, int length, int bitCount);
};
}