diff --git a/src/ui/appinfo/appinfomanager.cpp b/src/ui/appinfo/appinfomanager.cpp index 7ba63da9..5e5ff68a 100644 --- a/src/ui/appinfo/appinfomanager.cpp +++ b/src/ui/appinfo/appinfomanager.cpp @@ -15,7 +15,7 @@ namespace { const QLoggingCategory LC("appInfo"); -constexpr int DATABASE_USER_VERSION = 5; +constexpr int DATABASE_USER_VERSION = 6; constexpr int APP_CACHE_MAX_COUNT = 2000; diff --git a/src/ui/conf/confappmanager.cpp b/src/ui/conf/confappmanager.cpp index ea80dac7..2775037d 100644 --- a/src/ui/conf/confappmanager.cpp +++ b/src/ui/conf/confappmanager.cpp @@ -263,7 +263,7 @@ void ConfAppManager::logBlockedApp(const LogEntryBlocked &logEntry) if (appIdByPath(appPath) > 0) return; // already added by user - const QString appName = IoC()->appName(appOriginPath); + const QString appName = IoC()->appName(appPath); App app; app.blocked = logEntry.blocked(); diff --git a/src/ui/form/prog/programeditdialog.cpp b/src/ui/form/prog/programeditdialog.cpp index 33873b7e..56fc4a37 100644 --- a/src/ui/form/prog/programeditdialog.cpp +++ b/src/ui/form/prog/programeditdialog.cpp @@ -646,8 +646,13 @@ void ProgramEditDialog::fillEditName() if (appPath.isEmpty()) return; - const QString appName = - isWildcard() ? appPath.replace('\n', ' ') : IoC()->appName(appPath); + QString appName; + if (isWildcard()) { + appName = appPath.left(64).replace('\n', ' '); + } else { + appPath = FileUtil::normalizePath(appPath); + appName = IoC()->appName(appPath); + } m_editName->setText(appName); }