mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-11 15:56:17 -07:00
Fix compilation on MSVC2013 by moving unicode strings to
"unicodestrings.h". Closes #3059.
This commit is contained in:
parent
bc97208516
commit
e739e81205
8 changed files with 187 additions and 99 deletions
|
@ -67,6 +67,7 @@ const int UNLEN = 256;
|
|||
#endif // DISABLE_GUI
|
||||
|
||||
#include "core/utils/string.h"
|
||||
#include "core/unicodestrings.h"
|
||||
#include "misc.h"
|
||||
|
||||
static struct { const char *source; const char *comment; } units[] = {
|
||||
|
@ -345,7 +346,7 @@ QString Utils::Misc::bcLinkToMagnet(QString bc_link)
|
|||
QString Utils::Misc::userFriendlyDuration(qlonglong seconds)
|
||||
{
|
||||
if (seconds < 0 || seconds >= MAX_ETA)
|
||||
return QString::fromUtf8("∞");
|
||||
return QString::fromUtf8(C_INFINITY);
|
||||
if (seconds == 0)
|
||||
return "0";
|
||||
if (seconds < 60)
|
||||
|
@ -361,7 +362,7 @@ QString Utils::Misc::userFriendlyDuration(qlonglong seconds)
|
|||
hours = hours - days * 24;
|
||||
if (days < 100)
|
||||
return QCoreApplication::translate("misc", "%1d %2h", "e.g: 2days 10hours").arg(QString::number(days)).arg(QString::number(hours));
|
||||
return QString::fromUtf8("∞");
|
||||
return QString::fromUtf8(C_INFINITY);
|
||||
}
|
||||
|
||||
QString Utils::Misc::getUserIDString()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue