2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Improve string encoding.

This commit is contained in:
John Preston
2017-11-15 19:02:50 +04:00
parent 7fdeab829f
commit 5a159d0204
4 changed files with 36 additions and 28 deletions

View File

@@ -488,16 +488,6 @@ enum DBIPeerReportSpamStatus {
dbiprsRequesting = 5, // requesting the cloud setting right now
};
template <int Size>
inline QString strMakeFromLetters(const uint32 (&letters)[Size]) {
QString result;
result.reserve(Size);
for (int32 i = 0; i < Size; ++i) {
result.push_back(QChar((((letters[i] >> 16) & 0xFF) << 8) | (letters[i] & 0xFF)));
}
return result;
}
class MimeType {
public:
enum class Known {