From 2a8cd72689dccc96e4cae9585feb481b2e6ae119 Mon Sep 17 00:00:00 2001 From: nakst <> Date: Wed, 6 Oct 2021 17:25:49 +0100 Subject: [PATCH] accurate tab drag off --- desktop/desktop.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/desktop/desktop.cpp b/desktop/desktop.cpp index d650169..b741c6e 100644 --- a/desktop/desktop.cpp +++ b/desktop/desktop.cpp @@ -780,7 +780,8 @@ int WindowTabMessage(EsElement *element, EsMessage *message) { } else { EsPoint mousePosition = EsMouseGetPosition(tab->window); int32_t dragOffThreshold = GetConstantNumber("tabDragOffThreshold"); - int32_t previousTabOffsetX = tab->offsetX; + // int32_t previousTabOffsetX = tab->offsetX; + int32_t previousTabOffsetX = tab->dragPosition; if (EsRectangleContains(EsRectangleAdd(band->GetWindowBounds(), ES_RECT_1I(-dragOffThreshold)), mousePosition.x, mousePosition.y)) { ReorderItemDragged(tab, message->mouseDragged.newPositionX);