mirror of https://code.videolan.org/videolan/vlc
Revert "qt: workaround for type conversion to QVector<MLItemId> doesn't occur with Qt 5.12"
This reverts commit 23e220abf8
.
This commit is contained in:
parent
839924f737
commit
f17fe8e429
|
@ -269,24 +269,6 @@ void MediaLib::reload()
|
|||
});
|
||||
}
|
||||
|
||||
void MediaLib::mlInputItem(const QVariantList &variantList, QJSValue callback)
|
||||
{
|
||||
if (!callback.isCallable()) // invalid argument
|
||||
{
|
||||
msg_Warn(m_intf, "callback is not callbable");
|
||||
return;
|
||||
}
|
||||
|
||||
QVector<MLItemId> mlIdList;
|
||||
for (const auto& variant : variantList)
|
||||
{
|
||||
assert(variant.canConvert<MLItemId>());
|
||||
mlIdList.push_back(variant.value<MLItemId>());
|
||||
}
|
||||
|
||||
mlInputItem(mlIdList, callback);
|
||||
}
|
||||
|
||||
void MediaLib::mlInputItem(const QVector<MLItemId>& itemIdVector, QJSValue callback)
|
||||
{
|
||||
if (!callback.isCallable()) // invalid argument
|
||||
|
|
|
@ -74,9 +74,6 @@ public:
|
|||
Q_INVOKABLE void reload();
|
||||
|
||||
Q_INVOKABLE void mlInputItem(const QVector<MLItemId>& itemIdVector, QJSValue callback);
|
||||
// TODO: This is added back due to type conversion does not occur with Qt 5.12.
|
||||
// Remove when possible:
|
||||
Q_INVOKABLE void mlInputItem(const QVariantList& variantList, QJSValue callback);
|
||||
|
||||
inline bool idle() const { return m_idle; }
|
||||
inline int discoveryPending() const { return m_discoveryPending; }
|
||||
|
|
Loading…
Reference in New Issue