From 6213a065fe389c83eb5e9fdab42c95b3ff15c59d Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Mon, 4 Aug 2014 19:09:02 -0500 Subject: [PATCH] Clean up a couple of build warnings --- common/config_file.c | 6 +----- config/qtcurveconfig.cpp | 12 +++++++----- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/common/config_file.c b/common/config_file.c index aa1c289..91a9108 100644 --- a/common/config_file.c +++ b/common/config_file.c @@ -964,12 +964,8 @@ static bool readBoolEntry(TQtCConfig &cfg, const TQString &key, bool def) static void readDoubleList(TQtCConfig &cfg, const char *key, double *list, int count) { -#if ( (0x039999 >= 0x040000)) - TQStringList strings(readStringEntry(cfg, key).split(',', TQString::SkipEmptyParts)); -#else TQStringList strings(TQStringList::split(',', readStringEntry(cfg, key))); -#endif - bool ok(count==strings.size()); + bool ok(count==(int)strings.size()); if(ok) { diff --git a/config/qtcurveconfig.cpp b/config/qtcurveconfig.cpp index 4eccf69..64ffcae 100644 --- a/config/qtcurveconfig.cpp +++ b/config/qtcurveconfig.cpp @@ -1137,15 +1137,17 @@ void QtCurveConfig::addGradStop() double pos(stopPosition->value()/100.0), val(stopValue->value()/100.0); - for(; it!=end; ++it) - if(equal(pos, (*it).pos)) - if(equal(val, (*it).val)) + for(; it!=end; ++it) { + if(equal(pos, (*it).pos)) { + if(equal(val, (*it).val)) { return; - else - { + } + else { (*cg).second.stops.erase(it); break; } + } + } unsigned int b4=(*cg).second.stops.size(); (*cg).second.stops.insert(GradientStop(pos, val));