0

I have a draggable widget in flutter... it has many things such as:

            onDraggableCanceled: (e, q) {
             // do something
            },
            onDragCompleted: () {
              // do something
            },
            onDragEnd: (l) {
              // do something
            },

But, I want to check if the object should be allowed to be draggable before it drags. Basically, is there a thing called,

allowedToDrag () {
// check if allowed based on parameter, and if it is then drag, if not, dont
}

Is there something like this I can do for my draggable? Thanks!

2
  • How are you using draggable widget? Just don't wrap the widget by draggable widget. May 28, 2020 at 1:42
  • @SanjaySharma I am wrapping it in a draggable widget. My whole problem is that I have multiple draggable widgets on the same page and I only want 1 of those draggables to be draggable at the same time (not a problem maxSimiltanousDrags can fix). May 29, 2020 at 1:24

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.