[macos] fix bug 51040

This commit is contained in:
maxkadushkin
2023-12-24 10:51:28 +03:00
parent 74e85fc492
commit 9982fb31ea

View File

@ -660,6 +660,18 @@ static NSString * const kASCTabsMulticastDelegateKey = @"asctabsmulticastDelegat
}
}
- (void)otherMouseDown:(NSEvent *)event {
// [super otherMouseDown:event];
NSPoint dragPoint = [self.tabsView convertPoint:event.locationInWindow fromView:nil];
for (ASCTabView * tab in self.tabs) {
if (NSPointInRect(dragPoint, [tab frame])) {
[self tabDidClose: tab];
break;
}
}
}
- (void)addTab:(ASCTabView *)tab {
[self addTab:tab selected:YES];
}