diff --git a/src/backend.cpp b/src/backend.cpp index 08f88c52840954f067d934425596ae5be4f9340b..7f598107a5db94d25ff8062bc13ddf9e0e193da2 100644 --- a/src/backend.cpp +++ b/src/backend.cpp @@ -131,7 +131,7 @@ bool Backend::connectDesignStudio() qDebug() << "Project unpacked to " << projectPath; updatePopup("Running project..."); - if (!m_projectManager.runProject(projectPath, "UntitledProject35")) { + if (!m_projectManager.runProject(projectPath)) { qCritical() << "Could not run project. Please check the logs for more " "information."; } else { diff --git a/src/projectManager.cpp b/src/projectManager.cpp index bbece42f3fc897f4da2498e3070ac66966f1f976..99868b216982af9e1755c789dfae184cf3820433 100644 --- a/src/projectManager.cpp +++ b/src/projectManager.cpp @@ -164,13 +164,9 @@ QStringList ProjectManager::getImportPaths(const QString &projectPath, QStringList importPaths; for (const QString &path : importPathsMatch.captured(1).split(",")) { - qDebug() << "verbose:: Found import path: " << path; QString cleanedPath = path.trimmed(); - qDebug() << "verbose:: Cleaned import path: " << cleanedPath; cleanedPath = projectPath + "/" + cleanedPath.mid(1, cleanedPath.length() - 2); - qDebug() << "verbose:: Cleaned import path: " << cleanedPath; if (QFileInfo::exists(cleanedPath)) { - qDebug() << "verbose:: Adding import path: " << cleanedPath; importPaths.append(cleanedPath); } } @@ -185,7 +181,7 @@ bool ProjectManager::isQt6Project(const QString &qmlProjectFileContent) return qt6ProjectMatch.hasMatch(); } -bool ProjectManager::runProject(const QString &projectPath, const QString &projectName) +bool ProjectManager::runProject(const QString &projectPath) { qDebug() << "Project location: " << projectPath; @@ -396,11 +392,10 @@ bool ProjectManager::isProjectCached(const QJsonObject &projectInfo) bool ProjectManager::runCachedProject(const QJsonObject &projectInfo) { const QString projectId = projectInfo.value("id").toString(); - const QString projectName = projectInfo.value("appName").toString(); qDebug() << "Running cached project " << projectId; const QString projectPath = m_projectCachePath + "/" + projectId; - return runProject(projectPath, projectName); + return runProject(projectPath); } bool ProjectManager::cacheDemoProject(const QByteArray &projectData, const QString &projectName) @@ -460,7 +455,7 @@ bool ProjectManager::runDemoProject(const QString &projectName) { const QString demoProjectPath = m_demoProjectCachePath + "/" + projectName; qDebug() << "Running demo project " << projectName << " from " << demoProjectPath; - return runProject(demoProjectPath, projectName); + return runProject(demoProjectPath); } void ProjectManager::orientateWindow(Qt::ScreenOrientation orientation) diff --git a/src/projectManager.h b/src/projectManager.h index 3a2cfdbf35a47726f36c327e1dfdc303788067ce..6fad257544a894c3fc000bae78c29803c597dbab 100644 --- a/src/projectManager.h +++ b/src/projectManager.h @@ -40,7 +40,7 @@ public: explicit ProjectManager(QObject *parent = nullptr); QString unpackProject(const QByteArray &project, bool extractZip = false); - bool runProject(const QString &projectPath, const QString &projectName); + bool runProject(const QString &projectPath); bool cacheProject(const QByteArray &projectData, const QJsonObject &projectInfo); bool isProjectCached(const QJsonObject &projectInfo);