Disable swipe gestures while in edit mode

This commit is contained in:
QuantumEntangledAndy 2024-10-17 08:29:33 +07:00
parent 725cfdebca
commit 83182245d6
No known key found for this signature in database
GPG Key ID: 3EB4B66F30C609B6
1 changed files with 12 additions and 0 deletions

View File

@ -933,6 +933,12 @@ export function initRossMods() {
if (!$(e.target).closest('#sheld').length) { if (!$(e.target).closest('#sheld').length) {
return; return;
} }
if ($('#curEditTextarea')) {
// Don't swipe while in text edit mode
// the ios selection gestures get picked up
// as swipe gestures
return;
}
var SwipeButR = $('.swipe_right:last'); var SwipeButR = $('.swipe_right:last');
var SwipeTargetMesClassParent = $(e.target).closest('.last_mes'); var SwipeTargetMesClassParent = $(e.target).closest('.last_mes');
if (SwipeTargetMesClassParent !== null) { if (SwipeTargetMesClassParent !== null) {
@ -951,6 +957,12 @@ export function initRossMods() {
if (!$(e.target).closest('#sheld').length) { if (!$(e.target).closest('#sheld').length) {
return; return;
} }
if ($('#curEditTextarea')) {
// Don't swipe while in text edit mode
// the ios selection gestures get picked up
// as swipe gestures
return;
}
var SwipeButL = $('.swipe_left:last'); var SwipeButL = $('.swipe_left:last');
var SwipeTargetMesClassParent = $(e.target).closest('.last_mes'); var SwipeTargetMesClassParent = $(e.target).closest('.last_mes');
if (SwipeTargetMesClassParent !== null) { if (SwipeTargetMesClassParent !== null) {