[openjk] 16/130: Implement method remove
Simon McVittie
smcv at debian.org
Fri Oct 28 11:09:12 UTC 2016
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to branch debian/master
in repository openjk.
commit 95c4ceb7f5f0fa92114d9365fab5df7d961c1ab5
Author: bibendovsky <bibendovsky at NOSTROMO>
Date: Sun Jul 3 23:26:34 2016 +0300
Implement method remove
---
shared/qcommon/ojk_sg_archive.cpp | 9 ++++++---
shared/qcommon/ojk_sg_archive_fwd.h | 2 +-
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/shared/qcommon/ojk_sg_archive.cpp b/shared/qcommon/ojk_sg_archive.cpp
index 6edbd9d..b65a84f 100644
--- a/shared/qcommon/ojk_sg_archive.cpp
+++ b/shared/qcommon/ojk_sg_archive.cpp
@@ -140,10 +140,13 @@ void Archive::rename(
}
void Archive::remove(
- const std::string& file_path)
+ const std::string& base_file_name)
{
- throw ArchiveException(
- "Not implemented.");
+ auto path = generate_path(
+ base_file_name);
+
+ ::FS_DeleteUserGenFile(
+ path.c_str());
}
Archive& Archive::get_instance()
diff --git a/shared/qcommon/ojk_sg_archive_fwd.h b/shared/qcommon/ojk_sg_archive_fwd.h
index 94da627..98fe193 100644
--- a/shared/qcommon/ojk_sg_archive_fwd.h
+++ b/shared/qcommon/ojk_sg_archive_fwd.h
@@ -118,7 +118,7 @@ public:
// Remove a saved game file.
static void remove(
- const std::string& file_path);
+ const std::string& base_file_name);
// Returns a default instance of the class.
static Archive& get_instance();
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/openjk.git
More information about the Pkg-games-commits
mailing list