From 4f2dcef95299f2da628b30607021e8deb1d868b6 Mon Sep 17 00:00:00 2001 From: Thierry Bastian Date: Thu, 12 Nov 2009 11:47:11 +0100 Subject: Fixed a crash when configuring an audio effect with the Phonon dialog Task-number: QTBUG-5731 Reviewed-by: jan-arve --- src/3rdparty/phonon/phonon/effectwidget.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/3rdparty/phonon/phonon/effectwidget.cpp b/src/3rdparty/phonon/phonon/effectwidget.cpp index fb9cf6e..f8341e5 100644 --- a/src/3rdparty/phonon/phonon/effectwidget.cpp +++ b/src/3rdparty/phonon/phonon/effectwidget.cpp @@ -97,8 +97,9 @@ void EffectWidgetPrivate::autogenerateUi() Q_Q(EffectWidget); QVBoxLayout *mainLayout = new QVBoxLayout(q); mainLayout->setMargin(0); - for (int i = 0; i < effect->parameters().count(); ++i) { - const EffectParameter ¶ = effect->parameters().at(i); + const QList parameters = effect->parameters(); + for (int i = 0; i < parameters.count(); ++i) { + const EffectParameter ¶ = parameters.at(i); QVariant value = effect->parameterValue(para); QHBoxLayout *pLayout = new QHBoxLayout; mainLayout->addLayout(pLayout); -- cgit v0.12