This is a migrated thread and some comments may be shown as answers.

How to dynamically change CursorOffset values

1 Answer 93 Views
Drag and Drop
This is a migrated thread and some comments may be shown as answers.
James
Top achievements
Rank 1
James asked on 19 May 2016, 04:34 PM

Hello

We have a grid that we wish to drag row items from.The rows in the grid represent items that are rectangular shapes, so in the hint function we create an image of the shape. These shapes are then dragged from the grid onto a canvas where they will be placed. Our problem is that we would like to offset the cursor so that it is in the middle of the image rather than at the top left corner.; however we do not know the size of any of the images at the time of initialising grid to be draggable.

So is there any way that we can change the cursorOffset option during the hint function?

 

1 Answer, 1 is accepted

Sort by
0
Alex Gyoshev
Telerik team
answered on 23 May 2016, 12:56 PM

Hello James,

The draggable demo shows how to update the cursorOffset dynamically. See this Dojo snippet for an example of using this in the hint function.

Regards,
Alex Gyoshev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Drag and Drop
Asked by
James
Top achievements
Rank 1
Answers by
Alex Gyoshev
Telerik team
Share this question
or