mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-02-20 17:59:47 +00:00
Prefer files when handling paste event
Co-authored-by: trevor-signal <131492920+trevor-signal@users.noreply.github.com>
This commit is contained in:
@@ -56,11 +56,14 @@ export class SignalClipboard {
|
||||
const signal = event.clipboardData.getData('text/signal');
|
||||
|
||||
const clipboardContainsFiles = event.clipboardData.files?.length > 0;
|
||||
if (!clipboardContainsFiles) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
|
||||
if (clipboardContainsFiles) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
|
||||
if (selection == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user