MCPcopy Create free account
hub / github.com/Tencent/libpag / MakeDir

Function MakeDir

viewer/src/utils/FileUtils.cpp:71–84  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69}
70
71bool MakeDir(const QString& path, bool isDir) {
72 QString dirPath;
73 QFileInfo fileInfo(path);
74 if (isDir) {
75 dirPath = path;
76 } else {
77 dirPath = fileInfo.absolutePath();
78 }
79 QDir dir(dirPath);
80 if (dir.exists()) {
81 return true;
82 }
83 return dir.mkpath(dirPath);
84}
85
86bool WriteFileToDisk(const std::shared_ptr<File>& file, const QString& filePath) {
87 auto encodeByteData = pag::Codec::Encode(file);

Callers 1

PAGExportPNGTaskMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected