diff options
-rw-r--r-- | src/core/stdautoaway/src/idle.cpp | 3 | ||||
-rw-r--r-- | src/core/stdautoaway/src/main.cpp | 7 | ||||
-rw-r--r-- | src/core/stdautoaway/src/stdafx.h | 4 |
3 files changed, 12 insertions, 2 deletions
diff --git a/src/core/stdautoaway/src/idle.cpp b/src/core/stdautoaway/src/idle.cpp index add27610b8..4c15eede06 100644 --- a/src/core/stdautoaway/src/idle.cpp +++ b/src/core/stdautoaway/src/idle.cpp @@ -73,12 +73,11 @@ void IdleObject_Destroy() KillTimer(nullptr, g_hTimer); } -int LoadIdleModule(void) +void LoadIdleModule(void) { IdleObject_Create(); HookEvent(ME_OPT_INITIALISE, IdleOptInit); - return 0; } void UnloadIdleModule() diff --git a/src/core/stdautoaway/src/main.cpp b/src/core/stdautoaway/src/main.cpp index 4aed198a66..36cd90920b 100644 --- a/src/core/stdautoaway/src/main.cpp +++ b/src/core/stdautoaway/src/main.cpp @@ -65,6 +65,13 @@ extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_AUTOAW int CMPlugin::Load()
{
+ LoadIdleModule();
LoadAutoAwayModule();
return 0;
}
+
+int CMPlugin::Unload()
+{
+ UnloadIdleModule();
+ return 0;
+}
diff --git a/src/core/stdautoaway/src/stdafx.h b/src/core/stdautoaway/src/stdafx.h index 98f1ef29c5..8f15893de4 100644 --- a/src/core/stdautoaway/src/stdafx.h +++ b/src/core/stdautoaway/src/stdafx.h @@ -75,6 +75,7 @@ struct CMPlugin : public PLUGIN<CMPlugin> CMPlugin();
int Load() override;
+ int Unload() override;
CMOption<BYTE> bIdleCheck, bIdleMethod, bIdleOnSaver, bIdleOnFullScr, bIdleOnLock;
CMOption<BYTE> bIdlePrivate, bIdleSoundsOff, bIdleOnTerminal, bIdleStatusLock;
@@ -85,3 +86,6 @@ struct CMPlugin : public PLUGIN<CMPlugin> void IdleObject_Destroy();
void IdleObject_Create();
+
+void LoadIdleModule();
+void UnloadIdleModule();
|