From 3057ec0447943fe022b66a2d19e13d94f9183a7c Mon Sep 17 00:00:00 2001 From: Robin Burchell Date: Thu, 5 Jan 2017 20:27:53 +0100 Subject: Port existing qmlInfo callers to qmlWarning Now that qmlInfo actually reports info messages, we want to change existing callers to use warning-level messages to preserve the original message level. This was done through: perl -p -i -e "s/qmlInfo\(/qmlWarning\(/" **/*.{cpp,h,qdoc} .. with a little care taken to only add the hunks that should be changed. Change-Id: I511cee11ce0a26ec1048cd2b84c7536b812a0d89 Reviewed-by: Simon Hausmann --- src/imports/statemachine/signaltransition.cpp | 2 +- src/imports/statemachine/state.cpp | 2 +- src/imports/statemachine/statemachine.cpp | 2 +- src/imports/statemachine/timeouttransition.cpp | 2 +- src/imports/xmllistmodel/qqmlxmllistmodel.cpp | 8 ++-- src/particles/qquickimageparticle.cpp | 8 ++-- src/particles/qquickmaskextruder.cpp | 2 +- src/qml/qml/qqmlabstractbinding.cpp | 2 +- src/qml/qml/qqmlboundsignal.cpp | 4 +- src/qml/qml/qqmlcomponent.cpp | 4 +- src/qml/qml/qqmlcustomparser.cpp | 2 +- src/qml/qml/qqmlloggingcategory.cpp | 4 +- src/qml/types/qqmlbind.cpp | 4 +- src/qml/types/qqmlconnections.cpp | 2 +- src/qml/types/qqmldelegatemodel.cpp | 60 +++++++++++++------------- src/qml/types/qqmllistmodel.cpp | 40 ++++++++--------- src/qml/types/qqmlobjectmodel.cpp | 6 +-- src/quick/items/context2d/qquickcanvasitem.cpp | 16 +++---- src/quick/items/qquickanchors.cpp | 34 +++++++-------- src/quick/items/qquickanimatedimage.cpp | 2 +- src/quick/items/qquickanimatedsprite.cpp | 2 +- src/quick/items/qquickborderimage.cpp | 2 +- src/quick/items/qquickdrag.cpp | 12 +++--- src/quick/items/qquickflipable.cpp | 4 +- src/quick/items/qquickimagebase.cpp | 2 +- src/quick/items/qquickitem.cpp | 8 ++-- src/quick/items/qquickitemanimation.cpp | 12 +++--- src/quick/items/qquickitemview.cpp | 4 +- src/quick/items/qquickloader.cpp | 2 +- src/quick/items/qquickpathview.cpp | 2 +- src/quick/items/qquickpositioners.cpp | 8 ++-- src/quick/items/qquickrepeater.cpp | 2 +- src/quick/items/qquickspriteengine.cpp | 10 ++--- src/quick/items/qquickspritesequence.cpp | 2 +- src/quick/items/qquickstateoperations.cpp | 8 ++-- src/quick/items/qquicktext.cpp | 2 +- src/quick/items/qquicktextdocument.cpp | 2 +- src/quick/items/qquicktextedit.cpp | 2 +- src/quick/items/qquicktextinput.cpp | 2 +- src/quick/items/qquicktextutil.cpp | 4 +- src/quick/util/qquickanimation.cpp | 18 ++++---- src/quick/util/qquickanimationcontroller.cpp | 2 +- src/quick/util/qquickbehavior.cpp | 2 +- src/quick/util/qquickfontloader.cpp | 2 +- src/quick/util/qquickpropertychanges.cpp | 4 +- src/quick/util/qquickstatechangescript.cpp | 2 +- src/quick/util/qquickstategroup.cpp | 2 +- 47 files changed, 165 insertions(+), 165 deletions(-) (limited to 'src') diff --git a/src/imports/statemachine/signaltransition.cpp b/src/imports/statemachine/signaltransition.cpp index 2e6381fc08..44fbf69431 100644 --- a/src/imports/statemachine/signaltransition.cpp +++ b/src/imports/statemachine/signaltransition.cpp @@ -127,7 +127,7 @@ void SignalTransition::setSignal(const QJSValue &signal) Q_ASSERT(sender); signalMethod = sender->metaObject()->method(signalObject->signalIndex()); } else { - qmlInfo(this) << tr("Specified signal does not exist."); + qmlWarning(this) << tr("Specified signal does not exist."); return; } diff --git a/src/imports/statemachine/state.cpp b/src/imports/statemachine/state.cpp index 09d246cc1e..f1294b0de0 100644 --- a/src/imports/statemachine/state.cpp +++ b/src/imports/statemachine/state.cpp @@ -54,7 +54,7 @@ void State::componentComplete() static bool once = false; if (!once) { once = true; - qmlInfo(this) << "No top level StateMachine found. Nothing will run without a StateMachine."; + qmlWarning(this) << "No top level StateMachine found. Nothing will run without a StateMachine."; } } } diff --git a/src/imports/statemachine/statemachine.cpp b/src/imports/statemachine/statemachine.cpp index 76de01fe94..a9ea5f7a95 100644 --- a/src/imports/statemachine/statemachine.cpp +++ b/src/imports/statemachine/statemachine.cpp @@ -69,7 +69,7 @@ void StateMachine::setRunning(bool running) void StateMachine::componentComplete() { if (QStateMachine::initialState() == NULL && childMode() == QState::ExclusiveStates) - qmlInfo(this) << "No initial state set for StateMachine"; + qmlWarning(this) << "No initial state set for StateMachine"; // Everything is proper setup, now start the state-machine if we got // asked to do so. diff --git a/src/imports/statemachine/timeouttransition.cpp b/src/imports/statemachine/timeouttransition.cpp index 4bb1df3c28..0d208b919b 100644 --- a/src/imports/statemachine/timeouttransition.cpp +++ b/src/imports/statemachine/timeouttransition.cpp @@ -72,7 +72,7 @@ void TimeoutTransition::componentComplete() { QState *state = qobject_cast(parent()); if (!state) { - qmlInfo(this) << "Parent needs to be a State"; + qmlWarning(this) << "Parent needs to be a State"; return; } diff --git a/src/imports/xmllistmodel/qqmlxmllistmodel.cpp b/src/imports/xmllistmodel/qqmlxmllistmodel.cpp index 4306f477e9..61c8665a14 100644 --- a/src/imports/xmllistmodel/qqmlxmllistmodel.cpp +++ b/src/imports/xmllistmodel/qqmlxmllistmodel.cpp @@ -596,7 +596,7 @@ void QQuickXmlListModelPrivate::append_role(QQmlListPropertyd_func()->roleObjects.count(); _this->d_func()->roleObjects.append(role); if (_this->d_func()->roleNames.contains(role->name())) { - qmlInfo(role) << QQuickXmlListModel::tr("\"%1\" duplicates a previous role name and will be disabled.").arg(role->name()); + qmlWarning(role) << QQuickXmlListModel::tr("\"%1\" duplicates a previous role name and will be disabled.").arg(role->name()); return; } _this->d_func()->roles.insert(i, _this->d_func()->highestRole); @@ -847,7 +847,7 @@ void QQuickXmlListModel::setQuery(const QString &query) { Q_D(QQuickXmlListModel); if (!query.startsWith(QLatin1Char('/'))) { - qmlInfo(this) << QCoreApplication::translate("QQuickXmlRoleList", "An XmlListModel query must start with '/' or \"//\""); + qmlWarning(this) << QCoreApplication::translate("QQuickXmlRoleList", "An XmlListModel query must start with '/' or \"//\""); return; } @@ -1136,11 +1136,11 @@ void QQuickXmlListModel::queryError(void* object, const QString& error) Q_D(QQuickXmlListModel); for (int i=0; iroleObjects.count(); i++) { if (d->roleObjects.at(i) == static_cast(object)) { - qmlInfo(d->roleObjects.at(i)) << QQuickXmlListModel::tr("invalid query: \"%1\"").arg(error); + qmlWarning(d->roleObjects.at(i)) << QQuickXmlListModel::tr("invalid query: \"%1\"").arg(error); return; } } - qmlInfo(this) << QQuickXmlListModel::tr("invalid query: \"%1\"").arg(error); + qmlWarning(this) << QQuickXmlListModel::tr("invalid query: \"%1\"").arg(error); } void QQuickXmlListModel::queryCompleted(const QQuickXmlQueryResult &result) diff --git a/src/particles/qquickimageparticle.cpp b/src/particles/qquickimageparticle.cpp index 60cbf6175d..e82f17becd 100644 --- a/src/particles/qquickimageparticle.cpp +++ b/src/particles/qquickimageparticle.cpp @@ -1347,21 +1347,21 @@ void QQuickImageParticle::finishBuildParticleNodes(QSGNode** node) if (m_colorTable->pix.isReady()) colortable = m_colorTable->pix.image(); else - qmlInfo(this) << "Error loading color table: " << m_colorTable->pix.error(); + qmlWarning(this) << "Error loading color table: " << m_colorTable->pix.error(); } if (m_sizeTable) { if (m_sizeTable->pix.isReady()) sizetable = m_sizeTable->pix.image(); else - qmlInfo(this) << "Error loading size table: " << m_sizeTable->pix.error(); + qmlWarning(this) << "Error loading size table: " << m_sizeTable->pix.error(); } if (m_opacityTable) { if (m_opacityTable->pix.isReady()) opacitytable = m_opacityTable->pix.image(); else - qmlInfo(this) << "Error loading opacity table: " << m_opacityTable->pix.error(); + qmlWarning(this) << "Error loading opacity table: " << m_opacityTable->pix.error(); } if (colortable.isNull()){//###Goes through image just for this @@ -1383,7 +1383,7 @@ void QQuickImageParticle::finishBuildParticleNodes(QSGNode** node) if (!imageLoaded) { if (!m_image || !m_image->pix.isReady()) { if (m_image) - qmlInfo(this) << m_image->pix.error(); + qmlWarning(this) << m_image->pix.error(); delete m_material; return; } diff --git a/src/particles/qquickmaskextruder.cpp b/src/particles/qquickmaskextruder.cpp index 66d5808c33..7564fa6739 100644 --- a/src/particles/qquickmaskextruder.cpp +++ b/src/particles/qquickmaskextruder.cpp @@ -94,7 +94,7 @@ void QQuickMaskExtruder::startMaskLoading() void QQuickMaskExtruder::finishMaskLoading() { if (m_pix.isError()) - qmlInfo(this) << m_pix.error(); + qmlWarning(this) << m_pix.error(); } QPointF QQuickMaskExtruder::extrude(const QRectF &r) diff --git a/src/qml/qml/qqmlabstractbinding.cpp b/src/qml/qml/qqmlabstractbinding.cpp index 39d609454f..b1c320afd4 100644 --- a/src/qml/qml/qqmlabstractbinding.cpp +++ b/src/qml/qml/qqmlabstractbinding.cpp @@ -191,7 +191,7 @@ void QQmlAbstractBinding::removeFromObject() void QQmlAbstractBinding::printBindingLoopError(QQmlProperty &prop) { - qmlInfo(prop.object()) << QString(QLatin1String("Binding loop detected for property \"%1\"")).arg(prop.name()); + qmlWarning(prop.object()) << QString(QLatin1String("Binding loop detected for property \"%1\"")).arg(prop.name()); } QString QQmlAbstractBinding::expression() const diff --git a/src/qml/qml/qqmlboundsignal.cpp b/src/qml/qml/qqmlboundsignal.cpp index 254d5e1907..d5b2067094 100644 --- a/src/qml/qml/qqmlboundsignal.cpp +++ b/src/qml/qml/qqmlboundsignal.cpp @@ -91,7 +91,7 @@ QQmlBoundSignalExpression::QQmlBoundSignalExpression(QObject *target, int index, function += QQmlPropertyCache::signalParameterStringForJS(v4, signal.parameterNames(), &error); if (!error.isEmpty()) { - qmlInfo(scopeObject()) << error; + qmlWarning(scopeObject()) << error; return; } } else @@ -129,7 +129,7 @@ QQmlBoundSignalExpression::QQmlBoundSignalExpression(QObject *target, int index, QString error; QQmlPropertyCache::signalParameterStringForJS(engine, signalParameters, &error); if (!error.isEmpty()) { - qmlInfo(scopeObject()) << error; + qmlWarning(scopeObject()) << error; return; } runtimeFunction->updateInternalClass(engine, signalParameters); diff --git a/src/qml/qml/qqmlcomponent.cpp b/src/qml/qml/qqmlcomponent.cpp index 6ebcd142fb..936313768a 100644 --- a/src/qml/qml/qqmlcomponent.cpp +++ b/src/qml/qml/qqmlcomponent.cpp @@ -1244,7 +1244,7 @@ void QQmlComponent::createObject(QQmlV4Function *args) if (args->length() >= 2) { QV4::ScopedValue v(scope, (*args)[1]); if (!v->as() || v->as()) { - qmlInfo(this) << tr("createObject: value is not an object"); + qmlWarning(this) << tr("createObject: value is not an object"); args->setReturnValue(QV4::Encode::null()); return; } @@ -1361,7 +1361,7 @@ void QQmlComponent::incubateObject(QQmlV4Function *args) QV4::ScopedValue v(scope, (*args)[1]); if (v->isNull()) { } else if (!v->as() || v->as()) { - qmlInfo(this) << tr("createObject: value is not an object"); + qmlWarning(this) << tr("createObject: value is not an object"); args->setReturnValue(QV4::Encode::null()); return; } else { diff --git a/src/qml/qml/qqmlcustomparser.cpp b/src/qml/qml/qqmlcustomparser.cpp index 85c91a592a..0b0bbef795 100644 --- a/src/qml/qml/qqmlcustomparser.cpp +++ b/src/qml/qml/qqmlcustomparser.cpp @@ -83,7 +83,7 @@ QT_BEGIN_NAMESPACE by \a data, which is a block of data previously returned by a call to compile(). - Errors should be reported using qmlInfo(object). + Errors should be reported using qmlWarning(object). The \a object will be an instance of the TypeClass specified by QML_REGISTER_CUSTOM_TYPE. */ diff --git a/src/qml/qml/qqmlloggingcategory.cpp b/src/qml/qml/qqmlloggingcategory.cpp index 70e59db07b..764b874131 100644 --- a/src/qml/qml/qqmlloggingcategory.cpp +++ b/src/qml/qml/qqmlloggingcategory.cpp @@ -112,13 +112,13 @@ void QQmlLoggingCategory::componentComplete() { m_initialized = true; if (m_name.isNull()) - qmlInfo(this) << QLatin1String("Declaring the name of the LoggingCategory is mandatory and cannot be changed later !"); + qmlWarning(this) << QLatin1String("Declaring the name of the LoggingCategory is mandatory and cannot be changed later !"); } void QQmlLoggingCategory::setName(const QString &name) { if (m_initialized) { - qmlInfo(this) << QLatin1String("The name of a LoggingCategory cannot be changed after the Item is created"); + qmlWarning(this) << QLatin1String("The name of a LoggingCategory cannot be changed after the Item is created"); return; } diff --git a/src/qml/types/qqmlbind.cpp b/src/qml/types/qqmlbind.cpp index a545fe57ca..2ded9c13c8 100644 --- a/src/qml/types/qqmlbind.cpp +++ b/src/qml/types/qqmlbind.cpp @@ -82,12 +82,12 @@ void QQmlBindPrivate::validate(QObject *binding) const return; if (!prop.isValid()) { - qmlInfo(binding) << "Property '" << propName << "' does not exist on " << QQmlMetaType::prettyTypeName(obj) << "."; + qmlWarning(binding) << "Property '" << propName << "' does not exist on " << QQmlMetaType::prettyTypeName(obj) << "."; return; } if (!prop.isWritable()) { - qmlInfo(binding) << "Property '" << propName << "' on " << QQmlMetaType::prettyTypeName(obj) << " is read-only."; + qmlWarning(binding) << "Property '" << propName << "' on " << QQmlMetaType::prettyTypeName(obj) << " is read-only."; return; } } diff --git a/src/qml/types/qqmlconnections.cpp b/src/qml/types/qqmlconnections.cpp index 2aed4d9972..864ecf54dd 100644 --- a/src/qml/types/qqmlconnections.cpp +++ b/src/qml/types/qqmlconnections.cpp @@ -295,7 +295,7 @@ void QQmlConnections::connectSignals() d->boundsignals += signal; } else { if (!d->ignoreUnknownSignals) - qmlInfo(this) << tr("Cannot assign to non-existent property \"%1\"").arg(propName); + qmlWarning(this) << tr("Cannot assign to non-existent property \"%1\"").arg(propName); } } } diff --git a/src/qml/types/qqmldelegatemodel.cpp b/src/qml/types/qqmldelegatemodel.cpp index be10b270ae..c635ccf79c 100644 --- a/src/qml/types/qqmldelegatemodel.cpp +++ b/src/qml/types/qqmldelegatemodel.cpp @@ -310,7 +310,7 @@ void QQmlDelegateModel::componentComplete() --d->m_groupCount; --i; } else if (name.at(0).isUpper()) { - qmlInfo(d->m_groups[i]) << QQmlDelegateModelGroup::tr("Group names must start with a lower case letter"); + qmlWarning(d->m_groups[i]) << QQmlDelegateModelGroup::tr("Group names must start with a lower case letter"); d->m_groups[i] = d->m_groups[d->m_groupCount - 1]; --d->m_groupCount; --i; @@ -404,7 +404,7 @@ void QQmlDelegateModel::setDelegate(QQmlComponent *delegate) { Q_D(QQmlDelegateModel); if (d->m_transaction) { - qmlInfo(this) << tr("The delegate of a DelegateModel cannot be changed within onUpdated."); + qmlWarning(this) << tr("The delegate of a DelegateModel cannot be changed within onUpdated."); return; } bool wasValid = d->m_delegate != 0; @@ -610,7 +610,7 @@ void QQmlDelegateModelPrivate::group_append( if (d->m_complete) return; if (d->m_groupCount == Compositor::MaximumGroupCount) { - qmlInfo(d->q_func()) << QQmlDelegateModel::tr("The maximum number of supported DelegateModelGroups is 8"); + qmlWarning(d->q_func()) << QQmlDelegateModel::tr("The maximum number of supported DelegateModelGroups is 8"); return; } d->m_groups[d->m_groupCount] = group; @@ -719,7 +719,7 @@ void QQmlDelegateModel::setFilterGroup(const QString &group) Q_D(QQmlDelegateModel); if (d->m_transaction) { - qmlInfo(this) << tr("The group of a DelegateModel cannot be changed within onChanged"); + qmlWarning(this) << tr("The group of a DelegateModel cannot be changed within onChanged"); return; } @@ -889,7 +889,7 @@ void QQmlDelegateModelPrivate::incubatorStatusChanged(QQDMIncubationTask *incuba emitCreatedItem(incubationTask, cacheItem->object); cacheItem->releaseObject(); } else if (status == QQmlIncubator::Error) { - qmlInfo(q, m_delegate->errors()) << "Error creating delegate"; + qmlWarning(q, m_delegate->errors()) << "Error creating delegate"; } if (!cacheItem->isObjectReferenced()) { @@ -2459,7 +2459,7 @@ QQmlV4Handle QQmlDelegateModelGroup::get(int index) if (!model->m_context || !model->m_context->isValid()) { return QQmlV4Handle(QV4::Encode::undefined()); } else if (index < 0 || index >= model->m_compositor.count(d->group)) { - qmlInfo(this) << tr("get: index out of range"); + qmlWarning(this) << tr("get: index out of range"); return QQmlV4Handle(QV4::Encode::undefined()); } @@ -2552,7 +2552,7 @@ void QQmlDelegateModelGroup::insert(QQmlV4Function *args) QV4::ScopedValue v(scope, (*args)[i]); if (d->parseIndex(v, &index, &group)) { if (index < 0 || index > model->m_compositor.count(group)) { - qmlInfo(this) << tr("insert: index out of range"); + qmlWarning(this) << tr("insert: index out of range"); return; } if (++i == args->length()) @@ -2637,7 +2637,7 @@ void QQmlDelegateModelGroup::create(QQmlV4Function *args) } } if (index < 0 || index >= model->m_compositor.count(group)) { - qmlInfo(this) << tr("create: index out of range"); + qmlWarning(this) << tr("create: index out of range"); return; } @@ -2690,22 +2690,22 @@ void QQmlDelegateModelGroup::resolve(QQmlV4Function *args) QV4::ScopedValue v(scope, (*args)[0]); if (d->parseIndex(v, &from, &fromGroup)) { if (from < 0 || from >= model->m_compositor.count(fromGroup)) { - qmlInfo(this) << tr("resolve: from index out of range"); + qmlWarning(this) << tr("resolve: from index out of range"); return; } } else { - qmlInfo(this) << tr("resolve: from index invalid"); + qmlWarning(this) << tr("resolve: from index invalid"); return; } v = (*args)[1]; if (d->parseIndex(v, &to, &toGroup)) { if (to < 0 || to >= model->m_compositor.count(toGroup)) { - qmlInfo(this) << tr("resolve: to index out of range"); + qmlWarning(this) << tr("resolve: to index out of range"); return; } } else { - qmlInfo(this) << tr("resolve: to index invalid"); + qmlWarning(this) << tr("resolve: to index invalid"); return; } @@ -2713,11 +2713,11 @@ void QQmlDelegateModelGroup::resolve(QQmlV4Function *args) Compositor::iterator toIt = model->m_compositor.find(toGroup, to); if (!fromIt->isUnresolved()) { - qmlInfo(this) << tr("resolve: from is not an unresolved item"); + qmlWarning(this) << tr("resolve: from is not an unresolved item"); return; } if (!toIt->list) { - qmlInfo(this) << tr("resolve: to is not a model item"); + qmlWarning(this) << tr("resolve: to is not a model item"); return; } @@ -2787,7 +2787,7 @@ void QQmlDelegateModelGroup::remove(QQmlV4Function *args) QV4::Scope scope(args->v4engine()); QV4::ScopedValue v(scope, (*args)[0]); if (!d->parseIndex(v, &index, &group)) { - qmlInfo(this) << tr("remove: invalid index"); + qmlWarning(this) << tr("remove: invalid index"); return; } @@ -2799,11 +2799,11 @@ void QQmlDelegateModelGroup::remove(QQmlV4Function *args) QQmlDelegateModelPrivate *model = QQmlDelegateModelPrivate::get(d->model); if (index < 0 || index >= model->m_compositor.count(group)) { - qmlInfo(this) << tr("remove: index out of range"); + qmlWarning(this) << tr("remove: index out of range"); } else if (count != 0) { Compositor::iterator it = model->m_compositor.find(group, index); if (count < 0 || count > model->m_compositor.count(d->group) - it.index[d->group]) { - qmlInfo(this) << tr("remove: invalid count"); + qmlWarning(this) << tr("remove: invalid count"); } else { model->removeGroups(it, count, d->group, 1 << d->group); } @@ -2858,11 +2858,11 @@ void QQmlDelegateModelGroup::addGroups(QQmlV4Function *args) QQmlDelegateModelPrivate *model = QQmlDelegateModelPrivate::get(d->model); if (index < 0 || index >= model->m_compositor.count(group)) { - qmlInfo(this) << tr("addGroups: index out of range"); + qmlWarning(this) << tr("addGroups: index out of range"); } else if (count != 0) { Compositor::iterator it = model->m_compositor.find(group, index); if (count < 0 || count > model->m_compositor.count(d->group) - it.index[d->group]) { - qmlInfo(this) << tr("addGroups: invalid count"); + qmlWarning(this) << tr("addGroups: invalid count"); } else { model->addGroups(it, count, d->group, groups); } @@ -2888,11 +2888,11 @@ void QQmlDelegateModelGroup::removeGroups(QQmlV4Function *args) QQmlDelegateModelPrivate *model = QQmlDelegateModelPrivate::get(d->model); if (index < 0 || index >= model->m_compositor.count(group)) { - qmlInfo(this) << tr("removeGroups: index out of range"); + qmlWarning(this) << tr("removeGroups: index out of range"); } else if (count != 0) { Compositor::iterator it = model->m_compositor.find(group, index); if (count < 0 || count > model->m_compositor.count(d->group) - it.index[d->group]) { - qmlInfo(this) << tr("removeGroups: invalid count"); + qmlWarning(this) << tr("removeGroups: invalid count"); } else { model->removeGroups(it, count, d->group, groups); } @@ -2918,11 +2918,11 @@ void QQmlDelegateModelGroup::setGroups(QQmlV4Function *args) QQmlDelegateModelPrivate *model = QQmlDelegateModelPrivate::get(d->model); if (index < 0 || index >= model->m_compositor.count(group)) { - qmlInfo(this) << tr("setGroups: index out of range"); + qmlWarning(this) << tr("setGroups: index out of range"); } else if (count != 0) { Compositor::iterator it = model->m_compositor.find(group, index); if (count < 0 || count > model->m_compositor.count(d->group) - it.index[d->group]) { - qmlInfo(this) << tr("setGroups: invalid count"); + qmlWarning(this) << tr("setGroups: invalid count"); } else { model->setGroups(it, count, d->group, groups); } @@ -2957,13 +2957,13 @@ void QQmlDelegateModelGroup::move(QQmlV4Function *args) QV4::Scope scope(args->v4engine()); QV4::ScopedValue v(scope, (*args)[0]); if (!d->parseIndex(v, &from, &fromGroup)) { - qmlInfo(this) << tr("move: invalid from index"); + qmlWarning(this) << tr("move: invalid from index"); return; } v = (*args)[1]; if (!d->parseIndex(v, &to, &toGroup)) { - qmlInfo(this) << tr("move: invalid to index"); + qmlWarning(this) << tr("move: invalid to index"); return; } @@ -2976,11 +2976,11 @@ void QQmlDelegateModelGroup::move(QQmlV4Function *args) QQmlDelegateModelPrivate *model = QQmlDelegateModelPrivate::get(d->model); if (count < 0) { - qmlInfo(this) << tr("move: invalid count"); + qmlWarning(this) << tr("move: invalid count"); } else if (from < 0 || from + count > model->m_compositor.count(fromGroup)) { - qmlInfo(this) << tr("move: from index out of range"); + qmlWarning(this) << tr("move: from index out of range"); } else if (!model->m_compositor.verifyMoveTo(fromGroup, from, toGroup, to, count, d->group)) { - qmlInfo(this) << tr("move: to index out of range"); + qmlWarning(this) << tr("move: to index out of range"); } else if (count > 0) { QVector removes; QVector inserts; @@ -3038,7 +3038,7 @@ QString QQmlPartsModel::filterGroup() const void QQmlPartsModel::setFilterGroup(const QString &group) { if (QQmlDelegateModelPrivate::get(m_model)->m_transaction) { - qmlInfo(this) << tr("The group of a DelegateModel cannot be changed within onChanged"); + qmlWarning(this) << tr("The group of a DelegateModel cannot be changed within onChanged"); return; } @@ -3151,7 +3151,7 @@ QObject *QQmlPartsModel::object(int index, bool asynchronous) model->release(object); if (!model->m_delegateValidated) { if (object) - qmlInfo(model->m_delegate) << tr("Delegate component must be Package type."); + qmlWarning(model->m_delegate) << tr("Delegate component must be Package type."); model->m_delegateValidated = true; } diff --git a/src/qml/types/qqmllistmodel.cpp b/src/qml/types/qqmllistmodel.cpp index 1a2e4c7f6f..5e06455b26 100644 --- a/src/qml/types/qqmllistmodel.cpp +++ b/src/qml/types/qqmllistmodel.cpp @@ -99,7 +99,7 @@ const ListLayout::Role &ListLayout::getRoleOrCreate(const QString &key, Role::Da if (node) { const Role &r = *node->value; if (type != r.type) - qmlInfo(0) << QStringLiteral("Can't assign to existing role '%1' of different type [%2 -> %3]").arg(r.name).arg(roleTypeName(type)).arg(roleTypeName(r.type)); + qmlWarning(0) << QStringLiteral("Can't assign to existing role '%1' of different type [%2 -> %3]").arg(r.name).arg(roleTypeName(type)).arg(roleTypeName(r.type)); return r; } @@ -112,7 +112,7 @@ const ListLayout::Role &ListLayout::getRoleOrCreate(QV4::String *key, Role::Data if (node) { const Role &r = *node->value; if (type != r.type) - qmlInfo(0) << QStringLiteral("Can't assign to existing role '%1' of different type [%2 -> %3]").arg(r.name).arg(roleTypeName(type)).arg(roleTypeName(r.type)); + qmlWarning(0) << QStringLiteral("Can't assign to existing role '%1' of different type [%2 -> %3]").arg(r.name).arg(roleTypeName(type)).arg(roleTypeName(r.type)); return r; } @@ -226,7 +226,7 @@ const ListLayout::Role *ListLayout::getRoleOrCreate(const QString &key, const QV } if (type == Role::Invalid) { - qmlInfo(0) << "Can't create role for unsupported data type"; + qmlWarning(0) << "Can't create role for unsupported data type"; return 0; } @@ -1201,7 +1201,7 @@ int ListElement::setJsProperty(const ListLayout::Role &role, const QV4::Value &d } roleIndex = setListProperty(role, subModel); } else { - qmlInfo(0) << QStringLiteral("Can't assign to existing role '%1' of different type [%2 -> %3]").arg(role.name).arg(roleTypeName(role.type)).arg(roleTypeName(ListLayout::Role::List)); + qmlWarning(0) << QStringLiteral("Can't assign to existing role '%1' of different type [%2 -> %3]").arg(role.name).arg(roleTypeName(role.type)).arg(roleTypeName(ListLayout::Role::List)); } } else if (d.isBoolean()) { roleIndex = setBoolProperty(role, d.booleanValue()); @@ -1984,18 +1984,18 @@ void QQmlListModel::setDynamicRoles(bool enableDynamicRoles) if (m_mainThread && m_agent == 0) { if (enableDynamicRoles) { if (m_layout->roleCount()) - qmlInfo(this) << tr("unable to enable dynamic roles as this model is not empty!"); + qmlWarning(this) << tr("unable to enable dynamic roles as this model is not empty!"); else m_dynamicRoles = true; } else { if (m_roles.count()) { - qmlInfo(this) << tr("unable to enable static roles as this model is not empty!"); + qmlWarning(this) << tr("unable to enable static roles as this model is not empty!"); } else { m_dynamicRoles = false; } } } else { - qmlInfo(this) << tr("dynamic role setting must be made from the main thread, before any worker scripts are created"); + qmlWarning(this) << tr("dynamic role setting must be made from the main thread, before any worker scripts are created"); } } @@ -2048,7 +2048,7 @@ void QQmlListModel::remove(QQmlV4Function *args) int removeCount = (argLength == 2 ? QV4::ScopedValue(scope, (*args)[1])->toInt32() : 1); if (index < 0 || index+removeCount > count() || removeCount <= 0) { - qmlInfo(this) << tr("remove: indices [%1 - %2] out of range [0 - %3]").arg(index).arg(index+removeCount).arg(count()); + qmlWarning(this) << tr("remove: indices [%1 - %2] out of range [0 - %3]").arg(index).arg(index+removeCount).arg(count()); return; } @@ -2064,7 +2064,7 @@ void QQmlListModel::remove(QQmlV4Function *args) emitItemsRemoved(index, removeCount); } else { - qmlInfo(this) << tr("remove: incorrect number of arguments"); + qmlWarning(this) << tr("remove: incorrect number of arguments"); } } @@ -2092,7 +2092,7 @@ void QQmlListModel::insert(QQmlV4Function *args) int index = arg0->toInt32(); if (index < 0 || index > count()) { - qmlInfo(this) << tr("insert: index %1 out of range").arg(index); + qmlWarning(this) << tr("insert: index %1 out of range").arg(index); return; } @@ -2124,10 +2124,10 @@ void QQmlListModel::insert(QQmlV4Function *args) emitItemsInserted(index, 1); } else { - qmlInfo(this) << tr("insert: value is not an object"); + qmlWarning(this) << tr("insert: value is not an object"); } } else { - qmlInfo(this) << tr("insert: value is not an object"); + qmlWarning(this) << tr("insert: value is not an object"); } } @@ -2150,7 +2150,7 @@ void QQmlListModel::move(int from, int to, int n) if (n==0 || from==to) return; if (!canMove(from, to, n)) { - qmlInfo(this) << tr("move: out of range"); + qmlWarning(this) << tr("move: out of range"); return; } @@ -2239,10 +2239,10 @@ void QQmlListModel::append(QQmlV4Function *args) emitItemsInserted(index, 1); } else { - qmlInfo(this) << tr("append: value is not an object"); + qmlWarning(this) << tr("append: value is not an object"); } } else { - qmlInfo(this) << tr("append: value is not an object"); + qmlWarning(this) << tr("append: value is not an object"); } } @@ -2321,11 +2321,11 @@ void QQmlListModel::set(int index, const QQmlV4Handle &handle) QV4::ScopedObject object(scope, handle); if (!object) { - qmlInfo(this) << tr("set: value is not an object"); + qmlWarning(this) << tr("set: value is not an object"); return; } if (index > count() || index < 0) { - qmlInfo(this) << tr("set: index %1 out of range").arg(index); + qmlWarning(this) << tr("set: index %1 out of range").arg(index); return; } @@ -2371,7 +2371,7 @@ void QQmlListModel::set(int index, const QQmlV4Handle &handle) void QQmlListModel::setProperty(int index, const QString& property, const QVariant& value) { if (count() == 0 || index >= count() || index < 0) { - qmlInfo(this) << tr("set: index %1 out of range").arg(index); + qmlWarning(this) << tr("set: index %1 out of range").arg(index); return; } @@ -2401,7 +2401,7 @@ void QQmlListModel::sync() // This is just a dummy method to make it look like sync() exists in // ListModel (and not just QQmlListModelWorkerAgent) and to let // us document sync(). - qmlInfo(this) << "List sync() can only be called from a WorkerScript"; + qmlWarning(this) << "List sync() can only be called from a WorkerScript"; } bool QQmlListModelParser::verifyProperty(const QV4::CompiledData::Unit *qmlUnit, const QV4::CompiledData::Binding *binding) @@ -2543,7 +2543,7 @@ void QQmlListModelParser::applyBindings(QObject *obj, QV4::CompiledData::Compila } if (setRoles == false) - qmlInfo(obj) << "All ListElement declarations are empty, no roles can be created unless dynamicRoles is set."; + qmlWarning(obj) << "All ListElement declarations are empty, no roles can be created unless dynamicRoles is set."; } bool QQmlListModelParser::definesEmptyList(const QString &s) diff --git a/src/qml/types/qqmlobjectmodel.cpp b/src/qml/types/qqmlobjectmodel.cpp index 695043b592..21205f4490 100644 --- a/src/qml/types/qqmlobjectmodel.cpp +++ b/src/qml/types/qqmlobjectmodel.cpp @@ -373,7 +373,7 @@ void QQmlObjectModel::insert(int index, QObject *object) { Q_D(QQmlObjectModel); if (index < 0 || index > count()) { - qmlInfo(this) << tr("insert: index %1 out of range").arg(index); + qmlWarning(this) << tr("insert: index %1 out of range").arg(index); return; } d->insert(index, object); @@ -400,7 +400,7 @@ void QQmlObjectModel::move(int from, int to, int n) if (n <= 0 || from == to) return; if (from < 0 || to < 0 || from + n > count() || to + n > count()) { - qmlInfo(this) << tr("move: out of range"); + qmlWarning(this) << tr("move: out of range"); return; } d->move(from, to, n); @@ -418,7 +418,7 @@ void QQmlObjectModel::remove(int index, int n) { Q_D(QQmlObjectModel); if (index < 0 || n <= 0 || index + n > count()) { - qmlInfo(this) << tr("remove: indices [%1 - %2] out of range [0 - %3]").arg(index).arg(index+n).arg(count()); + qmlWarning(this) << tr("remove: indices [%1 - %2] out of range [0 - %3]").arg(index).arg(index+n).arg(count()); return; } d->remove(index, n); diff --git a/src/quick/items/context2d/qquickcanvasitem.cpp b/src/quick/items/context2d/qquickcanvasitem.cpp index 78db92ba8a..d376816ef9 100644 --- a/src/quick/items/context2d/qquickcanvasitem.cpp +++ b/src/quick/items/context2d/qquickcanvasitem.cpp @@ -354,7 +354,7 @@ void QQuickCanvasItem::setContextType(const QString &contextType) return; if (d->context) { - qmlInfo(this) << "Canvas already initialized with a different context type"; + qmlWarning(this) << "Canvas already initialized with a different context type"; return; } @@ -517,7 +517,7 @@ void QQuickCanvasItem::setRenderTarget(QQuickCanvasItem::RenderTarget target) Q_D(QQuickCanvasItem); if (d->renderTarget != target) { if (d->context) { - qmlInfo(this) << "Canvas:renderTarget not changeble once context is active."; + qmlWarning(this) << "Canvas:renderTarget not changeble once context is active."; return; } @@ -561,7 +561,7 @@ void QQuickCanvasItem::setRenderStrategy(QQuickCanvasItem::RenderStrategy strate Q_D(QQuickCanvasItem); if (d->renderStrategy != strategy) { if (d->context) { - qmlInfo(this) << "Canvas:renderStrategy not changeable once context is active."; + qmlWarning(this) << "Canvas:renderStrategy not changeable once context is active."; return; } d->renderStrategy = strategy; @@ -840,13 +840,13 @@ void QQuickCanvasItem::getContext(QQmlV4Function *args) QV4::Scope scope(args->v4engine()); QV4::ScopedString str(scope, (*args)[0]); if (!str) { - qmlInfo(this) << "getContext should be called with a string naming the required context type"; + qmlWarning(this) << "getContext should be called with a string naming the required context type"; args->setReturnValue(QV4::Encode::null()); return; } if (!d->available) { - qmlInfo(this) << "Unable to use getContext() at this time, please wait for available: true"; + qmlWarning(this) << "Unable to use getContext() at this time, please wait for available: true"; args->setReturnValue(QV4::Encode::null()); return; } @@ -859,7 +859,7 @@ void QQuickCanvasItem::getContext(QQmlV4Function *args) return; } - qmlInfo(this) << "Canvas already initialized with a different context type"; + qmlWarning(this) << "Canvas already initialized with a different context type"; args->setReturnValue(QV4::Encode::null()); return; } @@ -882,7 +882,7 @@ void QQuickCanvasItem::requestAnimationFrame(QQmlV4Function *args) QV4::Scope scope(args->v4engine()); QV4::ScopedFunctionObject f(scope, (*args)[0]); if (!f) { - qmlInfo(this) << "requestAnimationFrame should be called with an animation callback function"; + qmlWarning(this) << "requestAnimationFrame should be called with an animation callback function"; args->setReturnValue(QV4::Encode::null()); return; } @@ -910,7 +910,7 @@ void QQuickCanvasItem::cancelRequestAnimationFrame(QQmlV4Function *args) QV4::Scope scope(args->v4engine()); QV4::ScopedValue v(scope, (*args)[0]); if (!v->isInteger()) { - qmlInfo(this) << "cancelRequestAnimationFrame should be called with an animation callback id"; + qmlWarning(this) << "cancelRequestAnimationFrame should be called with an animation callback id"; args->setReturnValue(QV4::Encode::null()); return; } diff --git a/src/quick/items/qquickanchors.cpp b/src/quick/items/qquickanchors.cpp index 4162314cd3..c0bec7d716 100644 --- a/src/quick/items/qquickanchors.cpp +++ b/src/quick/items/qquickanchors.cpp @@ -214,7 +214,7 @@ void QQuickAnchorsPrivate::fillChanged() --updatingFill; } else { // ### Make this certain :) - qmlInfo(item) << QQuickAnchors::tr("Possible anchor loop detected on fill."); + qmlWarning(item) << QQuickAnchors::tr("Possible anchor loop detected on fill."); } } @@ -243,7 +243,7 @@ void QQuickAnchorsPrivate::centerInChanged() --updatingCenterIn; } else { // ### Make this certain :) - qmlInfo(item) << QQuickAnchors::tr("Possible anchor loop detected on centerIn."); + qmlWarning(item) << QQuickAnchors::tr("Possible anchor loop detected on centerIn."); } } @@ -529,7 +529,7 @@ void QQuickAnchors::setFill(QQuickItem *f) return; } if (f != readParentItem(d->item) && readParentItem(f) != readParentItem(d->item)){ - qmlInfo(d->item) << tr("Cannot anchor to an item that isn't a parent or sibling."); + qmlWarning(d->item) << tr("Cannot anchor to an item that isn't a parent or sibling."); return; } QQuickItem *oldFill = d->fill; @@ -565,7 +565,7 @@ void QQuickAnchors::setCenterIn(QQuickItem* c) return; } if (c != readParentItem(d->item) && readParentItem(c) != readParentItem(d->item)){ - qmlInfo(d->item) << tr("Cannot anchor to an item that isn't a parent or sibling."); + qmlWarning(d->item) << tr("Cannot anchor to an item that isn't a parent or sibling."); return; } QQuickItem *oldCI = d->centerIn; @@ -619,7 +619,7 @@ void QQuickAnchorsPrivate::updateVerticalAnchors() if (Q_UNLIKELY(updatingVerticalAnchor > 1)) { // ### Make this certain :) - qmlInfo(item) << QQuickAnchors::tr("Possible anchor loop detected on vertical anchor."); + qmlWarning(item) << QQuickAnchors::tr("Possible anchor loop detected on vertical anchor."); return; } @@ -794,7 +794,7 @@ void QQuickAnchorsPrivate::updateHorizontalAnchors() --updatingHorizontalAnchor; } else { // ### Make this certain :) - qmlInfo(item) << QQuickAnchors::tr("Possible anchor loop detected on horizontal anchor."); + qmlWarning(item) << QQuickAnchors::tr("Possible anchor loop detected on horizontal anchor."); } } @@ -1329,7 +1329,7 @@ bool QQuickAnchorsPrivate::checkHValid() const if (usedAnchors & QQuickAnchors::LeftAnchor && usedAnchors & QQuickAnchors::RightAnchor && usedAnchors & QQuickAnchors::HCenterAnchor) { - qmlInfo(item) << QQuickAnchors::tr("Cannot specify left, right, and horizontalCenter anchors at the same time."); + qmlWarning(item) << QQuickAnchors::tr("Cannot specify left, right, and horizontalCenter anchors at the same time."); return false; } @@ -1339,17 +1339,17 @@ bool QQuickAnchorsPrivate::checkHValid() const bool QQuickAnchorsPrivate::checkHAnchorValid(QQuickAnchorLine anchor) const { if (!anchor.item) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor to a null item."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor to a null item."); return false; } else if (anchor.anchorLine & QQuickAnchors::Vertical_Mask) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor a horizontal edge to a vertical edge."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor a horizontal edge to a vertical edge."); return false; } else if (anchor.item != readParentItem(item) && readParentItem(anchor.item) != readParentItem(item)) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor to an item that isn't a parent or sibling."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor to an item that isn't a parent or sibling."); return false; } else if (anchor.item == item) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor item to self."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor item to self."); return false; } @@ -1361,13 +1361,13 @@ bool QQuickAnchorsPrivate::checkVValid() const if (usedAnchors & QQuickAnchors::TopAnchor && usedAnchors & QQuickAnchors::BottomAnchor && usedAnchors & QQuickAnchors::VCenterAnchor) { - qmlInfo(item) << QQuickAnchors::tr("Cannot specify top, bottom, and verticalCenter anchors at the same time."); + qmlWarning(item) << QQuickAnchors::tr("Cannot specify top, bottom, and verticalCenter anchors at the same time."); return false; } else if (usedAnchors & QQuickAnchors::BaselineAnchor && (usedAnchors & QQuickAnchors::TopAnchor || usedAnchors & QQuickAnchors::BottomAnchor || usedAnchors & QQuickAnchors::VCenterAnchor)) { - qmlInfo(item) << QQuickAnchors::tr("Baseline anchor cannot be used in conjunction with top, bottom, or verticalCenter anchors."); + qmlWarning(item) << QQuickAnchors::tr("Baseline anchor cannot be used in conjunction with top, bottom, or verticalCenter anchors."); return false; } @@ -1377,17 +1377,17 @@ bool QQuickAnchorsPrivate::checkVValid() const bool QQuickAnchorsPrivate::checkVAnchorValid(QQuickAnchorLine anchor) const { if (!anchor.item) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor to a null item."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor to a null item."); return false; } else if (anchor.anchorLine & QQuickAnchors::Horizontal_Mask) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor a vertical edge to a horizontal edge."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor a vertical edge to a horizontal edge."); return false; } else if (anchor.item != readParentItem(item) && readParentItem(anchor.item) != readParentItem(item)) { - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor to an item that isn't a parent or sibling."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor to an item that isn't a parent or sibling."); return false; } else if (anchor.item == item){ - qmlInfo(item) << QQuickAnchors::tr("Cannot anchor item to self."); + qmlWarning(item) << QQuickAnchors::tr("Cannot anchor item to self."); return false; } diff --git a/src/quick/items/qquickanimatedimage.cpp b/src/quick/items/qquickanimatedimage.cpp index 81c649dbd5..a1833081c8 100644 --- a/src/quick/items/qquickanimatedimage.cpp +++ b/src/quick/items/qquickanimatedimage.cpp @@ -371,7 +371,7 @@ void QQuickAnimatedImage::movieRequestFinished() #endif if (!d->_movie->isValid()) { - qmlInfo(this) << "Error Reading Animated Image File " << d->url.toString(); + qmlWarning(this) << "Error Reading Animated Image File " << d->url.toString(); delete d->_movie; d->_movie = 0; d->setImage(QImage()); diff --git a/src/quick/items/qquickanimatedsprite.cpp b/src/quick/items/qquickanimatedsprite.cpp index 8aeef4ef4a..76c2146ddb 100644 --- a/src/quick/items/qquickanimatedsprite.cpp +++ b/src/quick/items/qquickanimatedsprite.cpp @@ -626,7 +626,7 @@ QSGSpriteNode* QQuickAnimatedSprite::initNode() Q_D(QQuickAnimatedSprite); if (!d->m_spriteEngine) { - qmlInfo(this) << "No sprite engine..."; + qmlWarning(this) << "No sprite engine..."; return nullptr; } else if (d->m_spriteEngine->status() == QQuickPixmap::Null) { d->m_spriteEngine->startAssemblingImage(); diff --git a/src/quick/items/qquickborderimage.cpp b/src/quick/items/qquickborderimage.cpp index 67b99bfbc6..28d834f9e2 100644 --- a/src/quick/items/qquickborderimage.cpp +++ b/src/quick/items/qquickborderimage.cpp @@ -515,7 +515,7 @@ void QQuickBorderImage::requestFinished() QSize impsize = d->pix.implicitSize(); if (d->pix.isError()) { d->status = Error; - qmlInfo(this) << d->pix.error(); + qmlWarning(this) << d->pix.error(); if (d->progress != 0) { d->progress = 0; emit progressChanged(d->progress); diff --git a/src/quick/items/qquickdrag.cpp b/src/quick/items/qquickdrag.cpp index 7a112e840a..e5969eed7f 100644 --- a/src/quick/items/qquickdrag.cpp +++ b/src/quick/items/qquickdrag.cpp @@ -307,7 +307,7 @@ void QQuickDragAttached::setActive(bool active) Q_D(QQuickDragAttached); if (d->active != active) { if (d->inEvent) - qmlInfo(this) << "active cannot be changed from within a drag event handler"; + qmlWarning(this) << "active cannot be changed from within a drag event handler"; else if (active) { if (d->dragType == QQuickDrag::Internal) { d->start(d->supportedActions); @@ -629,7 +629,7 @@ void QQuickDragAttached::start(QQmlV4Function *args) { Q_D(QQuickDragAttached); if (d->inEvent) { - qmlInfo(this) << "start() cannot be called from within a drag event handler"; + qmlWarning(this) << "start() cannot be called from within a drag event handler"; return; } @@ -675,7 +675,7 @@ int QQuickDragAttached::drop() Qt::DropAction acceptedAction = Qt::IgnoreAction; if (d->inEvent) { - qmlInfo(this) << "drop() cannot be called from within a drag event handler"; + qmlWarning(this) << "drop() cannot be called from within a drag event handler"; return acceptedAction; } @@ -722,7 +722,7 @@ void QQuickDragAttached::cancel() Q_D(QQuickDragAttached); if (d->inEvent) { - qmlInfo(this) << "cancel() cannot be called from within a drag event handler"; + qmlWarning(this) << "cancel() cannot be called from within a drag event handler"; return; } @@ -809,12 +809,12 @@ void QQuickDragAttached::startDrag(QQmlV4Function *args) Q_D(QQuickDragAttached); if (d->inEvent) { - qmlInfo(this) << "startDrag() cannot be called from within a drag event handler"; + qmlWarning(this) << "startDrag() cannot be called from within a drag event handler"; return; } if (!d->active) { - qmlInfo(this) << "startDrag() drag must be active"; + qmlWarning(this) << "startDrag() drag must be active"; return; } diff --git a/src/quick/items/qquickflipable.cpp b/src/quick/items/qquickflipable.cpp index 6a6b6c00a9..f452893528 100644 --- a/src/quick/items/qquickflipable.cpp +++ b/src/quick/items/qquickflipable.cpp @@ -153,7 +153,7 @@ void QQuickFlipable::setFront(QQuickItem *front) { Q_D(QQuickFlipable); if (d->front) { - qmlInfo(this) << tr("front is a write-once property"); + qmlWarning(this) << tr("front is a write-once property"); return; } d->front = front; @@ -175,7 +175,7 @@ void QQuickFlipable::setBack(QQuickItem *back) { Q_D(QQuickFlipable); if (d->back) { - qmlInfo(this) << tr("back is a write-once property"); + qmlWarning(this) << tr("back is a write-once property"); return; } if (back == 0) diff --git a/src/quick/items/qquickimagebase.cpp b/src/quick/items/qquickimagebase.cpp index a6bf6b4e8a..22d631e917 100644 --- a/src/quick/items/qquickimagebase.cpp +++ b/src/quick/items/qquickimagebase.cpp @@ -281,7 +281,7 @@ void QQuickImageBase::requestFinished() Q_D(QQuickImageBase); if (d->pix.isError()) { - qmlInfo(this) << d->pix.error(); + qmlWarning(this) << d->pix.error(); d->pix.clear(this); d->status = Error; if (d->progress != 0.0) { diff --git a/src/quick/items/qquickitem.cpp b/src/quick/items/qquickitem.cpp index 504446a8be..01737548c8 100644 --- a/src/quick/items/qquickitem.cpp +++ b/src/quick/items/qquickitem.cpp @@ -1566,7 +1566,7 @@ QQuickLayoutMirroringAttached::QQuickLayoutMirroringAttached(QObject *parent) : if (itemPrivate) itemPrivate->extra.value().layoutDirectionAttached = this; else - qmlInfo(parent) << tr("LayoutDirection attached property only works with Items and Windows"); + qmlWarning(parent) << tr("LayoutDirection attached property only works with Items and Windows"); } QQuickLayoutMirroringAttached * QQuickLayoutMirroringAttached::qmlAttachedProperties(QObject *object) @@ -1714,7 +1714,7 @@ QQuickEnterKeyAttached::QQuickEnterKeyAttached(QObject *parent) itemPrivate = QQuickItemPrivate::get(item); itemPrivate->extra.value().enterKeyAttached = this; } else - qmlInfo(parent) << tr("EnterKey attached property only works with Items"); + qmlWarning(parent) << tr("EnterKey attached property only works with Items"); } QQuickEnterKeyAttached *QQuickEnterKeyAttached::qmlAttachedProperties(QObject *object) @@ -4374,7 +4374,7 @@ void QQuickItem::mapFromItem(QQmlV4Function *args) const } if (!itemObj && !item->isNull()) { - qmlInfo(this) << "mapFromItem() given argument \"" << item->toQStringNoThrow() + qmlWarning(this) << "mapFromItem() given argument \"" << item->toQStringNoThrow() << "\" which is neither null nor an Item"; v4->throwTypeError(); return; @@ -4462,7 +4462,7 @@ void QQuickItem::mapToItem(QQmlV4Function *args) const } if (!itemObj && !item->isNull()) { - qmlInfo(this) << "mapToItem() given argument \"" << item->toQStringNoThrow() + qmlWarning(this) << "mapToItem() given argument \"" << item->toQStringNoThrow() << "\" which is neither null nor an Item"; v4->throwTypeError(); return; diff --git a/src/quick/items/qquickitemanimation.cpp b/src/quick/items/qquickitemanimation.cpp index fd4a7d733f..b33705e75e 100644 --- a/src/quick/items/qquickitemanimation.cpp +++ b/src/quick/items/qquickitemanimation.cpp @@ -304,7 +304,7 @@ QAbstractAnimationJob* QQuickParentAnimation::transition(QQuickStateActions &act bool ok; const QTransform &transform = targetParent->itemTransform(d->via, &ok); if (transform.type() >= QTransform::TxShear || !ok) { - qmlInfo(this) << QQuickParentAnimation::tr("Unable to preserve appearance under complex transform"); + qmlWarning(this) << QQuickParentAnimation::tr("Unable to preserve appearance under complex transform"); ok = false; } @@ -315,21 +315,21 @@ QAbstractAnimationJob* QQuickParentAnimation::transition(QQuickStateActions &act if (transform.m11() == transform.m22()) scale = transform.m11(); else { - qmlInfo(this) << QQuickParentAnimation::tr("Unable to preserve appearance under non-uniform scale"); + qmlWarning(this) << QQuickParentAnimation::tr("Unable to preserve appearance under non-uniform scale"); ok = false; } } else if (ok && isRotate) { if (transform.m11() == transform.m22()) scale = qSqrt(transform.m11()*transform.m11() + transform.m12()*transform.m12()); else { - qmlInfo(this) << QQuickParentAnimation::tr("Unable to preserve appearance under non-uniform scale"); + qmlWarning(this) << QQuickParentAnimation::tr("Unable to preserve appearance under non-uniform scale"); ok = false; } if (scale != 0) rotation = qAtan2(transform.m12()/scale, transform.m11()/scale) * 180/M_PI; else { - qmlInfo(this) << QQuickParentAnimation::tr("Unable to preserve appearance under scale of 0"); + qmlWarning(this) << QQuickParentAnimation::tr("Unable to preserve appearance under scale of 0"); ok = false; } } @@ -474,7 +474,7 @@ int QQuickAnchorAnimation::duration() const void QQuickAnchorAnimation::setDuration(int duration) { if (duration < 0) { - qmlInfo(this) << tr("Cannot set a duration of < 0"); + qmlWarning(this) << tr("Cannot set a duration of < 0"); return; } @@ -613,7 +613,7 @@ int QQuickPathAnimation::duration() const void QQuickPathAnimation::setDuration(int duration) { if (duration < 0) { - qmlInfo(this) << tr("Cannot set a duration of < 0"); + qmlWarning(this) << tr("Cannot set a duration of < 0"); return; } diff --git a/src/quick/items/qquickitemview.cpp b/src/quick/items/qquickitemview.cpp index 7d98cc2693..3f097d4bc8 100644 --- a/src/quick/items/qquickitemview.cpp +++ b/src/quick/items/qquickitemview.cpp @@ -487,7 +487,7 @@ void QQuickItemView::setCacheBuffer(int b) { Q_D(QQuickItemView); if (b < 0) { - qmlInfo(this) << "Cannot set a negative cache buffer"; + qmlWarning(this) << "Cannot set a negative cache buffer"; return; } @@ -2345,7 +2345,7 @@ FxViewItem *QQuickItemViewPrivate::createItem(int modelIndex, bool asynchronous) if (!delegateValidated) { delegateValidated = true; QObject* delegate = q->delegate(); - qmlInfo(delegate ? delegate : q) << QQuickItemView::tr("Delegate must be of Item type"); + qmlWarning(delegate ? delegate : q) << QQuickItemView::tr("Delegate must be of Item type"); } } inRequest = false; diff --git a/src/quick/items/qquickloader.cpp b/src/quick/items/qquickloader.cpp index eeec562e3c..5d5934bbd2 100644 --- a/src/quick/items/qquickloader.cpp +++ b/src/quick/items/qquickloader.cpp @@ -971,7 +971,7 @@ QV4::ReturnedValue QQuickLoaderPrivate::extractInitialPropertyValues(QQmlV4Funct QV4::ScopedValue v(scope, (*args)[1]); if (!v->isObject() || v->as()) { *error = true; - qmlInfo(loader) << QQuickLoader::tr("setSource: value is not an object"); + qmlWarning(loader) << QQuickLoader::tr("setSource: value is not an object"); } else { *error = false; valuemap = v; diff --git a/src/quick/items/qquickpathview.cpp b/src/quick/items/qquickpathview.cpp index 03596f13e9..53e547fe98 100644 --- a/src/quick/items/qquickpathview.cpp +++ b/src/quick/items/qquickpathview.cpp @@ -137,7 +137,7 @@ QQuickItem *QQuickPathViewPrivate::getItem(int modelIndex, qreal z, bool async) if (!delegateValidated) { delegateValidated = true; QObject* delegate = q->delegate(); - qmlInfo(delegate ? delegate : q) << QQuickPathView::tr("Delegate must be of Item type"); + qmlWarning(delegate ? delegate : q) << QQuickPathView::tr("Delegate must be of Item type"); } } } else { diff --git a/src/quick/items/qquickpositioners.cpp b/src/quick/items/qquickpositioners.cpp index e22427ca49..0287fdd45c 100644 --- a/src/quick/items/qquickpositioners.cpp +++ b/src/quick/items/qquickpositioners.cpp @@ -957,7 +957,7 @@ void QQuickColumn::reportConflictingAnchors() } } if (d->anchorConflict) { - qmlInfo(this) << "Cannot specify top, bottom, verticalCenter, fill or centerIn anchors for items inside Column." + qmlWarning(this) << "Cannot specify top, bottom, verticalCenter, fill or centerIn anchors for items inside Column." << " Column will not function."; } } @@ -1224,7 +1224,7 @@ void QQuickRow::reportConflictingAnchors() } } if (d->anchorConflict) - qmlInfo(this) << "Cannot specify left, right, horizontalCenter, fill or centerIn anchors for items inside Row." + qmlWarning(this) << "Cannot specify left, right, horizontalCenter, fill or centerIn anchors for items inside Row." << " Row will not function."; } @@ -1808,7 +1808,7 @@ void QQuickGrid::reportConflictingAnchors() } } if (d->anchorConflict) - qmlInfo(this) << "Cannot specify anchors for items inside Grid." << " Grid will not function."; + qmlWarning(this) << "Cannot specify anchors for items inside Grid." << " Grid will not function."; } /*! @@ -2121,7 +2121,7 @@ void QQuickFlow::reportConflictingAnchors() } } if (d->anchorConflict) - qmlInfo(this) << "Cannot specify anchors for items inside Flow." << " Flow will not function."; + qmlWarning(this) << "Cannot specify anchors for items inside Flow." << " Flow will not function."; } QT_END_NAMESPACE diff --git a/src/quick/items/qquickrepeater.cpp b/src/quick/items/qquickrepeater.cpp index 4f46f41b0d..a7254464ed 100644 --- a/src/quick/items/qquickrepeater.cpp +++ b/src/quick/items/qquickrepeater.cpp @@ -423,7 +423,7 @@ void QQuickRepeater::initItem(int index, QObject *object) if (!d->delegateValidated) { d->delegateValidated = true; QObject* delegate = this->delegate(); - qmlInfo(delegate ? delegate : this) << QQuickRepeater::tr("Delegate must be of Item type"); + qmlWarning(delegate ? delegate : this) << QQuickRepeater::tr("Delegate must be of Item type"); } } return; diff --git a/src/quick/items/qquickspriteengine.cpp b/src/quick/items/qquickspriteengine.cpp index f54a8911b2..d26a1f8a64 100644 --- a/src/quick/items/qquickspriteengine.cpp +++ b/src/quick/items/qquickspriteengine.cpp @@ -378,7 +378,7 @@ QImage QQuickSpriteEngine::assembledImage(int maxSize) if (!m_errorsPrinted && stat == QQuickPixmap::Error) { for (QQuickSprite* s : qAsConst(m_sprites)) if (s->m_pix.isError()) - qmlInfo(s) << s->m_pix.error(); + qmlWarning(s) << s->m_pix.error(); m_errorsPrinted = true; } @@ -399,7 +399,7 @@ QImage QQuickSpriteEngine::assembledImage(int maxSize) { const QSize frameSize(state->m_frameWidth, state->m_frameHeight); if (!(img.size() - frameSize).isValid()) { - qmlInfo(state).nospace() << "SpriteEngine: Invalid frame size " << frameSize << "." + qmlWarning(state).nospace() << "SpriteEngine: Invalid frame size " << frameSize << "." " It's bigger than image size " << img.size() << "."; return QImage(); } @@ -419,10 +419,10 @@ QImage QQuickSpriteEngine::assembledImage(int maxSize) int rowsNeeded = helper::divRoundUp(state->frames(), (maxSize / state->frameWidth())); if (h + rowsNeeded * state->frameHeight() > maxSize){ if (rowsNeeded * state->frameHeight() > maxSize) - qmlInfo(state) << "SpriteEngine: Animation too large to fit in one texture:" << state->source().toLocalFile(); + qmlWarning(state) << "SpriteEngine: Animation too large to fit in one texture:" << state->source().toLocalFile(); else - qmlInfo(state) << "SpriteEngine: Animations too large to fit in one texture, pushed over the edge by:" << state->source().toLocalFile(); - qmlInfo(state) << "SpriteEngine: Your texture max size today is " << maxSize; + qmlWarning(state) << "SpriteEngine: Animations too large to fit in one texture, pushed over the edge by:" << state->source().toLocalFile(); + qmlWarning(state) << "SpriteEngine: Your texture max size today is " << maxSize; return QImage(); } state->m_generatedCount = rowsNeeded; diff --git a/src/quick/items/qquickspritesequence.cpp b/src/quick/items/qquickspritesequence.cpp index 25a39f951a..858a3c0576 100644 --- a/src/quick/items/qquickspritesequence.cpp +++ b/src/quick/items/qquickspritesequence.cpp @@ -209,7 +209,7 @@ QSGSpriteNode *QQuickSpriteSequence::initNode() Q_D(QQuickSpriteSequence); if (!d->m_spriteEngine) { - qmlInfo(this) << "No sprite engine..."; + qmlWarning(this) << "No sprite engine..."; return nullptr; } else if (d->m_spriteEngine->status() == QQuickPixmap::Null) { d->m_spriteEngine->startAssemblingImage(); diff --git a/src/quick/items/qquickstateoperations.cpp b/src/quick/items/qquickstateoperations.cpp index 9cd3b6a5f5..b40a9e2843 100644 --- a/src/quick/items/qquickstateoperations.cpp +++ b/src/quick/items/qquickstateoperations.cpp @@ -78,7 +78,7 @@ void QQuickParentChangePrivate::doChange(QQuickItem *targetParent, QQuickItem *s bool ok; const QTransform &transform = target->parentItem()->itemTransform(targetParent, &ok); if (transform.type() >= QTransform::TxShear || !ok) { - qmlInfo(q) << QQuickParentChange::tr("Unable to preserve appearance under complex transform"); + qmlWarning(q) << QQuickParentChange::tr("Unable to preserve appearance under complex transform"); ok = false; } @@ -89,21 +89,21 @@ void QQuickParentChangePrivate::doChange(QQuickItem *targetParent, QQuickItem *s if (transform.m11() == transform.m22()) scale = transform.m11(); else { - qmlInfo(q) << QQuickParentChange::tr("Unable to preserve appearance under non-uniform scale"); + qmlWarning(q) << QQuickParentChange::tr("Unable to preserve appearance under non-uniform scale"); ok = false; } } else if (ok && isRotate) { if (transform.m11() == transform.m22()) scale = qSqrt(transform.m11()*transform.m11() + transform.m12()*transform.m12()); else { - qmlInfo(q) << QQuickParentChange::tr("Unable to preserve appearance under non-uniform scale"); + qmlWarning(q) << QQuickParentChange::tr("Unable to preserve appearance under non-uniform scale"); ok = false; } if (scale != 0) rotation = qAtan2(transform.m12()/scale, transform.m11()/scale) * 180/M_PI; else { - qmlInfo(q) << QQuickParentChange::tr("Unable to preserve appearance under scale of 0"); + qmlWarning(q) << QQuickParentChange::tr("Unable to preserve appearance under scale of 0"); ok = false; } } diff --git a/src/quick/items/qquicktext.cpp b/src/quick/items/qquicktext.cpp index e37a7e6d5e..30e9c71143 100644 --- a/src/quick/items/qquicktext.cpp +++ b/src/quick/items/qquicktext.cpp @@ -1135,7 +1135,7 @@ void QQuickTextPrivate::setLineGeometry(QTextLine &line, qreal lineWidth, qreal needToUpdateLayout = true; } } else if (image->pix->isError()) { - qmlInfo(q) << image->pix->error(); + qmlWarning(q) << image->pix->error(); } } diff --git a/src/quick/items/qquicktextdocument.cpp b/src/quick/items/qquicktextdocument.cpp index 61d75fe99b..c272503480 100644 --- a/src/quick/items/qquicktextdocument.cpp +++ b/src/quick/items/qquicktextdocument.cpp @@ -211,7 +211,7 @@ QQuickPixmap *QQuickTextDocumentWithImageResources::loadPixmap( if (p->isError()) { if (!errors.contains(url)) { errors.insert(url); - qmlInfo(parent()) << p->error(); + qmlWarning(parent()) << p->error(); } } return p; diff --git a/src/quick/items/qquicktextedit.cpp b/src/quick/items/qquicktextedit.cpp index 106acf57cf..8532786a8d 100644 --- a/src/quick/items/qquicktextedit.cpp +++ b/src/quick/items/qquicktextedit.cpp @@ -1741,7 +1741,7 @@ void QQuickTextEdit::select(int start, int end) bool QQuickTextEdit::isRightToLeft(int start, int end) { if (start > end) { - qmlInfo(this) << "isRightToLeft(start, end) called with the end property being smaller than the start."; + qmlWarning(this) << "isRightToLeft(start, end) called with the end property being smaller than the start."; return false; } else { return getText(start, end).isRightToLeft(); diff --git a/src/quick/items/qquicktextinput.cpp b/src/quick/items/qquicktextinput.cpp index e9f88ae7f0..a023ad8a8c 100644 --- a/src/quick/items/qquicktextinput.cpp +++ b/src/quick/items/qquicktextinput.cpp @@ -2002,7 +2002,7 @@ void QQuickTextInput::selectAll() bool QQuickTextInput::isRightToLeft(int start, int end) { if (start > end) { - qmlInfo(this) << "isRightToLeft(start, end) called with the end property being smaller than the start."; + qmlWarning(this) << "isRightToLeft(start, end) called with the end property being smaller than the start."; return false; } else { return text().midRef(start, end - start).isRightToLeft(); diff --git a/src/quick/items/qquicktextutil.cpp b/src/quick/items/qquicktextutil.cpp index 8bcdb0b5f6..b07289f4a3 100644 --- a/src/quick/items/qquicktextutil.cpp +++ b/src/quick/items/qquicktextutil.cpp @@ -61,7 +61,7 @@ QQuickItem *QQuickTextUtil::createCursor( item->setPosition(rectangle.topLeft()); item->setHeight(rectangle.height()); } else { - qmlInfo(parent) << tr("%1 does not support loading non-visual cursor delegates.") + qmlWarning(parent) << tr("%1 does not support loading non-visual cursor delegates.") .arg(QString::fromUtf8(className)); } component->completeCreate(); @@ -72,7 +72,7 @@ QQuickItem *QQuickTextUtil::createCursor( parent, SLOT(createCursor()), Qt::UniqueConnection); return item; } - qmlInfo(parent, component->errors()) << tr("Could not load cursor delegate"); + qmlWarning(parent, component->errors()) << tr("Could not load cursor delegate"); return item; } diff --git a/src/quick/util/qquickanimation.cpp b/src/quick/util/qquickanimation.cpp index 9de474ac36..1a2441171d 100644 --- a/src/quick/util/qquickanimation.cpp +++ b/src/quick/util/qquickanimation.cpp @@ -192,14 +192,14 @@ QQmlProperty QQuickAbstractAnimationPrivate::createProperty(QObject *obj, const if (errorMessage) *errorMessage = message; else - qmlInfo(infoObj) << message; + qmlWarning(infoObj) << message; return QQmlProperty(); } else if (!prop.isWritable()) { const QString message = QQuickAbstractAnimation::tr("Cannot animate read-only property \"%1\"").arg(str); if (errorMessage) *errorMessage = message; else - qmlInfo(infoObj) << message; + qmlWarning(infoObj) << message; return QQmlProperty(); } return prop; @@ -256,7 +256,7 @@ void QQuickAbstractAnimation::setRunning(bool r) return; if (d->group || d->disableUserControl) { - qmlInfo(this) << "setRunning() cannot be used on non-root animation nodes."; + qmlWarning(this) << "setRunning() cannot be used on non-root animation nodes."; return; } @@ -322,12 +322,12 @@ void QQuickAbstractAnimation::setPaused(bool p) return; if (!d->running) { - qmlInfo(this) << "setPaused() cannot be used when animation isn't running."; + qmlWarning(this) << "setPaused() cannot be used when animation isn't running."; return; } if (d->group || d->disableUserControl) { - qmlInfo(this) << "setPaused() cannot be used on non-root animation nodes."; + qmlWarning(this) << "setPaused() cannot be used on non-root animation nodes."; return; } @@ -709,7 +709,7 @@ int QQuickPauseAnimation::duration() const void QQuickPauseAnimation::setDuration(int duration) { if (duration < 0) { - qmlInfo(this) << tr("Cannot set a duration of < 0"); + qmlWarning(this) << tr("Cannot set a duration of < 0"); return; } @@ -1004,7 +1004,7 @@ void QQuickScriptActionPrivate::execute() QQmlExpression expr(scriptStr); expr.evaluate(); if (expr.hasError()) - qmlInfo(q) << expr.error(); + qmlWarning(q) << expr.error(); } } @@ -2077,7 +2077,7 @@ int QQuickPropertyAnimation::duration() const void QQuickPropertyAnimation::setDuration(int duration) { if (duration < 0) { - qmlInfo(this) << tr("Cannot set a duration of < 0"); + qmlWarning(this) << tr("Cannot set a duration of < 0"); return; } @@ -2644,7 +2644,7 @@ QQuickStateActions QQuickPropertyAnimation::createTransitionActions(QQuickStateA if (!successfullyCreatedDefaultProperty) { for (const QString &errorMessage : qAsConst(errorMessages)) - qmlInfo(this) << errorMessage; + qmlWarning(this) << errorMessage; } } diff --git a/src/quick/util/qquickanimationcontroller.cpp b/src/quick/util/qquickanimationcontroller.cpp index 4bc2d6319e..fa1ade50d1 100644 --- a/src/quick/util/qquickanimationcontroller.cpp +++ b/src/quick/util/qquickanimationcontroller.cpp @@ -169,7 +169,7 @@ void QQuickAnimationController::setAnimation(QQuickAbstractAnimation *animation) if (animation != d->animation) { if (animation) { if (animation->userControlDisabled()) { - qmlInfo(this) << "QQuickAnimationController::setAnimation: the animation is controlled by others, can't be used in AnimationController."; + qmlWarning(this) << "QQuickAnimationController::setAnimation: the animation is controlled by others, can't be used in AnimationController."; return; } animation->setDisableUserControl(); diff --git a/src/quick/util/qquickbehavior.cpp b/src/quick/util/qquickbehavior.cpp index 9af1d41b29..1b2d9afb7c 100644 --- a/src/quick/util/qquickbehavior.cpp +++ b/src/quick/util/qquickbehavior.cpp @@ -129,7 +129,7 @@ void QQuickBehavior::setAnimation(QQuickAbstractAnimation *animation) { Q_D(QQuickBehavior); if (d->animation) { - qmlInfo(this) << tr("Cannot change the animation assigned to a Behavior."); + qmlWarning(this) << tr("Cannot change the animation assigned to a Behavior."); return; } diff --git a/src/quick/util/qquickfontloader.cpp b/src/quick/util/qquickfontloader.cpp index d13291c30a..3761a37a6d 100644 --- a/src/quick/util/qquickfontloader.cpp +++ b/src/quick/util/qquickfontloader.cpp @@ -307,7 +307,7 @@ void QQuickFontLoader::updateFontInfo(const QString& name, QQuickFontLoader::Sta } if (status != d->status) { if (status == Error) - qmlInfo(this) << "Cannot load font: \"" << d->url.toString() << '"'; + qmlWarning(this) << "Cannot load font: \"" << d->url.toString() << '"'; d->status = status; emit statusChanged(); } diff --git a/src/quick/util/qquickpropertychanges.cpp b/src/quick/util/qquickpropertychanges.cpp index fafa2edd0b..20aa52e472 100644 --- a/src/quick/util/qquickpropertychanges.cpp +++ b/src/quick/util/qquickpropertychanges.cpp @@ -397,10 +397,10 @@ QQuickPropertyChangesPrivate::property(const QString &property) Q_Q(QQuickPropertyChanges); QQmlProperty prop(object, property, qmlContext(q)); if (!prop.isValid()) { - qmlInfo(q) << QQuickPropertyChanges::tr("Cannot assign to non-existent property \"%1\"").arg(property); + qmlWarning(q) << QQuickPropertyChanges::tr("Cannot assign to non-existent property \"%1\"").arg(property); return QQmlProperty(); } else if (!(prop.type() & QQmlProperty::SignalProperty) && !prop.isWritable()) { - qmlInfo(q) << QQuickPropertyChanges::tr("Cannot assign to read-only property \"%1\"").arg(property); + qmlWarning(q) << QQuickPropertyChanges::tr("Cannot assign to read-only property \"%1\"").arg(property); return QQmlProperty(); } return prop; diff --git a/src/quick/util/qquickstatechangescript.cpp b/src/quick/util/qquickstatechangescript.cpp index 86b70fe879..a70fa1a676 100644 --- a/src/quick/util/qquickstatechangescript.cpp +++ b/src/quick/util/qquickstatechangescript.cpp @@ -131,7 +131,7 @@ void QQuickStateChangeScript::execute() QQmlExpression expr(d->script); expr.evaluate(); if (expr.hasError()) - qmlInfo(this, expr.error()); + qmlWarning(this, expr.error()); } } diff --git a/src/quick/util/qquickstategroup.cpp b/src/quick/util/qquickstategroup.cpp index 200f243a1b..f2cd4638fc 100644 --- a/src/quick/util/qquickstategroup.cpp +++ b/src/quick/util/qquickstategroup.cpp @@ -438,7 +438,7 @@ void QQuickStateGroupPrivate::setCurrentStateInternal(const QString &state, } if (applyingState) { - qmlInfo(q) << "Can't apply a state change as part of a state definition."; + qmlWarning(q) << "Can't apply a state change as part of a state definition."; return; } -- cgit v1.2.3