The default widget is mostly a dialog concept,
and does not really need this generic api. If
we need to mark a widget as default, use
gtk_window_set_default().
The default activation is now handled
via action, and activating the focus can
be handled by GtkWindow, since we only
have one per-window focus anyway.
We don't want to set resize cursors on popovers.
The underlying issue here is that we don't translate
the coordinates between surfaces. For now, just
ignore these events.
This api is meant to mimic xdg-popover.grab - we
show the surface, and dismiss it when we get events
on other surfaces. For foreign surfaces, the compositor
handles that for us; for our own, we check outselves
before delivering events to GTK.
Use the new surface-transform-changed-callback functionality
to move the popover whenever the parent changes its
position in the window. This currently works for X11,
but not for Wayland (due to restrictions in the
move-to-rect implementation.
This is another step towards implementing
popup semantics for X11.
We do a sort-of ok job on stacking order
here - whenever the parent window gets a
ConfigureNotify, we just restack all popups
directly on top of their parent. This is good
enough to keep popups on top of their parent
while we drag it around, and it gets the popup
to disappear when raising another window on
top of the parent.
We don't need the complicated wrapper system anymore,
since client-side windows are gone. This commit moves
all the vfuncs to GtkSurfaceClass, and changes the
backends to just derive their surface implementation
from GdkSurface.
We want to use a gdk_surface_new_popup for popups,
and align the constructor names with the surface
types, so rename
gdk_surface_new_popup -> gdk_surface_new_temp
gdk_surface_new_popup_full -> gdk_surface_new_popup
The temp surface type will disappear eventually.
All the information in it is already contained
in the surface object we pass along, and none
of the backend implementations were using the
attributes at all.
We are not creating such surfaces anymore, and
they were only ever meaningfully implemented
on X11. Drop the concept, and the api for determining
if a surface is input-only.
Make entry completion mostly work as a popover.
We need to disable treeview search, since it
creates a toplevel that will disrupt our grabbing
popup, causing it to be dismissed.
We don't need to grab ourselves, since the popover
code does it for us. We don't need to reposition our
window, since the popover takes care of that too.
This lets us remove a use of GTK_WINDOW_POPUP,
which should eventually be going away.
This does not quite work yet - the popup is not
going away as it should.