Commit b4351700 authored by Ronan's avatar Ronan
Browse files

unstable

parent 9594e158
......@@ -43,6 +43,7 @@ inline void addCodecToList (QVariantList &list, const T &codec, CodecsModel::Cod
map["number"] = codec->getNumber();
map["type"] = type;
map["recvFmtp"] = ::Utils::linphoneStringToQString(codec->getRecvFmtp());
map["__codec"] = QVariant::fromValue(codec);
list << map;
}
......@@ -87,5 +88,7 @@ QVariant CodecsModel::data (const QModelIndex &index, int role) const {
// -----------------------------------------------------------------------------
void CodecsModel::enableCodec (int id, bool status) {
// TODO.
Q_ASSERT(id >= 0 && id < m_codecs.count());
shared_ptr<linphone::PayloadType> codec = m_codecs[id].toMap().value("__codec").value<>();
codec->enable(status);
}
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