DragData.fromJson constructor

DragData.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory DragData.fromJson(Map<String, dynamic> json) {
  return DragData(
    items: (json['items'] as List)
        .map((e) => DragDataItem.fromJson(e as Map<String, dynamic>))
        .toList(),
    files: json.containsKey('files')
        ? (json['files'] as List).map((e) => e as String).toList()
        : null,
    dragOperationsMask: json['dragOperationsMask'] as int,
  );
}