Skip to content

Commit 949e362

Browse files
committed
Небольшие исправления.
1 parent 96fe5e7 commit 949e362

File tree

3 files changed

+25
-7
lines changed

3 files changed

+25
-7
lines changed

src/include/core_as/sstring.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -394,6 +394,18 @@ class str_algs {
394394
return false;
395395
return !myLen || 0 == traits::compare(text.c_str(), _str(), myLen);
396396
}
397+
// Заканчивается ли строка указанной подстрокой
398+
bool isSuffixed(SimpleStr suffix) {
399+
return suffix.length() <= _len() && (suffix.length() == 0 || (*this)(-int(suffix.length())).isEqual(suffix));
400+
}
401+
// Заканчивается ли строка указанной подстрокой без учета регистра ASCII
402+
bool isSuffixedia(SimpleStr suffix) {
403+
return suffix.length() <= _len() && (suffix.length() == 0 || (*this)(-int(suffix.length())).isEqualia(suffix));
404+
}
405+
// Заканчивается ли строка указанной подстрокой без учета регистра UNICODE
406+
bool isSuffixediu(SimpleStr suffix) {
407+
return suffix.length() <= _len() && (suffix.length() == 0 || (*this)(-int(suffix.length())).isEqualiu(suffix));
408+
}
397409

398410
bool isAscii() const noexcept {
399411
if (_isEmpty())

src/include/core_as/version.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
#define F_VERSION 1,0,0,6
2-
#define P_VERSION "1.0.0.6"
1+
#define F_VERSION 1,0,0,7
2+
#define P_VERSION "1.0.0.7"
33
#define COPY_RIGHT "© Àëåêñàíäð Îðåôêîâ, 2021"

src/starter/starter.cpp

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -238,25 +238,31 @@ void processResumeInject() {
238238
}
239239
}
240240

241+
void processLoadModule(ssw msg) {
242+
coreModule->log<LogLevel::Info>(+L"Load module "_ss & msg);
243+
}
244+
241245
void processMsgFromOther(const wchar_t* msg) {
242246
wchar_t* end;
243247
long cmd = wcstol(msg, &end, 0);
244248
if (*end == ' ')
245249
++end;
250+
SimpleStrNtW tail = e_s(end);
246251
switch (cmd) {
247252
case smInject:
248-
processInject(e_s(end));
253+
processInject(tail);
249254
break;
250255
case smLoadModule:
256+
processLoadModule(tail);
251257
break;
252258
case smConnect:
253-
processConnect(e_s(end));
259+
processConnect(tail);
254260
break;
255261
case smDisconnect:
256-
processDisconnect(e_s(end));
262+
processDisconnect(tail);
257263
break;
258264
case smShowNotify:
259-
processShowNotify(e_s(end));
265+
processShowNotify(tail);
260266
break;
261267
case smStopInject:
262268
processStopInject();
@@ -265,7 +271,7 @@ void processMsgFromOther(const wchar_t* msg) {
265271
processResumeInject();
266272
break;
267273
case smBrodcast:
268-
processBroadCast(e_s(end));
274+
processBroadCast(tail);
269275
break;
270276
}
271277
}

0 commit comments

Comments
 (0)