/// <summary> /// Destroys the hosted window. Derived classes should override /// this method to destroy the hosted window. /// </summary> /// <param name="child"> /// The platform handle of the child. /// </param> protected override void Destroy(Avalonia.Platform.IPlatformHandle child) { _window.Dispose(); }
/// <summary> /// Creates the window to be hosted. Derived classes override this /// method to build the window being hosted. /// </summary> /// <param name="parent"> /// The platform handle of the parent window. /// </param> /// <returns> /// The platform handle of the created window. /// </returns> protected override Avalonia.Platform.IPlatformHandle Build(Avalonia.Platform.IPlatformHandle parent) { _window = new VulkanSurface(parent.Handle); return(new Avalonia.Platform.PlatformHandle(_window.Handle, "ChildWindow")); }