@@ -74,6 +74,9 @@
continue;
}
+ if (i>0)
+ *ts << "," << endl;
+
*ts << S(4) << "\"" << cameras.at(i).first.split(" ").first().toLower() << "\":" << endl << S(4) << "{" << endl;
for (j=0 ; j<resolutions.at(i).size() ; j++)
@@ -83,6 +86,9 @@
continue;
}
+ if (j>0)
+ *ts << "," << endl;
+
QStringList res = resolutions.at(i).at(j).second;
*ts << S(8) << "\"" << resolutions.at(i).at(j).first.split("-").first().toLower() << "\":" << endl << S(8) << "[" << endl;
@@ -95,11 +101,14 @@
<< ((m == res.size()-1) ? "" : ",") << endl;
}
- *ts << S(8) << ((j < resolutions.at(i).size()-1) ? "]," : "]") << endl;
+ *ts << S(8) << "]";
}
- *ts << S(4) << ((i < cameras.size()-1) ? "}," : "}") << endl;
+
+ *ts << endl;
+ *ts << S(4) << "}";
}
+ *ts << endl;
*ts << "}" << endl;
file.close();
|