Rehabilitate Haiku support.

This commit is contained in:
waddlesplash
2020-12-12 15:25:51 -05:00
parent 1d489b3fd5
commit 2df11d3911
10 changed files with 155 additions and 3 deletions

View File

@ -152,6 +152,8 @@ static WindowSystemType GetWindowSystemType()
return WindowSystemType::X11;
else if (platform_name == QStringLiteral("wayland"))
return WindowSystemType::Wayland;
else if (platform_name == QStringLiteral("haiku"))
return WindowSystemType::Haiku;
ModalMessageBox::critical(
nullptr, QStringLiteral("Error"),
@ -165,7 +167,7 @@ static WindowSystemInfo GetWindowSystemInfo(QWindow* window)
wsi.type = GetWindowSystemType();
// Our Win32 Qt external doesn't have the private API.
#if defined(WIN32) || defined(__APPLE__)
#if defined(WIN32) || defined(__APPLE__) || defined(__HAIKU__)
wsi.render_window = window ? reinterpret_cast<void*>(window->winId()) : nullptr;
wsi.render_surface = wsi.render_window;
#else