Commit Graph

63220 Commits

Author SHA1 Message Date
Matthias Clasen
eb6edac4bd gdk: Drop gdk_surface_begin_move/resize_drag
These have been replaced by GdkToplevel api.
2020-05-17 12:49:29 -04:00
Matthias Clasen
f316fe0f58 window: Use toplevel begin_move/resize api
The GdkSurface api for this is going away.
2020-05-17 12:49:26 -04:00
Matthias Clasen
309a7aa253 gdk: Add gdk_toplevel_begin_move/resize
For now, these are wrappers around the surface apis,
but they are going to replace them, since this operation
is only available on toplevels.
2020-05-17 12:41:16 -04:00
Timm Bäder
2c1d218749 Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master

Closes #1619

See merge request GNOME/gtk!1921
2020-05-17 13:08:26 +00:00
Emin Tufan Çetin
716485113a Update Turkish translation 2020-05-17 11:42:10 +00:00
Matthias Clasen
d70feb9165 Apply surface transform in more places
With these fixes, GtkSwitch now works in the presence
of surface transforms.
2020-05-17 02:23:23 -04:00
Matthias Clasen
38af49d4fd inspector: Take surface transform into account 2020-05-17 02:10:56 -04:00
Timm Bäder
007de568c9 gl renderer: Fix an uninitialized value 2020-05-17 08:07:11 +02:00
Matthias Clasen
d2913b81cb windowhandle: Take surface transform into account 2020-05-17 02:05:32 -04:00
Matthias Clasen
c90078fd4a widget: Fix gtk_widget_get_surface_allocation
As the name implies, this should be surface-relative
coordinates, so it needs to take the surface transform
into account.
2020-05-17 02:04:22 -04:00
Matthias Clasen
428e647238 textview: Fix context menu placement
Take the surface transform into account for
positioning the context menu.
2020-05-17 02:03:41 -04:00
Matthias Clasen
5e35a4b69a tooltip: Fix positioning
There are a few more places where we were forgetting
to apply the surface->native transform. With these
changes, tooltips are positioned correctly when
the toplevel has padding applied.

Fixes: #1619
2020-05-17 01:22:02 -04:00
Matthias Clasen
3035bf1e39 widget-factory: Cosmetics
Add a frame around the white background in the background
selection dialog. Otherwise, it is not really visible.
2020-05-16 21:54:14 -04:00
Matthias Clasen
a2a3aab94d Merge branch 'wip/baedert/for-master' into 'master'
Wip/baedert/for master

Closes #2601

See merge request GNOME/gtk!1918
2020-05-16 23:35:51 +00:00
Timm Bäder
5b0e91844b popover: Fix input shape rendering
Once again, calling gtk_widget_get_allocation() is wrong.

Fixes #2601
2020-05-16 22:34:38 +02:00
Timm Bäder
c4363e2706 showrendernode: Set widget overflow 2020-05-16 22:04:00 +02:00
Timm Bäder
ccaacfc8c3 texthandle: Remove min-width/height handling
We do that automatically for all widgets.
2020-05-16 22:04:00 +02:00
Timm Bäder
2e9d772e66 natives: Use GtkCssBoxes in get_surface_transform 2020-05-16 22:04:00 +02:00
Timm Bäder
bac6e79614 native: Add documenation for get_surface_transform 2020-05-16 22:03:58 +02:00
Timm Bäder
2fd86ef80c popover: Return correct values from get_surface_transform()
We do not (yet) care about the box shadow here, so it's sufficient to
return the css values.
2020-05-16 22:03:58 +02:00
Timm Bäder
f9370d7e83 main: Translate coordinates from surface to native before picking
gtk_widget_pick() needs them to be in @self coordinates.
2020-05-16 22:03:55 +02:00
Matthias Clasen
bc75965053 Merge branch 'matthiasc/for-master' into 'master'
broadway: Be careful about destroyed surfaces

See merge request GNOME/gtk!1917
2020-05-16 18:27:19 +00:00
Matthias Clasen
77107f70c4 broadway: Be careful about destroyed surfaces
Just because we take a ref on a surface does not
guarantee that it is still usable a second later.
Check if its been destroyed in the meantime.

This is breaking the template tests in ci, since
there is no client behind the Broadway server.
2020-05-16 13:47:18 -04:00
Matthias Clasen
b41aeabbec Merge branch 'matthiasc/for-master' into 'master'
broadway: Don't create overlarge images

See merge request GNOME/gtk!1916
2020-05-16 17:01:30 +00:00
Matthias Clasen
c0ae36e943 broadway: Create slave devices
The assumption is that the source device in events
is a slave device, so create pointer and keyboard
devices and use them in events.

This fixes the seat test on Broadway.
2020-05-16 12:27:22 -04:00
Matthias Clasen
5851415fca broadway: Don't create overlarge images
Respect that cairo won't create image surfaces larger
than 32767 x 32767.

This makes the one reftest pass that specifically checks
this condition, treeview-crash-too-wide.
2020-05-16 11:27:21 -04:00
Matthias Clasen
36b4b39619 Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master

See merge request GNOME/gtk!1915
2020-05-16 15:03:10 +00:00
Yuri Chornoivan
d7bf3605b9 Update Ukrainian translation 2020-05-16 14:52:15 +00:00
Matthias Clasen
15211556df Merge branch 'broadway-surface-destroy' into 'master'
Broadway surface destroy

