mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Improve code style, Wrap code for better readability
This commit is contained in:
@@ -836,12 +836,16 @@ QDomDocument QETProject::toXml() {
|
||||
|
||||
// schemas
|
||||
|
||||
// qDebug() << "Export XML de" << diagrams_.count() << "schemas";
|
||||
qDebug() << "Export XML de" << m_diagrams_list.count() << "schemas";
|
||||
int order_num = 1;
|
||||
const QList<Diagram *> diagrams_list = m_diagrams_list;
|
||||
for(Diagram *diagram : diagrams_list)
|
||||
{
|
||||
qDebug() << qPrintable(QString("QETProject::toXml() : exporting diagram \"%1\"").arg(diagram -> title())) << "[" << diagram << "]";
|
||||
qDebug() << QString("exporting diagram \"%1\""
|
||||
).arg(diagram -> title())
|
||||
<< "["
|
||||
<< diagram
|
||||
<< "]";
|
||||
QDomElement xml_diagram = diagram->toXml().documentElement();
|
||||
QDomNode xml_node = xml_doc.importNode(xml_diagram, true);
|
||||
|
||||
@@ -1020,10 +1024,12 @@ ElementsLocation QETProject::importElement(ElementsLocation &location)
|
||||
}
|
||||
//Element doesn't exist in the collection, we just import it
|
||||
else {
|
||||
ElementsLocation loc(m_elements_collection->addElement(location), this);
|
||||
ElementsLocation loc(m_elements_collection->addElement(
|
||||
location), this);
|
||||
|
||||
if (!loc.exist()) {
|
||||
qDebug() << "QETProject::importElement : failed to import location. " << location;
|
||||
qDebug() << "failed to import location. "
|
||||
<< location;
|
||||
return ElementsLocation();
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user