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

LibGUI: Make the Clipboard API deal in raw byte buffers a bit more

To open up for putting not just text/plain content on the clipboard,
let's make the GUI::Clipboard API a bit more raw-data-friendly. :^)
This commit is contained in:
Andreas Kling 2020-09-05 16:16:01 +02:00
parent 802f541184
commit 51146e3075
12 changed files with 43 additions and 38 deletions

View file

@ -160,7 +160,7 @@ Tab::Tab(Type type)
hooks().on_link_click(m_link_context_menu_url, "_blank", 0);
}));
m_link_context_menu->add_action(GUI::Action::create("Copy link", [this](auto&) {
GUI::Clipboard::the().set_data(m_link_context_menu_url.to_string());
GUI::Clipboard::the().set_plain_text(m_link_context_menu_url.to_string());
}));
m_link_context_menu->add_separator();
m_link_context_menu->add_action(GUI::Action::create("Download", [this](auto&) {