Fix drag and drop functionality.