if (e.attribute("type") == "simplekeyframe") {
QStringList kfrs = paramvalue.split(";");
for (int l = 0; l < kfrs.count(); l++) {
- QString fr = kfrs.at(l).section("=", 0, 0);
- double val = kfrs.at(l).section("=", 1, 1).toDouble();
+ QString fr = kfrs.at(l).section('=', 0, 0);
+ double val = kfrs.at(l).section('=', 1, 1).toDouble();
kfrs[l] = fr + ":" + QString::number((int)(val * fact));
}
e.setAttribute("keyframes", kfrs.join(";"));
void TrackView::slotUpdateTrackEffectState(int ix)
{
QList<HeaderTrack *> widgets = findChildren<HeaderTrack *>();
- if (ix >= widgets.count()) {
+ if (ix < 0 || ix >= widgets.count()) {
kDebug() << "ERROR, Trying to access a non existant track: " << ix;
return;
}