summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/StatusManager/src/AdvancedAutoAway/aaa_options.cpp5
-rw-r--r--plugins/StatusManager/src/AdvancedAutoAway/advancedautoaway.h5
-rw-r--r--plugins/StatusManager/src/StartupStatus/ss_options.cpp5
-rw-r--r--plugins/StatusManager/src/StartupStatus/startupstatus.cpp5
-rw-r--r--plugins/StatusManager/src/StartupStatus/startupstatus.h10
-rw-r--r--plugins/StatusManager/src/options.cpp18
-rw-r--r--plugins/StatusManager/src/stdafx.h12
7 files changed, 34 insertions, 26 deletions
diff --git a/plugins/StatusManager/src/AdvancedAutoAway/aaa_options.cpp b/plugins/StatusManager/src/AdvancedAutoAway/aaa_options.cpp
index 63971adcdf..df1055b5df 100644
--- a/plugins/StatusManager/src/AdvancedAutoAway/aaa_options.cpp
+++ b/plugins/StatusManager/src/AdvancedAutoAway/aaa_options.cpp
@@ -119,6 +119,11 @@ static void SetDialogStatus(HWND hwndDlg, TAAAProtoSetting *sameSetting)
/////////////////////////////////////////////////////////////////////////////////////////
// Rules dialog window procedure
+int AAACompareSettings(const TAAAProtoSetting *p1, const TAAAProtoSetting *p2)
+{
+ return mir_strcmp(p1->szName, p2->szName);
+}
+
static TAAAProtoSettingList optionSettings(10, AAACompareSettings);
static INT_PTR CALLBACK DlgProcAutoAwayRulesOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
diff --git a/plugins/StatusManager/src/AdvancedAutoAway/advancedautoaway.h b/plugins/StatusManager/src/AdvancedAutoAway/advancedautoaway.h
index 3f3a0b3c02..e6d7969743 100644
--- a/plugins/StatusManager/src/AdvancedAutoAway/advancedautoaway.h
+++ b/plugins/StatusManager/src/AdvancedAutoAway/advancedautoaway.h
@@ -72,10 +72,7 @@ struct TAAAProtoSetting : public PROTOCOLSETTINGEX, public MZeroedObject
unsigned int sts1setTimer;
};
-static int AAACompareSettings(const TAAAProtoSetting *p1, const TAAAProtoSetting *p2)
-{
- return mir_strcmp(p1->szName, p2->szName);
-}
+int AAACompareSettings(const TAAAProtoSetting *p1, const TAAAProtoSetting *p2);
struct AAMSGSETTING
{
diff --git a/plugins/StatusManager/src/StartupStatus/ss_options.cpp b/plugins/StatusManager/src/StartupStatus/ss_options.cpp
index eaa5566820..22372bcb1f 100644
--- a/plugins/StatusManager/src/StartupStatus/ss_options.cpp
+++ b/plugins/StatusManager/src/StartupStatus/ss_options.cpp
@@ -21,6 +21,11 @@
/////////////////////////////////////////////////////////////////////////////////////////
+int SSCompareSettings(const TSSSetting *p1, const TSSSetting *p2)
+{
+ return mir_strcmp(p1->szName, p2->szName);
+}
+
TSettingsList* GetCurrentProtoSettings()
{
int count;
diff --git a/plugins/StatusManager/src/StartupStatus/startupstatus.cpp b/plugins/StatusManager/src/StartupStatus/startupstatus.cpp
index b9de70b28c..7376d1a03c 100644
--- a/plugins/StatusManager/src/StartupStatus/startupstatus.cpp
+++ b/plugins/StatusManager/src/StartupStatus/startupstatus.cpp
@@ -485,6 +485,11 @@ HANDLE hSSModuleLoadedHook = NULL,
hGetProfileCountService,
hGetProfileNameService;
+static INT_PTR SrvGetProfile(WPARAM wParam, LPARAM lParam)
+{
+ return GetProfile((int)wParam, *(TSettingsList*)lParam);
+}
+
void StartupStatusLoad()
{
MUUID muidLast = MIID_LAST;
diff --git a/plugins/StatusManager/src/StartupStatus/startupstatus.h b/plugins/StatusManager/src/StartupStatus/startupstatus.h
index e1ad779103..5d04c24cf5 100644
--- a/plugins/StatusManager/src/StartupStatus/startupstatus.h
+++ b/plugins/StatusManager/src/StartupStatus/startupstatus.h
@@ -30,10 +30,7 @@ struct TSSSetting : public PROTOCOLSETTINGEX, public MZeroedObject
~TSSSetting();
};
-static int SSCompareSettings(const TSSSetting *p1, const TSSSetting *p2)
-{
- return mir_strcmp(p1->szName, p2->szName);
-}
+int SSCompareSettings(const TSSSetting *p1, const TSSSetting *p2);
typedef OBJLIST<TSSSetting> TSettingsList;
@@ -148,11 +145,6 @@ TSettingsList* GetCurrentProtoSettings();
int GetProfile(int profileID, TSettingsList& arSettings );
wchar_t *GetStatusMessage(int profile, char *szProto);
-static INT_PTR SrvGetProfile(WPARAM wParam, LPARAM lParam)
-{
- return GetProfile((int)wParam, *(TSettingsList*)lParam);
-}
-
INT_PTR LoadAndSetProfile(WPARAM wParam, LPARAM lParam);
INT_PTR GetProfileCount(WPARAM wParam, LPARAM lParam);
INT_PTR GetProfileName(WPARAM wParam, LPARAM lParam);
diff --git a/plugins/StatusManager/src/options.cpp b/plugins/StatusManager/src/options.cpp
index c6fe45bda4..cb3d19e7fe 100644
--- a/plugins/StatusManager/src/options.cpp
+++ b/plugins/StatusManager/src/options.cpp
@@ -1,7 +1,21 @@
#include "stdafx.h"
-CSubPluginsOptionsDlg::CSubPluginsOptionsDlg()
- : CPluginDlgBase(hInst, IDD_OPT_SUBPLUGINS, MODULENAME),
+bool IsSubPluginEnabled(const char *name)
+{
+ // Check if this plugin was disabled as separate dll
+ CMStringA dllName(FORMAT, "%s.dll", name);
+ dllName.MakeLower();
+ int dllEnabled = !db_get_b(NULL, "PluginDisable", dllName);
+
+ char setting[128];
+ mir_snprintf(setting, "%s_enabled", name);
+ return db_get_b(NULL, MODULENAME, setting, dllEnabled) != 0;
+}
+
+/////////////////////////////////////////////////////////////////////////////////////////
+
+CSubPluginsOptionsDlg::CSubPluginsOptionsDlg() :
+ CPluginDlgBase(hInst, IDD_OPT_SUBPLUGINS, MODULENAME),
m_enableKeepStatus(this, IDC_ENABLE_KEEPSTATUS),
m_enableStartupStatus(this, IDC_ENABLE_STARTUPSTATUS),
m_enableAdvancedAutoAway(this, IDC_ENABLE_ADVANCEDAUTOAWAY)
diff --git a/plugins/StatusManager/src/stdafx.h b/plugins/StatusManager/src/stdafx.h
index f82e4ae86a..fbf6746322 100644
--- a/plugins/StatusManager/src/stdafx.h
+++ b/plugins/StatusManager/src/stdafx.h
@@ -35,17 +35,7 @@
extern HINSTANCE hInst;
-static BYTE IsSubPluginEnabled(const char* name)
-{
- // Check if this plugin was disabled as separate dll
- CMStringA dllName(FORMAT, "%s.dll", name);
- dllName.MakeLower();
- bool dllEnabled = !db_get_b(NULL, "PluginDisable", dllName);
-
- char setting[128];
- mir_snprintf(setting, "%s_enabled", name);
- return db_get_b(NULL, MODULENAME, setting, dllEnabled ? 1 : 0);
-}
+bool IsSubPluginEnabled(const char *name);
class CSubPluginsOptionsDlg : CPluginDlgBase
{