A cross-platform UI framework for .NET
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

40 lines
1010 B

using System;
using Avalonia.Controls;
using Avalonia.Win32.Interop;
namespace Avalonia.Win32
{
class EmbeddedWindowImpl : WindowImpl
{
public EmbeddedWindowImpl()
{
_windowProperties = new WindowProperties
{
ShowInTaskbar = false,
IsResizable = false,
IsMinimizable = false,
IsMaximizable = false,
Decorations = WindowDecorations.None
};
}
protected override IntPtr CreateWindowOverride(ushort atom)
{
var hWnd = UnmanagedMethods.CreateWindowEx(
0,
atom,
null,
(int)UnmanagedMethods.WindowStyles.WS_CHILD,
0,
0,
640,
480,
OffscreenParentWindow.Handle,
IntPtr.Zero,
IntPtr.Zero,
IntPtr.Zero);
return hWnd;
}
}
}