Commit a666a8b9 authored by Johnny Jazeix's avatar Johnny Jazeix Committed by Mathieu Faverge

use constBegin/constEnd instead of cbegin/cend to be Qt4 compliant

parent 954372e4
...@@ -307,14 +307,8 @@ Palette *Session::get_palette(const std::string &type, const std::string &palett ...@@ -307,14 +307,8 @@ Palette *Session::get_palette(const std::string &type, const std::string &palett
p = new Palette(string(type+"/"+palette_name)); p = new Palette(string(type+"/"+palette_name));
*where_from = p; *where_from = p;
#if defined(USE_QT5) for(QMap<QString, QVariant>::const_iterator it = qmap.constBegin() ;
for(QMap<QString, QVariant>::const_iterator it = qmap.cbegin() ; it != qmap.constEnd() ; ++ it) {
it != qmap.cend() ; ++ it)
#else
for(QMap<QString, QVariant>::const_iterator it = qmap.begin() ;
it != qmap.end() ; ++ it)
#endif
{
const QColor qc = it.value().value<QColor>(); const QColor qc = it.value().value<QColor>();
Color c = Color(qc.red()/255., qc.green()/255., qc.blue()/255.); Color c = Color(qc.red()/255., qc.green()/255., qc.blue()/255.);
p->add_state(it.key().toStdString(), c, qc.alpha()==255.); p->add_state(it.key().toStdString(), c, qc.alpha()==255.);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment