1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:38:11 +00:00

Userland: Store MIME keys as String in Core::MimeData

This commit is contained in:
Karol Kosek 2023-08-21 17:06:49 +02:00 committed by Sam Atkins
parent 4f638d3af2
commit 2f35348104
13 changed files with 22 additions and 22 deletions

View file

@ -125,10 +125,10 @@ RefPtr<Core::MimeData> Model::mime_data(ModelSelection const& selection) const
}
});
mime_data->set_data(drag_data_type(), data_builder.to_byte_buffer().release_value_but_fixme_should_propagate_errors());
mime_data->set_data(MUST(String::from_utf8(drag_data_type())), data_builder.to_byte_buffer().release_value_but_fixme_should_propagate_errors());
mime_data->set_text(text_builder.to_deprecated_string());
if (bitmap)
mime_data->set_data("image/x-raw-bitmap", bitmap->serialize_to_byte_buffer().release_value_but_fixme_should_propagate_errors());
mime_data->set_data("image/x-raw-bitmap"_string, bitmap->serialize_to_byte_buffer().release_value_but_fixme_should_propagate_errors());
return mime_data;
}