summaryrefslogtreecommitdiff
path: root/plugins/TranslitSwitcher/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2023-09-25 13:41:55 +0300
committerGeorge Hazan <george.hazan@gmail.com>2023-09-25 13:41:55 +0300
commitc6f59d75142b7568dd89f5cff691b0b58030aafd (patch)
tree6fd83d9e6a71bbf7a750a1983922121265acadd7 /plugins/TranslitSwitcher/src
parent53669871fc860856c80c2d79cb6b21d52ea25440 (diff)
SmileyAdd: fix for the obsolete quirks in SmaileyAdd API
Diffstat (limited to 'plugins/TranslitSwitcher/src')
-rw-r--r--plugins/TranslitSwitcher/src/Layoutproc.cpp17
1 files changed, 7 insertions, 10 deletions
diff --git a/plugins/TranslitSwitcher/src/Layoutproc.cpp b/plugins/TranslitSwitcher/src/Layoutproc.cpp
index 5ac0ba1115..33183d9615 100644
--- a/plugins/TranslitSwitcher/src/Layoutproc.cpp
+++ b/plugins/TranslitSwitcher/src/Layoutproc.cpp
@@ -19,7 +19,7 @@ Boston, MA 02111-1307, USA.
#include "stdafx.h"
-SMADD_BATCHPARSE2 smgp;
+SMADD_BATCHPARSE smgp;
SMADD_BATCHPARSERES *smileyPrs = nullptr;
bool isItSmiley(unsigned int position)
@@ -399,9 +399,8 @@ void SwitchLayout(bool lastword)
if (ServiceExists(MS_SMILEYADD_BATCHPARSE)) {
memset(&smgp, 0, sizeof(smgp));
- smgp.cbSize = sizeof(smgp);
- smgp.str = buf;
- smgp.flag = SAFL_TCHAR;
+ smgp.str.w = buf;
+ smgp.flag = SAFL_UNICODE;
smileyPrs = (SMADD_BATCHPARSERES *)CallService(MS_SMILEYADD_BATCHPARSE, 0, (LPARAM)&smgp);
}
@@ -449,9 +448,8 @@ void SwitchLayout(bool lastword)
if (slen != 0) {
if (ServiceExists(MS_SMILEYADD_BATCHPARSE)) {
memset(&smgp, 0, sizeof(smgp));
- smgp.cbSize = sizeof(smgp);
- smgp.str = sel;
- smgp.flag = SAFL_TCHAR;
+ smgp.str.w = sel;
+ smgp.flag = SAFL_UNICODE;
smileyPrs = (SMADD_BATCHPARSERES *)CallService(MS_SMILEYADD_BATCHPARSE, 0, (LPARAM)&smgp);
}
@@ -672,9 +670,8 @@ int OnButtonPressed(WPARAM, LPARAM lParam)
HKL hkl = GetKeyboardLayout(dwThreadID);
memset(&smgp, 0, sizeof(smgp));
- smgp.cbSize = sizeof(smgp);
- smgp.str = sel;
- smgp.flag = SAFL_TCHAR;
+ smgp.str.w = sel;
+ smgp.flag = SAFL_UNICODE;
if (ServiceExists(MS_SMILEYADD_BATCHPARSE))
smileyPrs = (SMADD_BATCHPARSERES *)CallService(MS_SMILEYADD_BATCHPARSE, 0, (LPARAM)&smgp);