Functions | |
void | copy_to_clipboard (const std::string &text, const bool mouse) |
Copies text to the clipboard. More... | |
std::string | copy_from_clipboard (const bool mouse) |
Copies text from the clipboard. More... | |
void | handle_system_event (const SDL_Event &) |
bool | available () |
Whether wesnoth was compiled with support for a clipboard. More... | |
bool desktop::clipboard::available | ( | ) |
Whether wesnoth was compiled with support for a clipboard.
Definition at line 55 of file clipboard.cpp.
Referenced by gui2::dialogs::chat_log::view::bind(), gui2::dialogs::gamestate_inspector::controller::bind(), gui2::dialogs::lua_interpreter::controller::bind(), gui2::dialogs::custom_tod::pre_show(), gui2::dialogs::game_cache_options::pre_show(), gui2::dialogs::game_version::pre_show(), gui2::dialogs::screenshot_notification::pre_show(), gui2::dialogs::wml_error::pre_show(), and gui2::dialogs::screenshot_notification::save_screenshot().
std::string desktop::clipboard::copy_from_clipboard | ( | const bool | mouse | ) |
Copies text from the clipboard.
mouse | Is the pasting done by the mouse? |
Definition at line 39 of file clipboard.cpp.
Referenced by gui::textbox::handle_key_down(), gui2::text_box_base::paste_selection(), and gui2::password_box::paste_selection().
void desktop::clipboard::copy_to_clipboard | ( | const std::string & | text, |
const bool | mouse | ||
) |
Copies text to the clipboard.
text | The text to copy. |
mouse | Is the selection done by the mouse? On UNIX systems there are multiple clipboards and the mouse selection uses a different clipboard. Ignored on other systems. |
Definition at line 34 of file clipboard.cpp.
Referenced by gui2::dialogs::chat_log::model::chat_message_list_to_clipboard(), gui2::dialogs::wml_error::copy_report_callback(), gui2::text_box_base::copy_selection(), gui2::dialogs::game_cache_options::copy_to_clipboard_callback(), gui2::dialogs::game_version::copy_to_clipboard_callback(), gui2::dialogs::custom_tod::copy_to_clipboard_callback(), editor::editor_controller::export_selection_coords(), gui2::dialogs::gamestate_inspector::controller::handle_copy_button_clicked(), gui2::dialogs::lua_interpreter::controller::handle_copy_button_clicked(), gui::textbox::handle_key_down(), gui2::dialogs::screenshot_notification::pre_show(), gui2::dialogs::game_version::report_copy_callback(), and gui2::label::signal_handler_right_button_click().
void desktop::clipboard::handle_system_event | ( | const SDL_Event & | ) |
Definition at line 51 of file clipboard.cpp.
Referenced by events::pump().