forked from qt-creator/qt-creator
Made CrumblePath API a bit more consistent/generic
Was a bit confusing to pass QVariant data in and get an int back. Change-Id: I613d2eb88ade45baee85a4f84d7db6d3ce7fb923 Reviewed-on: http://codereview.qt.nokia.com/205 Reviewed-by: Christiaan Janssen <christiaan.janssen@nokia.com>
This commit is contained in:
committed by
Christiaan Janssen
parent
61fc11b9c0
commit
38c798a642
@@ -52,10 +52,10 @@ void ContextCrumblePath::updateContextPath(const QStringList &path, const QList<
|
||||
|
||||
m_isEmpty = path.isEmpty();
|
||||
if (m_isEmpty) {
|
||||
pushElement(tr("[no context]"),QVariant(-1));
|
||||
pushElement(tr("[no context]"), -1);
|
||||
} else {
|
||||
for (int i = 0; i < path.count(); i++)
|
||||
pushElement(path[i], QVariant(debugIds[i]));
|
||||
pushElement(path[i], debugIds[i]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ void ContextCrumblePath::addChildren(const QStringList &childrenNames, const QLi
|
||||
{
|
||||
Q_ASSERT(childrenNames.count() == childrenDebugIds.count());
|
||||
for (int i = 0; i < childrenNames.count(); i++)
|
||||
addChild(childrenNames[i], QVariant(childrenDebugIds[i]));
|
||||
addChild(childrenNames[i], childrenDebugIds[i]);
|
||||
}
|
||||
|
||||
void ContextCrumblePath::clear()
|
||||
|
||||
Reference in New Issue
Block a user