"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/ExportDlgImpl.cpp" between
MP3Diags-unstable-1.3.04.tar.gz and MP3Diags-unstable-1.5.01.tar.gz

About: MP3 Diags finds problems in MP3 files and helps the user to fix many of them (with a GUI). Also includes a tag editor and a file renamer.

ExportDlgImpl.cpp  (MP3Diags-unstable-1.3.04):ExportDlgImpl.cpp  (MP3Diags-unstable-1.5.01)
skipping to change at line 215 skipping to change at line 215
dlg.setFilters(filters);*/ dlg.setFilters(filters);*/
dlg.setFileMode(QFileDialog::AnyFile); dlg.setFileMode(QFileDialog::AnyFile);
if (QDialog::Accepted != dlg.exec()) { return; } if (QDialog::Accepted != dlg.exec()) { return; }
QStringList fileNames (dlg.selectedFiles()); QStringList fileNames (dlg.selectedFiles());
if (1 != fileNames.size()) { return; } if (1 != fileNames.size()) { return; }
QString s (fileNames.first()); QString s (fileNames.first());
QString flt (dlg.selectedFilter()); QString flt (dlg.selectedNameFilter()); //ttt9 make sure this is OK on Windo ws (it works on Linux)
if (flt.endsWith("xml)") && !s.endsWith(".xml")) if (flt.endsWith("xml)") && !s.endsWith(".xml"))
{ {
s += ".xml"; s += ".xml";
} }
else if (flt.endsWith("txt)") && !s.endsWith(".txt")) else if (flt.endsWith("txt)") && !s.endsWith(".txt"))
{ {
s += ".txt"; s += ".txt";
} }
else if (flt.endsWith("m3u)") && !s.endsWith(".m3u")) else if (flt.endsWith("m3u)") && !s.endsWith(".m3u"))
{ {
skipping to change at line 415 skipping to change at line 415
out << pCodec->fromUnicode(qs).constData() << endl; out << pCodec->fromUnicode(qs).constData() << endl;
} }
return (bool)out; return (bool)out;
} }
namespace { namespace {
string escapeXml(const string& s) string escapeXml(const string& s)
{ {
QString qs (Qt::escape(convStr(s))); QString qs (convStr(s).toHtmlEscaped());
qs.replace(QString("\""), "&quot;"); qs.replace(QString("\""), "&quot;");
qs.replace(QString("#"), "&#35;"); qs.replace(QString("#"), "&#35;");
return convStr(qs); return convStr(qs);
} }
void printDataStream(ostream& out, DataStream* p) void printDataStream(ostream& out, DataStream* p)
{ {
out << " type=\"" << p->getDisplayName() << "\" begin=\"0x" << hex << p->get Pos() << "\" end=\"0x" << (p->getPos() + (p->getSize() - 1)) << "\" size=\"" << dec << p->getSize() << "\""; out << " type=\"" << p->getDisplayName() << "\" begin=\"0x" << hex << p->get Pos() << "\" end=\"0x" << (p->getPos() + (p->getSize() - 1)) << "\" size=\"" << dec << p->getSize() << "\"";
} }
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)