From 05ccb4dcd0b507fb000426667ed3f25c0b93db2b Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 23 Jun 2013 11:37:58 +0000 Subject: db_set_resident - helper for MIDataBase::SetSettingResident git-svn-id: http://svn.miranda-ng.org/main/trunk@5093 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/mir_core/db.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/mir_core/db.cpp') diff --git a/src/mir_core/db.cpp b/src/mir_core/db.cpp index 82013cc3f3..7b04b6eab4 100644 --- a/src/mir_core/db.cpp +++ b/src/mir_core/db.cpp @@ -311,3 +311,14 @@ extern "C" MIR_CORE_DLL(void) db_setCurrent(MIDatabase* _db) { currDb = _db; } + +MIR_CORE_DLL(BOOL) db_set_resident(const char *szModule, const char *szService, BOOL bEnable) +{ + if (currDb == NULL || szModule == NULL || szService == NULL) + return FALSE; + + char str[MAXMODULELABELLENGTH * 2]; + strncpy_s(str,szModule,strlen(szModule)); + strncat_s(str,szService,strlen(szService)); + return currDb->SetSettingResident(bEnable, str); +} -- cgit v1.2.3