BASE 1.2.2.1 Fix

This commit is contained in:
AlastorFox committed 2026-10-12 00:05:53 +03:00
1 parent 3abaa4665d
commit a1fff09097
2 files changed
+6 -10

No files matched your search

+2 -2
View File
@@ -415,14 +415,14 @@ public partial class MainWindow : Window
e.Handled = true;
}
private void TabStrip_Drop(object sender, WpfDragEventArgs e)
private async void TabStrip_Drop(object sender, WpfDragEventArgs e)
{
if (_tabManager is null || !e.Data.GetDataPresent(typeof(BrowserTab))) return;
var source = e.Data.GetData(typeof(BrowserTab)) as BrowserTab;
var target = FindTabItem(e.OriginalSource as DependencyObject)?.DataContext as BrowserTab;
if (source is null || target is null || ReferenceEquals(source, target)) return;
var targetIndex = _tabManager.Tabs.IndexOf(target);
if (targetIndex >= 0) _tabManager.MoveTab(source, targetIndex);
if (targetIndex >= 0) await _tabManager.MoveTabAsync(source, targetIndex);
e.Handled = true;
}