File tree Expand file tree Collapse file tree 2 files changed +0
-24
lines changed Expand file tree Collapse file tree 2 files changed +0
-24
lines changed Original file line number Diff line number Diff line change @@ -453,29 +453,6 @@ void DesktopEntryManager::handleFileChanges() {
453
453
QThreadPool::globalInstance ()->start (scanner);
454
454
}
455
455
456
- QString DesktopEntryManager::extractIdFromPath (const QString& path) {
457
- const auto fi = QFileInfo (path);
458
- const auto canon = fi.canonicalFilePath ();
459
- const auto actual = canon.isEmpty () ? fi.absoluteFilePath () : canon;
460
- for (const auto & rootPath: DesktopEntryManager::desktopPaths ()) {
461
- auto root = QDir (rootPath);
462
- const auto rel = root.relativeFilePath (actual);
463
- if (!rel.startsWith (" ../" )) {
464
- auto relInfo = QFileInfo (rel);
465
- auto id = QString ();
466
- if (relInfo.path () != " ." && !relInfo.path ().isEmpty ()) {
467
- id = relInfo.path ();
468
- id.replace (' /' , ' -' );
469
- id += ' -' + relInfo.completeBaseName ();
470
- } else {
471
- id = relInfo.completeBaseName ();
472
- }
473
- return id;
474
- }
475
- }
476
- return fi.completeBaseName ();
477
- }
478
-
479
456
const QStringList& DesktopEntryManager::desktopPaths () {
480
457
static const auto paths = []() {
481
458
auto dataPaths = QStringList ();
Original file line number Diff line number Diff line change @@ -261,7 +261,6 @@ class DesktopEntryManager: public QObject {
261
261
262
262
static DesktopEntryManager* instance ();
263
263
264
- static QString extractIdFromPath (const QString& path);
265
264
static const QStringList& desktopPaths ();
266
265
267
266
signals:
You can’t perform that action at this time.
0 commit comments