mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-04 06:36:24 +00:00
Cleanup previous PR
This commit is contained in:
parent
947139fd81
commit
e4eb85216d
1 changed files with 5 additions and 1 deletions
|
|
@ -4148,6 +4148,7 @@ static void schedule_drag_finish_timer(void);
|
|||
static GLFWid drag_finish_window_id = 0;
|
||||
static GLFWDragOperationType drag_finish_action = 0;
|
||||
static NSTimer *drag_finish_timer = nil;
|
||||
static NSMutableArray<GLFWFilePromiseProviderDelegate*> *file_promise_providers = nil;
|
||||
#define DRAG_FINISH_TIMEOUT_SECONDS 2.0
|
||||
|
||||
@implementation GLFWDraggingSource
|
||||
|
|
@ -4224,7 +4225,6 @@ static NSTimer *drag_finish_timer = nil;
|
|||
}
|
||||
@end
|
||||
|
||||
static NSMutableArray<GLFWFilePromiseProviderDelegate*> *file_promise_providers = nil;
|
||||
|
||||
static void
|
||||
fire_drag_finished(void) {
|
||||
|
|
@ -4456,6 +4456,10 @@ _glfwPlatformStartDrag(_GLFWwindow* window, const GLFWimage* thumbnail) {@autore
|
|||
_GLFWwindow *window = _glfwWindowForId(_glfw.drag.window_id);
|
||||
if (!window) { [self end_transfer:EINVAL]; return; }
|
||||
bool keep_going = true;
|
||||
if (drag_finish_timer) {
|
||||
[drag_finish_timer invalidate];
|
||||
drag_finish_timer = nil;
|
||||
}
|
||||
while (keep_going) {
|
||||
GLFWDragEvent ev = {.type=GLFW_DRAG_DATA_REQUEST, .mime_type=mimeType};
|
||||
_glfwInputDragSourceRequest(window, &ev);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue