Send D&D input through paste action

Treating D&D like paste allows using D&D to input text into areas other
than the PTY, like the search bar.
This commit is contained in:
Christian Duerr 2023-02-27 08:30:39 +01:00 committed by GitHub
parent f01dea8643
commit bf58748055
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View File

@ -48,6 +48,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Window clipping when maximizing a window without decorations on Windows
- Quadrants not aligned with half blocks with built-in font
- EOT (`\x03`) escaping bracketed paste mode
- Drag & Drop not working for the search bar
### Removed

View File

@ -1320,7 +1320,7 @@ impl input::Processor<EventProxy, ActionContext<'_, Notifier, EventProxy>> {
},
WindowEvent::DroppedFile(path) => {
let path: String = path.to_string_lossy().into();
self.ctx.write_to_pty((path + " ").into_bytes());
self.ctx.paste(&(path + " "));
},
WindowEvent::CursorLeft { .. } => {
self.ctx.mouse.inside_text_area = false;