Matthias Clasen
efff718d4e
x11: Make popup surfaces use o-r windows
...
This is a step towards a full implementation
of popup surfaces for X11.
2019-04-28 12:36:05 +00:00
Matthias Clasen
afb8bc6478
wayland: Use popup parents
...
Make the Wayland move-to-rect implementation
use popup parents.
2019-04-28 12:36:05 +00:00
Matthias Clasen
d9a8d78b38
surface: Stop setting transient-for for popups
...
This was just a hack to reuse the existing
infrastructure. Now that we store parents separately,
stop doing it.
2019-04-28 12:36:05 +00:00
Matthias Clasen
2a36ba48fa
surface: Make move-to-rect work for popups
...
Now that we store popup parents separately,
the client-side move-to-rect implementation
must use them.
2019-04-28 12:36:05 +00:00
Matthias Clasen
194ee05f2f
surface: Store popup parent
...
Store popup parents separately from transient-for parents,
since these are separate concepts with different behaviors.
2019-04-28 12:36:05 +00:00
Matthias Clasen
3da781e2fe
x11: some leftover cleanups
...
Every surface is toplevel now. no need to check
2019-04-28 12:36:05 +00:00
Matthias Clasen
c0d853151a
wip: popup surface type
2019-04-28 12:36:05 +00:00
Matthias Clasen
01c65a07d2
x11: Remove useless checks
...
All surfaces are toplevels now, no need
to check for this all over the place.
2019-04-28 12:36:05 +00:00
Matthias Clasen
9193d07206
Get rid of GdkSurfaceImpl
...
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.
2019-04-28 12:36:05 +00:00
Matthias Clasen
af77b8f4a0
surface: Add a frame-clock property
...
This will let us shift things around later.
2019-04-28 12:36:05 +00:00
Matthias Clasen
e40ca67c4e
gdk: Add a private header
...
This is in preparation for getting rid of GdkSurfaceImpl.
2019-04-28 12:36:05 +00:00
Matthias Clasen
2542bfcd76
Rename surface constructors
...
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.
2019-04-28 12:36:05 +00:00
Matthias Clasen
3301c8dc74
gdk: Drop pass-through surfaces
...
With client-side windows gone, this property
is no longer used at all, and has been replaced
by a similar concept on the widget level.
Drop it.
2019-04-28 12:36:05 +00:00
Matthias Clasen
5709c6eb40
gdk: Drop GdkWindowAttr
...
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.
2019-04-28 12:36:05 +00:00
Matthias Clasen
6a8af95029
gdk: Drop input-only surfaces
...
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.
2019-04-28 12:36:05 +00:00
Matthias Clasen
5c9aff53f0
gdk: Remove an unused field
...
Spring cleaning. We are not using this field
at all, since we have the input_only boolean.
2019-04-28 12:36:05 +00:00
Matthias Clasen
bbe9f4a03b
entry completion: Various fixes
...
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.
2019-04-28 12:36:05 +00:00
Matthias Clasen
7a094d949e
wip: Use a popover for entry completion
...
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.
2019-04-28 12:36:05 +00:00
Matthias Clasen
e3f4402aee
surface: Cosmetics
2019-04-28 12:36:05 +00:00
Matthias Clasen
986f073a4f
Drop gdk_surface_new_temp
...
This is no longer used, and the only difference
to gdk_surface_new_popup is input-only, which is
an X11-only concept.
2019-04-28 12:36:05 +00:00
Matthias Clasen
518ecd3406
menu: Stop using gdk_surface_new_temp
...
We can just as well use gdk_surface_new_popup.
2019-04-28 12:36:05 +00:00
Matthias Clasen
c9fb34f338
x11: Stop using gdk_surface_new_temp
...
We can just as well use gdk_surface_new_popup.
2019-04-28 12:36:05 +00:00
Matthias Clasen
80f71f3ebd
broadway: Stop using gdk_surface_new_temp
...
This is in preparation for adding a proper
popup surface type.
2019-04-28 12:36:05 +00:00
Matthias Clasen
0e9e2eb650
wayland: Reshuffle some internals
...
Make find_grab_input_seat return a GdkWaylandSeat
instead of a struct wl_seat, so we can use it and
avoid calling gdk_display_get_default_seat when
we need to get a serial later.
2019-04-28 12:36:05 +00:00
Matthias Clasen
7a8164c79f
docs: Remove references to gdk_device_grab
...
It is no longer public api, refer to gdk_seat_grab instead.
2019-04-28 12:36:05 +00:00
Matthias Clasen
933fdc24f2
gdk: Remove remnants of client-side windows
...
Now that all surfaces are native, we don't need
to separately keep track of grab surfaces and
their native ancestor anymore.
2019-04-28 12:36:05 +00:00
Matthias Clasen
6263343765
Drop gtk_widget_register_surface
...
This is no longer used.
2019-04-28 12:36:05 +00:00
Matthias Clasen
067a83d38d
popover: Stop using gtk_widget_register_surface
...
The GtkRoot implementations are expected to handle
the necessary surface setup themselves, going forward.
2019-04-28 12:36:05 +00:00
Matthias Clasen
976998697d
window: Stop using gtk_widget_register_surface
...
The GtkRoot implementations are expected to handle
the necessary surface setup themselves, going forward.
2019-04-28 12:36:05 +00:00
Matthias Clasen
fb289f64ec
menu: Stop using gtk_widget_register_surface
...
It does not seem to be necessary at all.
2019-04-28 12:36:05 +00:00
Matthias Clasen
c77fa1f2dd
surface: Make gdk_surface_get_device_position void
...
None of the callers were using the return value,
and without child surfaces, it is not very useful.
2019-04-28 12:36:05 +00:00
Matthias Clasen
e51e192f64
x11: Drop a gratitious use of gdk_event_get_root_coords
...
We are in the backend, so we can do the translation ourselves.
2019-04-28 12:36:05 +00:00
Matthias Clasen
ee43674a80
Remove gdk_surface_get_geometry as public api
...
We still need to keep the vfunc around, since the
fallback implementation of gdk_display_get_monitor_at_surface
uses it. So, a GDK backend must either have root coordinates
or always return a monitor from monitor_at_surface.
2019-04-28 12:36:05 +00:00
Matthias Clasen
b439197467
Drop gdk_surface_get_root_origin
...
It was not used.
2019-04-28 12:36:05 +00:00
Matthias Clasen
70f0e01afc
Remove gdk_surface_get_root_coords as public api
...
We still need to keep the vfunc around, since the
fallback implementation for move_to_rect uses it.
So, a GDK backend must either have root coordinates
or implement move_to_rect.
2019-04-28 12:36:05 +00:00
Matthias Clasen
a84f439d84
tooltip: Remove an unused gdk_surface_get_root_coords call
2019-04-28 12:36:05 +00:00
Matthias Clasen
ecac56ee27
Remove gdk_surface_coords_to/from_parent
...
This api was unused, and surfaces have no parents anymore.
2019-04-28 12:36:05 +00:00
Matthias Clasen
891f0d6d74
surface: Small simplification
...
No more special-casing of state setting.
2019-04-28 12:36:05 +00:00
Matthias Clasen
7d83f7dd3d
surface: Simplify destroy implementation
...
Without child surfaces, there is no need to recurse.
2019-04-28 12:36:05 +00:00
Matthias Clasen
92bc945b8a
surface: Remove abs_x/abs_y
...
We no longer have child windows, so the offset is
always 0.
2019-04-28 12:36:05 +00:00
Matthias Clasen
af5323cb41
surface: Small cleanup
...
Every surface has an impl now, no need to check.
2019-04-28 12:36:05 +00:00
Matthias Clasen
52583a41bd
surface: Simplify some code
...
Fold gdk_surface_process_updates_recurse into its
only caller. There is no recursion here anymore.
2019-04-28 12:36:05 +00:00
Matthias Clasen
16ae86315f
Remove surface->children
...
This field is not used at all anymore.
2019-04-28 12:36:05 +00:00
Matthias Clasen
716a6e9e39
gdk: Stop using surface->children
...
It is always NULL.
2019-04-28 12:36:04 +00:00
Matthias Clasen
984e59a219
wayland: Stop using surface->children
...
It is always NULL.
2019-04-28 12:36:04 +00:00
Matthias Clasen
80a6fac000
Remove surface->parent
...
This field is no longer used.
2019-04-28 12:36:04 +00:00
Matthias Clasen
a99c5790ec
gdk: Stop using surface->parent
...
It is always NULL.
2019-04-28 12:36:04 +00:00
Matthias Clasen
d96b8b3632
broadway: Stop using surface->parent
2019-04-28 12:36:04 +00:00
Matthias Clasen
191850e7bc
x11: Stop using surface->parent
...
It is always NULL.
2019-04-28 12:36:04 +00:00
Matthias Clasen
aa918cd4da
wayland: Stop using surface->parent
...
It is always NULL.
2019-04-28 12:36:04 +00:00