forked from qt-creator/qt-creator
Utils: Rename most FilePath::{from,to}Variant uses to {from,to}Settings
Specifies the main purpose more clearly. The remaining ones a "true" (internal) variants in models and as action data. Change-Id: I8dd3c846e419f29d88283c2f48268ef6685b19fe Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -795,8 +795,8 @@ bool PathChooserField::parseData(const QVariant &data, QString *errorMessage)
|
||||
|
||||
QVariantMap tmp = data.toMap();
|
||||
|
||||
m_path = FilePath::fromVariant(consumeValue(tmp, "path"));
|
||||
m_basePath = FilePath::fromVariant(consumeValue(tmp, "basePath"));
|
||||
m_path = FilePath::fromSettings(consumeValue(tmp, "path"));
|
||||
m_basePath = FilePath::fromSettings(consumeValue(tmp, "basePath"));
|
||||
m_historyId = consumeValue(tmp, "historyId").toString();
|
||||
|
||||
QString kindStr = consumeValue(tmp, "kind", "existingDirectory").toString();
|
||||
@@ -877,12 +877,12 @@ void PathChooserField::initializeData(MacroExpander *expander)
|
||||
|
||||
void PathChooserField::fromSettings(const QVariant &value)
|
||||
{
|
||||
m_path = FilePath::fromVariant(value);
|
||||
m_path = FilePath::fromSettings(value);
|
||||
}
|
||||
|
||||
QVariant PathChooserField::toSettings() const
|
||||
{
|
||||
return qobject_cast<PathChooser *>(widget())->filePath().toVariant();
|
||||
return qobject_cast<PathChooser *>(widget())->filePath().toSettings();
|
||||
}
|
||||
|
||||
// --------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user