18 const QDomNodeList &nodes =
m_document->elementsByTagName(helper.nodeName(
"Entry"));
19 for(
int i = 0; i < nodes.count(); ++i)
21 const QDomNodeList ¶mNodes = nodes.item(i).childNodes();
23 QString duration, path;
24 for(
int j = 0; j < paramNodes.count(); ++j)
26 const QDomNode ¶mNode = paramNodes.item(j);
27 const QDomElement &element = paramNode.toElement();
28 const QString &
name = paramNode.nodeName().toLower();
30 if(name ==
"duration" || name ==
"length")
32 duration = element.attribute(
"value");
33 duration = duration.mid(3, 5);
35 else if(name ==
"ref")
37 path = element.attribute(
"href");
63 for(
int i = 0; i < items.count(); ++i)
74 writeDomElement(trackDom,
"Duration", {
"value",
"00:" + song.duration() +
".000"});
The class of the ttk xml interface.
QDomDocument * m_document
QDomElement writeDomElement(QDomElement &element, const QString &node) const
QDomElement createRoot(const QString &node) const
The class of the ttk xml attribute.
The class of the ttk xml hepler.
The class of the read write interface.
The class of the music song item.
virtual bool writeBuffer(const MusicSongItemList &items) overridefinal
virtual bool readBuffer(MusicSongItemList &items) overridefinal
The class of the music song info.