Commit f91aaf01 authored by Ronan's avatar Ronan
Browse files

feat(src/components/codecs/CodecsModel): in progress.

parent b4351700
......@@ -89,6 +89,6 @@ QVariant CodecsModel::data (const QModelIndex &index, int role) const {
void CodecsModel::enableCodec (int id, bool status) {
Q_ASSERT(id >= 0 && id < m_codecs.count());
shared_ptr<linphone::PayloadType> codec = m_codecs[id].toMap().value("__codec").value<>();
shared_ptr<linphone::PayloadType> codec = m_codecs[id].toMap().value("__codec").value<shared_ptr<linphone::PayloadType> >();
codec->enable(status);
}
......@@ -23,10 +23,16 @@
#ifndef CODECS_MODEL_H_
#define CODECS_MODEL_H_
#include <memory>
#include <QAbstractListModel>
// =============================================================================
namespace linphone {
class PayloadType;
}
class CodecsModel : public QAbstractListModel {
Q_OBJECT;
......@@ -53,4 +59,6 @@ private:
QVariantList m_codecs;
};
Q_DECLARE_METATYPE(std::shared_ptr<linphone::PayloadType> );
#endif // CODECS_MODEL_H_
......@@ -12,4 +12,6 @@ Text {
bold: true
pointSize: CodecsViewerStyle.legend.fontSize
}
horizontalAlignment: Text.AlignHCenter
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment