2

I have define a custom actions in my accessibilityElement:

UIAccessibilityCustomAction *action1 = ...initWithName:@"label1";
UIAccessibilityCustomAction *action2 = ...initWithName:@"label2";
element.accessibilityCustomActions = @[action1, action2];

When swipe down/up, it reads "Drag" in addition to the normal "label1", "label2", what is this "Drag" and how did it come about?

sss
  • 21
  • 3

1 Answers1

1

For anyone that comes along and sees this, I was having the same issue, and I was able to find that Apple added (sometime around iOS 11) the UITextDraggable protocol to UITextView.

This is defined as:

The interface that determines if a text view is a drag source.

This protocol has the property textDragInteraction that defaults to true for UITextViews.

You can set this property to false like this:

Swift:

textView.textDragInteraction?.isEnabled = false

Obj-C:

textView.textDragInteraction.enabled = NO;
PirateDave
  • 163
  • 1
  • 3
  • 11