diff --git a/Telegram/SourceFiles/application.cpp b/Telegram/SourceFiles/application.cpp index 0851cc946..11602af75 100644 --- a/Telegram/SourceFiles/application.cpp +++ b/Telegram/SourceFiles/application.cpp @@ -30,6 +30,7 @@ Copyright (c) 2014-2017 John Preston, https://desktop.telegram.org namespace { +// @todo are there no other ways to get/set hex? QChar _toHex(ushort v) { v = v & 0x000F; return QChar::fromLatin1((v >= 10) ? ('a' + (v - 10)) : ('0' + v)); @@ -38,6 +39,7 @@ ushort _fromHex(QChar c) { return ((c.unicode() >= uchar('a')) ? (c.unicode() - uchar('a') + 10) : (c.unicode() - uchar('0'))) & 0x000F; } +// @todo urlencode/decode functions might help here?? QString _escapeTo7bit(const QString &str) { QString result; result.reserve(str.size() * 2); diff --git a/Telegram/SourceFiles/base/algorithm.h b/Telegram/SourceFiles/base/algorithm.h index 44188b05e..e3aafda87 100644 --- a/Telegram/SourceFiles/base/algorithm.h +++ b/Telegram/SourceFiles/base/algorithm.h @@ -22,6 +22,7 @@ Copyright (c) 2014-2017 John Preston, https://desktop.telegram.org namespace base { +// @todo use ranges-v3 here template decltype(auto) for_each(Range &&range, Method &&method) { return std::for_each( diff --git a/Telegram/SourceFiles/base/build_config.h b/Telegram/SourceFiles/base/build_config.h index 173163038..3bf067451 100644 --- a/Telegram/SourceFiles/base/build_config.h +++ b/Telegram/SourceFiles/base/build_config.h @@ -22,7 +22,7 @@ Copyright (c) 2014-2017 John Preston, https://desktop.telegram.org #include -// thanks Chromium +// thanks Chromium - @todo replace this with cmake-generated config file #if defined(__APPLE__) #define OS_MAC 1 diff --git a/Telegram/SourceFiles/base/weak_unique_ptr.h b/Telegram/SourceFiles/base/weak_unique_ptr.h index dd74f6d43..7ae74f12f 100644 --- a/Telegram/SourceFiles/base/weak_unique_ptr.h +++ b/Telegram/SourceFiles/base/weak_unique_ptr.h @@ -20,6 +20,8 @@ Copyright (c) 2014-2017 John Preston, https://desktop.telegram.org */ #pragma once +// @todo replace this with std::experimental::observer_ptr + namespace base { class enable_weak_from_this; diff --git a/Telegram/SourceFiles/core/utils.h b/Telegram/SourceFiles/core/utils.h index 4dc88ae5d..bebadbb32 100644 --- a/Telegram/SourceFiles/core/utils.h +++ b/Telegram/SourceFiles/core/utils.h @@ -294,7 +294,7 @@ void finish(); } -using TimeMs = qint64; +using TimeMs = qint64; // @todo use std::chrono::milliseconds bool checkms(); // returns true if time has changed TimeMs getms(bool checked = false); @@ -418,7 +418,7 @@ inline QString fromUtf8Safe(const QByteArray &str) { static const QRegularExpression::PatternOptions reMultiline(QRegularExpression::DotMatchesEverythingOption | QRegularExpression::MultilineOption); template -inline T snap(const T &v, const T &_min, const T &_max) { +inline T snap(const T &v, const T &_min, const T &_max) { // @todo std::clamp() return (v < _min) ? _min : ((v > _max) ? _max : v); } diff --git a/Telegram/SourceFiles/overviewwidget.h b/Telegram/SourceFiles/overviewwidget.h index ba905fc7e..250d1179e 100644 --- a/Telegram/SourceFiles/overviewwidget.h +++ b/Telegram/SourceFiles/overviewwidget.h @@ -336,7 +336,7 @@ public: _inGrab = true; resizeEvent(0); } - void grapWithoutTopBarShadow(); + void grapWithoutTopBarShadow();//@fixme grab? void grabFinish() override; void rpcClear() override { _inner->rpcClear(); diff --git a/Telegram/ThirdParty/emoji_suggestions/emoji_suggestions.h b/Telegram/ThirdParty/emoji_suggestions/emoji_suggestions.h index d13ce0efa..b13f0608e 100644 --- a/Telegram/ThirdParty/emoji_suggestions/emoji_suggestions.h +++ b/Telegram/ThirdParty/emoji_suggestions/emoji_suggestions.h @@ -27,6 +27,7 @@ namespace Emoji { static_assert(sizeof(char16_t) == 2, "Bad UTF-16 character size."); +// @todo kill this off, use std::u16string instead class utf16string { public: utf16string() = default;