From 5c0b5c7430c405c71db9eff990fbfdd6fbfcd4cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luis=20=C3=81ngel=20San=20Mart=C3=ADn?= Date: Fri, 7 Apr 2023 10:51:05 +0200 Subject: [PATCH] Add method for getting the db container path from a library id --- YACReaderLibrary/yacreader_libraries.cpp | 5 +++++ YACReaderLibrary/yacreader_libraries.h | 1 + 2 files changed, 6 insertions(+) diff --git a/YACReaderLibrary/yacreader_libraries.cpp b/YACReaderLibrary/yacreader_libraries.cpp index ad83731c..0861df21 100644 --- a/YACReaderLibrary/yacreader_libraries.cpp +++ b/YACReaderLibrary/yacreader_libraries.cpp @@ -29,6 +29,11 @@ QString YACReaderLibraries::getPath(int id) return ""; } +QString YACReaderLibraries::getDBPath(int id) +{ + return getPath(id) + "/.yacreaderlibrary"; +} + QString YACReaderLibraries::getName(int id) { foreach (QString name, libraries.keys()) diff --git a/YACReaderLibrary/yacreader_libraries.h b/YACReaderLibrary/yacreader_libraries.h index 12e096e6..a536c80b 100644 --- a/YACReaderLibrary/yacreader_libraries.h +++ b/YACReaderLibrary/yacreader_libraries.h @@ -13,6 +13,7 @@ public: QList getNames(); QString getPath(const QString &name); QString getPath(int id); + QString getDBPath(int id); QString getName(int id); bool isEmpty(); bool contains(const QString &name);