diff --git a/src/Dock.Avalonia/Controls/ToolChromeControl.axaml.cs b/src/Dock.Avalonia/Controls/ToolChromeControl.axaml.cs index d211d95e4..94d87ac1f 100644 --- a/src/Dock.Avalonia/Controls/ToolChromeControl.axaml.cs +++ b/src/Dock.Avalonia/Controls/ToolChromeControl.axaml.cs @@ -1,3 +1,4 @@ +using System.Runtime.InteropServices; using Avalonia; using Avalonia.Controls; using Avalonia.Controls.Metadata; @@ -79,7 +80,8 @@ protected override void OnApplyTemplate(TemplateAppliedEventArgs e) { base.OnApplyTemplate(e); - if (VisualRoot is HostWindow window) + //On linux we dont attach to the HostWindow because of inconsistent drag behaviour + if (VisualRoot is HostWindow window && RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { Grip = e.NameScope.Find("PART_Grip"); CloseButton = e.NameScope.Find