Cleanup: use BLI_str_utf8 prefix
Rename: - BLI_str_utf8_invalid_byte (was BLI_utf8_invalid_byte) - BLI_str_utf8_invalid_strip (was BLI_utf8_invalid_strip)
This commit is contained in:
@@ -3350,7 +3350,7 @@ static bool ui_textedit_copypaste(uiBut *but, uiHandleButtonData *data, const in
|
||||
|
||||
if (pbuf) {
|
||||
if (UI_but_is_utf8(but)) {
|
||||
buf_len -= BLI_utf8_invalid_strip(pbuf, (size_t)buf_len);
|
||||
buf_len -= BLI_str_utf8_invalid_strip(pbuf, (size_t)buf_len);
|
||||
}
|
||||
|
||||
ui_textedit_insert_buf(but, data, pbuf, buf_len);
|
||||
@@ -3527,7 +3527,7 @@ static void ui_textedit_end(bContext *C, uiBut *but, uiHandleButtonData *data)
|
||||
|
||||
if (but) {
|
||||
if (UI_but_is_utf8(but)) {
|
||||
const int strip = BLI_utf8_invalid_strip(but->editstr, strlen(but->editstr));
|
||||
const int strip = BLI_str_utf8_invalid_strip(but->editstr, strlen(but->editstr));
|
||||
/* not a file?, strip non utf-8 chars */
|
||||
if (strip) {
|
||||
/* won't happen often so isn't that annoying to keep it here for a while */
|
||||
|
||||
Reference in New Issue
Block a user