See merge request GNOME/gtk!1914
2020-05-16 14:16:52 +00:00
Matthias Clasen
13f8583934 ci: Don't run opengl renderer tests on Broadway
The test setup mechanism in meson is not flexible
enough to let us run different suites depending
on setup, so just pass in explicitly which suites
we want to skip, depending on the backend.
2020-05-16 10:14:10 -04:00
Matthias Clasen
350110ad9d testsuite: Add a gsk-compare-broadway suite
We have a Broadway renderer, might as well spell
that out in the tests, and make the suite exclude the
3d tests it can't handle.
2020-05-16 10:14:10 -04:00
Matthias Clasen
d771aa6fee testsuite: Destroy surfaces
If we don't destroy the surface, it leaks.

GDK backends keep an extra reference on the
surface for the external resources associated
with it, and only drop it in destroy().
2020-05-16 09:12:18 -04:00
Matthias Clasen
4acb56d8c5 broadway: Keep an reference on surfaces
GDK backends are expected to keep a references on
their surfaces as long as they are associated with
external resources, and drop it in destroy().

This showed up as criticals in the shortcuts test
which manually creates and destroys surfaces.
2020-05-16 09:12:07 -04:00
Matthias Clasen
afaa9810d1 Merge branch 'matthiasc/for-master' into 'master'
inspector: Use tabular numbers in the fps overlay

See merge request GNOME/gtk!1912
2020-05-16 11:21:00 +00:00
Piotr Drąg
6aa68fcfee Update POTFILES.in and POTFILES.skip 2020-05-16 12:37:01 +02:00
Timm Bäder
b2b2070415 Implement diff() for color matrix nodes
This way we don't redraw color matrix nodes all the time.
2020-05-16 08:22:55 +02:00
Matthias Clasen
c5b2bbf01b inspector: Use tabular numbers in the fps overlay
It is a lot more readable if it doesn't constantly jitter.
2020-05-15 21:30:14 -04:00
Matthias Clasen
f4d3d8e27c Merge branch 'better-ci-reports' into 'master'
ci: Add the backend to the reports

See merge request GNOME/gtk!1911
2020-05-16 00:52:56 +00:00
Matthias Clasen
4f6fa87f00 Merge branch 'wip/carlosg/tablet-disconnects-master' into 'master'
gdk/wayland: Handle disorderly tablet/pad disconnects

See merge request GNOME/gtk!1910
2020-05-15 23:50:54 +00:00
Matthias Clasen
01bd6cfd17 ci: Add the backend to the reports
We want the test names in the junit xml to be
unique across all the tests in a job, so we need
to include the backend in the test name.

And we also want to see the used backend in
the html report.
2020-05-15 19:49:18 -04:00
Carlos Garnacho
000487c36c gdk/wayland: Handle disorderly tablet/pad disconnects
If the tablet gets removed/freed while there are pad events in flight,
we leave a dangling pointer from the pad to the tablet, which may
lead to invalid reads/writes when handling the pad event(s).
2020-05-15 23:40:18 +02:00
Matthias Clasen
5870f1c90a Merge branch 'headless-seatless' into 'master'
gtk: Handle seatless displays

See merge request GNOME/gtk!1905
2020-05-15 21:13:01 +00:00
Matthias Clasen
30ef48143f ci: Ignore Broadway failures
These need some more work, so ignore them for now,
to get the initial multi-backend testsuite into
production.
2020-05-15 15:24:04 -04:00
Matthias Clasen
0232218100 displayclose: Quietly skip if no X available 2020-05-15 14:58:58 -04:00
Matthias Clasen
31cf894092 ci: Run tests with different backends
Run the testsuite under x11, wayland and broadway
in the fedora-x86_64 job. This requires us to use
the v17 image which includes weston.
2020-05-15 14:11:53 -04:00
Matthias Clasen
509db01319 tests: Centralize our test setup a bit
Put all of the constant environment into the
toplevel meson.build file, to reduce repetition
and copy-paste errors.
2020-05-15 14:11:53 -04:00
Matthias Clasen
ff4552c842 testsuite: Add test setups for backends
Add test setups that set the GDK_BACKEND and
TEST_OUTPUT_SUBDIR environment variables.

This lets use run
meson test --setup x11 --suite reftest
meson test --setup wayland --suite reftest
and the output will be nicely separated.

We still need to do compositor / display server
setup from the outside.
2020-05-15 14:11:53 -04:00
Matthias Clasen
c22af88235 tests: Allow setting a subdir for output
meson seems somewhat weak when it comes to handling
test output. We need to get the output from different
test runs into different locations, and the only
way to communicate from a test setup with the actual
test code seems the environment, so use that.

Make all tests that produce output in files respect
a TEST_OUTPUT_SUBDIR environment variable which specifies
the name of a subdirectory to use. This is combined
with the existing --output argument, which specifies
a per-test location.

Affected tests are reftests, css performance tests
and gsk compare tests.
2020-05-15 14:11:53 -04:00
Matthias Clasen
6719616c36 ci: Fix a typo in the run-docker.sh script 2020-05-15 14:11:53 -04:00
Matthias Clasen
18c7284817 ci: Add weston and weston-libs to the fedora image
We want to run tests under Wayland, using weston
as the compositor. The weston-libs package contains
the headless backend for weston.
2020-05-15 14:11:53 -04:00