diff options
Diffstat (limited to 'plugins/ChangeKeyboardLayout')
-rw-r--r-- | plugins/ChangeKeyboardLayout/src/hook_events.cpp | 4 | ||||
-rw-r--r-- | plugins/ChangeKeyboardLayout/src/options.cpp | 6 | ||||
-rw-r--r-- | plugins/ChangeKeyboardLayout/src/text_operations.cpp | 5 |
3 files changed, 6 insertions, 9 deletions
diff --git a/plugins/ChangeKeyboardLayout/src/hook_events.cpp b/plugins/ChangeKeyboardLayout/src/hook_events.cpp index 9cdf91d010..884182159e 100644 --- a/plugins/ChangeKeyboardLayout/src/hook_events.cpp +++ b/plugins/ChangeKeyboardLayout/src/hook_events.cpp @@ -80,7 +80,7 @@ void RegPopupActions() poOptions.paActions[0].flags = PAF_ENABLED;
poOptions.paActions[0].wParam = poOptions.paActions[0].lParam = 0;
poOptions.paActions[0].lchIcon = hCopyIcon;
- CallService(MS_POPUP_REGISTERACTIONS, (WPARAM)&poOptions.paActions, 1);
+ PURegisterActions(poOptions.paActions, 1);
}
int OnIconsChanged(WPARAM, LPARAM)
@@ -187,7 +187,7 @@ LRESULT CALLBACK Keyboard_Hook(int code, WPARAM wParam, LPARAM lParam) int CALLBACK CKLPopupDlgProc(HWND hWnd, UINT uiMessage, WPARAM wParam, LPARAM lParam)
{
- LPTSTR ptszPopupText = (LPTSTR)CallService(MS_POPUP_GETPLUGINDATA, (WPARAM)hWnd, (LPARAM)&ptszPopupText);
+ LPTSTR ptszPopupText = (LPTSTR)PUGetPluginData(hWnd);
switch (uiMessage) {
case WM_COMMAND:
diff --git a/plugins/ChangeKeyboardLayout/src/options.cpp b/plugins/ChangeKeyboardLayout/src/options.cpp index a8a4e11be5..257acb225f 100644 --- a/plugins/ChangeKeyboardLayout/src/options.cpp +++ b/plugins/ChangeKeyboardLayout/src/options.cpp @@ -352,8 +352,7 @@ INT_PTR CALLBACK DlgPopupsProcOptions(HWND hWnd, UINT uiMessage, WPARAM wParam, if ((HIWORD(wParam) == BN_CLICKED )) {
ptszPopupPreviewText = (LPTSTR)mir_alloc(MaxTextSize*sizeof(wchar_t));
- POPUPDATAW_V2 pdtData = { 0 };
- pdtData.cbSize = sizeof(pdtData);
+ POPUPDATAW pdtData = { 0 };
wcsncpy(pdtData.lpwzContactName, TranslateT(MODULENAME), MAX_CONTACTNAME);
wcsncpy(pdtData.lpwzText, L"Ghbdtn? rfr ltkf&", MAX_SECONDLINE);
@@ -389,8 +388,7 @@ INT_PTR CALLBACK DlgPopupsProcOptions(HWND hWnd, UINT uiMessage, WPARAM wParam, pdtData.lpActions = poOptions.paActions;
pdtData.actionCount = 1;
pdtData.PluginWindowProc = (WNDPROC)CKLPopupDlgProc;
-
- if (PUAddPopupW( &pdtData, APF_NEWDATA) < 0)
+ if (PUAddPopupW(&pdtData) < 0)
mir_free(ptszPopupPreviewText);
}
break;
diff --git a/plugins/ChangeKeyboardLayout/src/text_operations.cpp b/plugins/ChangeKeyboardLayout/src/text_operations.cpp index d1d2d05a65..094edd431f 100644 --- a/plugins/ChangeKeyboardLayout/src/text_operations.cpp +++ b/plugins/ChangeKeyboardLayout/src/text_operations.cpp @@ -448,8 +448,7 @@ int ChangeLayout(HWND hTextWnd, BYTE TextOperation, BOOL CurrentWord) LPTSTR ptszPopupText = (LPTSTR)mir_alloc(MaxTextSize*sizeof(wchar_t));
mir_wstrcpy(ptszPopupText, ptszMBox);
- POPUPDATAW_V2 pdtData = { 0 };
- pdtData.cbSize = sizeof(pdtData);
+ POPUPDATAW pdtData = { 0 };
wcsncpy(pdtData.lpwzContactName, TranslateT(MODULENAME), MAX_CONTACTNAME);
wcsncpy(pdtData.lpwzText, ptszPopupText, MAX_SECONDLINE);
@@ -486,7 +485,7 @@ int ChangeLayout(HWND hTextWnd, BYTE TextOperation, BOOL CurrentWord) pdtData.lpActions = poOptions.paActions;
pdtData.actionCount = 1;
- if (PUAddPopupW(&pdtData, APF_NEWDATA) < 0) {
+ if (PUAddPopupW(&pdtData) < 0) {
mir_free(ptszPopupText);
MessageBox(nullptr, ptszMBox, TranslateT(MODULENAME), MB_ICONINFORMATION);
}
|