From e7817210488dafcf8c674c2ce92c71ba41675a80 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 5 Nov 2023 20:21:19 +0300 Subject: =?UTF-8?q?fixes=20#3807=20(Popup+:=20=D0=BD=D0=B0=D1=81=D1=82?= =?UTF-8?q?=D1=80=D0=BE=D0=B9=D0=BA=D0=B0=20YAMN=20"=D0=B2=D1=81=D0=B5?= =?UTF-8?q?=D0=B3=D0=B4=D0=B0=20=D0=BF=D0=BE=D0=BA=D0=B0=D0=B7=D1=8B=D0=B2?= =?UTF-8?q?=D0=B0=D1=82=D1=8C=20=D0=B2=D1=81=D0=BF=D0=BB.=D0=BE=D0=BA?= =?UTF-8?q?=D0=BD=D0=B0"=20=D0=B8=D0=BC=D0=B5=D0=B5=D1=82=20=D0=BF=D1=80?= =?UTF-8?q?=D0=B8=D0=BE=D1=80=D0=B8=D1=82=D0=B5=D1=82=20=D0=BF=D0=B5=D1=80?= =?UTF-8?q?=D0=B5=D0=B4=20=D0=B3=D0=BB=D1=83=D1=88=D0=B5=D0=BD=D0=B8=D0=B5?= =?UTF-8?q?=D0=BC=20=D0=BE=D0=BA=D0=BE=D0=BD=20=D0=B2=20idle)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugins/Popup/src/main.cpp | 3 +++ plugins/Popup/src/services.cpp | 5 +---- plugins/Popup/src/stdafx.h | 2 ++ 3 files changed, 6 insertions(+), 4 deletions(-) (limited to 'plugins') diff --git a/plugins/Popup/src/main.cpp b/plugins/Popup/src/main.cpp index 04ee826c2e..e1ba577864 100644 --- a/plugins/Popup/src/main.cpp +++ b/plugins/Popup/src/main.cpp @@ -237,6 +237,9 @@ static int ModulesLoaded(WPARAM, LPARAM) LoadActions(); LoadNotifications(); + // register idle mode switcher + HookEvent(ME_IDLE_CHANGED, OnIdleChanged); + // hook TopToolBar HookEvent(ME_TTB_MODULELOADED, TTBLoaded); diff --git a/plugins/Popup/src/services.cpp b/plugins/Popup/src/services.cpp index 48a73fc864..32a9f4d4c7 100644 --- a/plugins/Popup/src/services.cpp +++ b/plugins/Popup/src/services.cpp @@ -475,7 +475,7 @@ static INT_PTR Popup_LoadSkin(WPARAM, LPARAM lParam) return 1; } -static int OnIdleChanged(WPARAM, LPARAM lParam) +int OnIdleChanged(WPARAM, LPARAM lParam) { g_bIdleMode = (lParam & IDF_ISIDLE) != 0; return 0; @@ -514,7 +514,4 @@ void CreateServices() CreateServiceFunction(MS_POPUP_DESTROYPOPUP, Popup_DeletePopup); CreateServiceFunction("Popup/LoadSkin", Popup_LoadSkin); - - // register idle mode switcher - HookEvent(ME_IDLE_CHANGED, OnIdleChanged); } diff --git a/plugins/Popup/src/stdafx.h b/plugins/Popup/src/stdafx.h index 8d297fd0e0..6cfca9e544 100644 --- a/plugins/Popup/src/stdafx.h +++ b/plugins/Popup/src/stdafx.h @@ -139,4 +139,6 @@ INT_PTR svcEnableDisableMenuCommand(WPARAM, LPARAM); void InitIcons(); void CreateServices(); +int OnIdleChanged(WPARAM, LPARAM lParam); + #endif //HEADERS_H -- cgit v1.2.3