summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/NewEventNotify/src/main.cpp16
1 files changed, 7 insertions, 9 deletions
diff --git a/plugins/NewEventNotify/src/main.cpp b/plugins/NewEventNotify/src/main.cpp
index 80d3975a66..fed94ffd9a 100644
--- a/plugins/NewEventNotify/src/main.cpp
+++ b/plugins/NewEventNotify/src/main.cpp
@@ -130,11 +130,7 @@ int HookedInit(WPARAM, LPARAM)
if (ServiceExists("PluginSweeper/Add"))
CallService("PluginSweeper/Add", (WPARAM)MODULE, (LPARAM)MODULE);
- if (ServiceExists(MS_MSG_GETWINDOWDATA))
- g_IsSrmmWindowAPI = 1;
- else
- g_IsSrmmWindowAPI = 0;
-
+ g_IsSrmmWindowAPI = ServiceExists(MS_MSG_GETWINDOWDATA) != 0;
return 0;
}
@@ -204,8 +200,10 @@ int CheckMsgWnd(HANDLE hContact)
mwid.uFlags = MSG_WINDOW_UFLAG_MSG_BOTH;
mwd.cbSize = sizeof(MessageWindowData);
mwd.hContact = hContact;
- if (!CallService(MS_MSG_GETWINDOWDATA, (WPARAM) &mwid, (LPARAM) &mwd)) {
- if (mwd.hwndWindow != NULL && (mwd.uState & MSG_WINDOW_STATE_EXISTS)) return 1;
- }
+ if (!CallService(MS_MSG_GETWINDOWDATA, (WPARAM) &mwid, (LPARAM) &mwd))
+ if (mwd.hwndWindow != NULL && (mwd.uState & MSG_WINDOW_STATE_EXISTS))
+ return 1;
}
-} \ No newline at end of file
+
+ return 0;
+}