equal
deleted
inserted
replaced
73 |
73 |
74 return result; |
74 return result; |
75 } |
75 } |
76 |
76 |
77 |
77 |
78 QFile * HWDataManager::findFileForRead( |
78 QString HWDataManager::findFileForRead( |
79 const QString & relativeDataFilePath) const |
79 const QString & relativeDataFilePath) const |
80 { |
80 { |
81 QFile * file = |
81 QString path = userData->absolutePath()+"/"+relativeDataFilePath; |
82 new QFile(userData->absolutePath()+"/"+relativeDataFilePath); |
82 |
83 if (!file->exists()) |
83 if (!QFile::exists(path)) |
84 { |
84 path = defaultData->absolutePath()+"/"+relativeDataFilePath; |
85 delete file; |
85 |
86 file = new QFile(defaultData->absolutePath()+"/"+relativeDataFilePath); |
86 return path; |
87 } |
|
88 return file; |
|
89 } |
87 } |
90 |
88 |
91 |
89 |
92 QFile * HWDataManager::findFileForWrite( |
90 QFile * HWDataManager::findFileForWrite( |
93 const QString & relativeDataFilePath) const |
91 const QString & relativeDataFilePath) const |