Fix WinCE/MSVC2008 build errors related to std::lower_bound patches.
See QTBUG-33473 for more information about this compiler bug. Change-Id: I13b945350fdc38165c1515f0cdd75a53cf37cd6c Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
This commit is contained in:
parent
25f7cddcab
commit
774d74df91
@ -61,6 +61,11 @@ struct NameprepCaseFoldingEntry {
|
||||
ushort mapping[4];
|
||||
};
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
inline bool operator<(const NameprepCaseFoldingEntry &one, const NameprepCaseFoldingEntry &other)
|
||||
{ return one.uc < other.uc; }
|
||||
#endif
|
||||
|
||||
inline bool operator<(uint one, const NameprepCaseFoldingEntry &other)
|
||||
{ return one < other.uc; }
|
||||
|
||||
|
@ -742,6 +742,11 @@ static const struct XPMRGBData {
|
||||
{ QRGB(139,139, 0), "yellow4" },
|
||||
{ QRGB(154,205, 50), "yellowgreen" } };
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
inline bool operator<(const XPMRGBData &data1, const XPMRGBData &data2)
|
||||
{ return qstrcmp(data1.name, data2.name) < 0; }
|
||||
#endif
|
||||
|
||||
inline bool operator<(const char *name, const XPMRGBData &data)
|
||||
{ return qstrcmp(name, data.name) < 0; }
|
||||
inline bool operator<(const XPMRGBData &data, const char *name)
|
||||
|
@ -289,6 +289,11 @@ static const int rgbTblSize = sizeof(rgbTbl) / sizeof(RGBData);
|
||||
|
||||
#undef rgb
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
inline bool operator<(const RGBData &data1, const RGBData &data2)
|
||||
{ return qstrcmp(data1.name, data2.name) < 0; }
|
||||
#endif
|
||||
|
||||
inline bool operator<(const char *name, const RGBData &data)
|
||||
{ return qstrcmp(name, data.name) < 0; }
|
||||
inline bool operator<(const RGBData &data, const char *name)
|
||||
|
@ -347,6 +347,13 @@ static const QCssKnownValue styleFeatures[NumKnownStyleFeatures - 1] = {
|
||||
{ "none", StyleFeature_None }
|
||||
};
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
Q_STATIC_GLOBAL_OPERATOR bool operator<(const QCssKnownValue &prop1, const QCssKnownValue &prop2)
|
||||
{
|
||||
return QString::compare(QString::fromLatin1(prop1.name), QLatin1String(prop2.name), Qt::CaseInsensitive) < 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
Q_STATIC_GLOBAL_OPERATOR bool operator<(const QString &name, const QCssKnownValue &prop)
|
||||
{
|
||||
return QString::compare(name, QLatin1String(prop.name), Qt::CaseInsensitive) < 0;
|
||||
|
@ -125,6 +125,11 @@ struct AGLEntry {
|
||||
unsigned short index;
|
||||
};
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
inline bool operator<(AGLEntry entry1, AGLEntry entry2)
|
||||
{ return entry1.uc < entry2.uc; }
|
||||
#endif
|
||||
|
||||
inline bool operator<(unsigned short uc, AGLEntry entry)
|
||||
{ return uc < entry.uc; }
|
||||
inline bool operator<(AGLEntry entry, unsigned short uc)
|
||||
|
@ -324,6 +324,13 @@ static const struct QTextHtmlEntity { const char *name; quint16 code; } entities
|
||||
{ "zwnj", 0x200c }
|
||||
};
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
bool operator<(const QTextHtmlEntity &entity1, const QTextHtmlEntity &entity2)
|
||||
{
|
||||
return QLatin1String(entity1.name) < QLatin1String(entity2.name);
|
||||
}
|
||||
#endif
|
||||
|
||||
Q_STATIC_GLOBAL_OPERATOR bool operator<(const QString &entityStr, const QTextHtmlEntity &entity)
|
||||
{
|
||||
return entityStr < QLatin1String(entity.name);
|
||||
@ -443,6 +450,12 @@ static const QTextHtmlElement elements[Html_NumElements]= {
|
||||
{ "var", Html_var, QTextHtmlElement::DisplayInline },
|
||||
};
|
||||
|
||||
#if defined(Q_CC_MSVC) && _MSC_VER < 1600
|
||||
Q_STATIC_GLOBAL_OPERATOR bool operator<(const QTextHtmlElement &e1, const QTextHtmlElement &e2)
|
||||
{
|
||||
return QLatin1String(e1.name) < QLatin1String(e2.name);
|
||||
}
|
||||
#endif
|
||||
|
||||
Q_STATIC_GLOBAL_OPERATOR bool operator<(const QString &str, const QTextHtmlElement &e)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user