mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-18 13:30:34 +01:00
Revert r4900
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4902 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -101,7 +101,7 @@ ElementsLocation ECHSFileToFile::copyDirectory(ElementsLocation &source, Element
|
||||
if (source_dir == destination_dir)
|
||||
copy_itself = true;
|
||||
|
||||
for (QString str : source_dir.entryList(QDir::Dirs | QDir::NoDotAndDotDot, QDir::Name))
|
||||
foreach(QString str, source_dir.entryList(QDir::Dirs | QDir::NoDotAndDotDot, QDir::Name))
|
||||
{
|
||||
if (copy_itself)
|
||||
{
|
||||
@@ -118,7 +118,7 @@ ElementsLocation ECHSFileToFile::copyDirectory(ElementsLocation &source, Element
|
||||
|
||||
//Copy all elements found in source_dir to destination_dir
|
||||
source_dir.setNameFilters(QStringList() << "*.elmt");
|
||||
for (QString str: source_dir.entryList(QDir::Files | QDir::NoDotAndDotDot, QDir::Name))
|
||||
foreach(QString str, source_dir.entryList(QDir::Files | QDir::NoDotAndDotDot, QDir::Name))
|
||||
{
|
||||
ElementsLocation sub_source(source.fileSystemPath() + "/" + str);
|
||||
copyElement(sub_source, created_location);
|
||||
@@ -211,7 +211,7 @@ ElementsLocation ECHSXmlToFile::copyDirectory(ElementsLocation &source, Elements
|
||||
XmlElementCollection *project_collection = source.projectCollection();
|
||||
|
||||
QStringList directories_names = project_collection->directoriesNames( project_collection->directory(source.collectionPath(false)) );
|
||||
for (QString name : directories_names)
|
||||
foreach(QString name, directories_names)
|
||||
{
|
||||
ElementsLocation sub_source_dir(source.projectCollectionPath() + "/" + name);
|
||||
copyDirectory(sub_source_dir, created_location);
|
||||
@@ -219,7 +219,7 @@ ElementsLocation ECHSXmlToFile::copyDirectory(ElementsLocation &source, Elements
|
||||
|
||||
//Create all elements found in source to destination
|
||||
QStringList elements_names = project_collection->elementsNames( project_collection->directory(source.collectionPath(false))) ;
|
||||
for (QString name : elements_names)
|
||||
foreach (QString name, elements_names)
|
||||
{
|
||||
ElementsLocation source_element(source.projectCollectionPath() + "/" + name);
|
||||
copyElement(source_element, created_location);
|
||||
|
||||
Reference in New Issue
Block a user