MCPcopy Create free account
hub / github.com/KDE/kdiff3 / mkDirImp

Method mkDirImp

src/DefaultFileAccessJobHandler.cpp:215–237  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

213#endif
214
215bool DefaultFileAccessJobHandler::mkDirImp(const QString& dirName)
216{
217 if(dirName.isEmpty())
218 return false;
219
220 FileAccess dir(dirName);
221 if(dir.isLocal())
222 {
223 return QDir().mkdir(dir.absoluteFilePath());
224 }
225 else
226 {
227 m_bSuccess = false;
228#if HAS_KFKIO
229 KIO::SimpleJob* pJob = KIO::mkdir(dir.url());
230 chk_connect(pJob, &KIO::SimpleJob::result, this, &DefaultFileAccessJobHandler::slotSimpleJobResult);
231 chk_connect(pJob, &KIO::SimpleJob::finished, this, &DefaultFileAccessJobHandler::slotJobEnded);
232
233 ProgressProxy::enterEventLoop(pJob, i18nc("Message for progress dialog %1 = path to file", "Making folder: %1", dirName));
234#endif
235 return m_bSuccess;
236 }
237}
238
239bool DefaultFileAccessJobHandler::rmDirImp(const QString& dirName)
240{

Callers 1

mkDirMethod · 0.45

Calls 3

isEmptyMethod · 0.45
isLocalMethod · 0.45
absoluteFilePathMethod · 0.45

Tested by

no test coverage detected