Better text selection
This commit is contained in:
@@ -117,6 +117,16 @@ impl WindowController {
|
||||
self.proxy.set_primary_selection_text(self.id, text)
|
||||
}
|
||||
|
||||
/// Copies plain text to the platform clipboard for this window.
|
||||
pub fn set_clipboard_text(&self, text: impl Into<String>) -> Result<(), PlatformClosed> {
|
||||
self.proxy.set_clipboard_text(self.id, text)
|
||||
}
|
||||
|
||||
/// Requests the current plain-text clipboard contents from the platform.
|
||||
pub fn request_clipboard_text(&self) -> Result<(), PlatformClosed> {
|
||||
self.proxy.request_clipboard_text(self.id)
|
||||
}
|
||||
|
||||
/// Requests the current plain-text primary selection contents from the platform.
|
||||
pub fn request_primary_selection_text(&self) -> Result<(), PlatformClosed> {
|
||||
self.proxy.request_primary_selection_text(self.id)
|
||||
|
||||
Reference in New Issue
Block a user