[ui gtk] Fix file dialog

Use drawing area for vulkan but window for dialogs
This commit is contained in:
Sandy Carter 2019-01-21 15:15:15 -05:00
parent d92cd9f6a1
commit f0bc0a8088
2 changed files with 3 additions and 2 deletions

View File

@ -69,7 +69,7 @@ bool VulkanContext::Initialize() {
#elif XE_PLATFORM_LINUX
#ifdef GDK_WINDOWING_X11
GtkWidget* window_handle =
static_cast<GtkWidget*>(target_window_->native_handle());
dynamic_cast<GTKWindow*>(target_window_)->native_window_handle();
xcb_window_t window =
gdk_x11_window_get_xid(gtk_widget_get_window(window_handle));
VkXcbSurfaceCreateInfoKHR create_info;

View File

@ -30,7 +30,8 @@ class GTKWindow : public Window {
NativePlatformHandle native_platform_handle() const override {
return connection_;
}
NativeWindowHandle native_handle() const override { return drawing_area_; }
NativeWindowHandle native_handle() const override { return window_; }
GtkWidget* native_window_handle() const { return drawing_area_; }
void EnableMainMenu() override {}
void DisableMainMenu() override {}