Skip to content

Commit

Permalink
Qt5: 'QVariant qVariantFromValue(const T&)' is deprecated: Use QVaria…
Browse files Browse the repository at this point in the history
…nt::fromValue() instead. [-Wdeprecated-declarations]
  • Loading branch information
wwmayer committed Jun 12, 2020
1 parent eced0cb commit 66cbcde
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Gui/CallTips.cpp
Expand Up @@ -523,7 +523,7 @@ void CallTipsList::showTips(const QString& line)
addItem(it.key());
QListWidgetItem *item = this->item(this->count()-1);
item->setData(Qt::ToolTipRole, QVariant(it.value().description));
item->setData(Qt::UserRole, qVariantFromValue( it.value() )); //< store full CallTip data
item->setData(Qt::UserRole, QVariant::fromValue( it.value() )); //< store full CallTip data
switch (it.value().type)
{
case CallTip::Module:
Expand Down
2 changes: 1 addition & 1 deletion src/Mod/TechDraw/App/QDomNodeModel.cpp
Expand Up @@ -273,7 +273,7 @@ QString QDomNodeModel::stringValue ( const QXmlNodeModelIndex & ni ) const

QVariant QDomNodeModel::typedValue ( const QXmlNodeModelIndex & ni ) const
{
return qVariantFromValue(stringValue(ni));
return QVariant::fromValue(stringValue(ni));
}

QXmlNodeModelIndex QDomNodeModel::fromDomNode(const QDomNode &n) const
Expand Down

0 comments on commit 66cbcde

Please sign in to comment.