macos: simplify access to native widget.

This commit is contained in:
Mat 2024-09-06 16:12:56 +00:00
parent 62723f9f9b
commit 4294bca076

View File

@ -273,8 +273,7 @@ quartz_set_client_surface (GtkIMContext *context,
if (widget != NULL)
{
GtkRoot *root = gtk_widget_get_root (widget);
GtkNative *native = gtk_widget_get_native (GTK_WIDGET (root));
GtkNative *native = GTK_NATIVE (gtk_widget_get_root (widget));
if (native != NULL)
qc->client_surface = gtk_native_get_surface (native);