ButchersBoy / Dragablz

Dragable and tearable tab control for WPF
http://dragablz.net
MIT License
2.17k stars 320 forks source link

Wrong order of NewTabHost initialization #251

Open danielklecha opened 3 years ago

danielklecha commented 3 years ago

Hi!

Great project :) I use ReactiveUI and in that project bindings happen after view is activated. Because of that ItemsSource is not set when drag tab and drop in right corner. I think that Layout.cs must be updated to handle that. Lines 976-979 should be reordered:

newTabHost.Container.Show();
newTabHost.Container.Activate();
newTabHost.TabablzControl.AddToSource(content);
newTabHost.TabablzControl.SelectedItem = content;