From c7fbc52e7af7c756a3b17e9f8f3693d58163157e Mon Sep 17 00:00:00 2001 From: kelson42 Date: Thu, 5 May 2011 05:39:09 +0000 Subject: [PATCH] + new core content mgmt imp. --- src/common/kiwix/manager.cpp | 9 +++++++++ src/common/kiwix/manager.h | 2 ++ 2 files changed, 11 insertions(+) diff --git a/src/common/kiwix/manager.cpp b/src/common/kiwix/manager.cpp index 3f6e6048c..a1212e292 100644 --- a/src/common/kiwix/manager.cpp +++ b/src/common/kiwix/manager.cpp @@ -134,6 +134,15 @@ namespace kiwix { return true; } + bool Manager::setCurrentBookId(const string id) { + library.current = id; + return true; + } + + string Manager::getCurrentBookId() { + return library.current; + } + bool Manager::addBookFromPath(const string path, const string url) { kiwix::Book book; diff --git a/src/common/kiwix/manager.h b/src/common/kiwix/manager.h index da9e879ae..d3909bc6e 100644 --- a/src/common/kiwix/manager.h +++ b/src/common/kiwix/manager.h @@ -40,6 +40,8 @@ namespace kiwix { bool writeFile(const string path); bool removeBookByIndex(const unsigned int bookIndex); bool removeBookById(const string id); + bool setCurrentBookId(const string id); + string getCurrentBookId(); bool addBookFromPath(const string path, const string url = ""); Library cloneLibrary();