mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-03 22:25:57 +00:00
macOS: Handle dropping of file promises into kitty in addition to file paths
Fixes #9084
This commit is contained in:
parent
ef15aa3f51
commit
3ba6c3f4b9
2 changed files with 14 additions and 1 deletions
|
|
@ -164,6 +164,8 @@ Detailed list of changes
|
|||
|
||||
- Fix a regression in 0.43.0 that caused high CPU usage when :opt:`disable_ligatures` was set to ``cursor`` and the tab bar was visible (:iss:`9071`)
|
||||
|
||||
- macOS: Handle dropping of file promises into kitty in addition to file paths (:pull:`9084`)
|
||||
|
||||
0.43.1 [2025-10-01]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
|
|
|||
|
|
@ -789,7 +789,18 @@ static const NSRange kEmptyRange = { NSNotFound, 0 };
|
|||
self.identifier = @"kitty-content-view";
|
||||
|
||||
[self updateTrackingAreas];
|
||||
[self registerForDraggedTypes:@[NSPasteboardTypeFileURL, NSPasteboardTypeString]];
|
||||
// Register for file promises in addition to regular files (macOS 10.12+)
|
||||
if (@available(macOS 10.12, *)) {
|
||||
NSMutableArray *types = [NSMutableArray arrayWithObjects:
|
||||
NSPasteboardTypeFileURL,
|
||||
NSPasteboardTypeString,
|
||||
nil];
|
||||
// Add file promise types
|
||||
[types addObjectsFromArray:[NSFilePromiseReceiver readableDraggedTypes]];
|
||||
[self registerForDraggedTypes:types];
|
||||
} else {
|
||||
[self registerForDraggedTypes:@[NSPasteboardTypeFileURL, NSPasteboardTypeString]];
|
||||
}
|
||||
}
|
||||
|
||||
return self;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue