Commit Graph

50582 Commits

Author SHA1 Message Date
Jonas Ådahl
9f9aaea319 wayland: Use correct enum type and values
Use the gravity enum values when converting to gravity. It doesn't fix
anything, since the enum values were identical, but it makes a coverity
warning go away.

https://bugzilla.gnome.org/show_bug.cgi?id=780301
2017-05-08 17:42:31 -04:00
Matthias Clasen
95e313a283 file filter: Be save against NULL
g_content_type_from_mime_type may return NULL, deal with that.

https://bugzilla.gnome.org/show_bug.cgi?id=782180
2017-05-08 16:35:53 -04:00
Matthias Clasen
c4a5f6a601 Revert "GdkWaylandWindow: Unexport when finalizing"
This reverts commit 251e216052.
2017-05-08 15:59:23 -04:00
Jonas Ådahl
251e216052 GdkWaylandWindow: Unexport when finalizing
The application might not have exported, and it'll be too late for it
at this point anyway, so lets be helpful and not leak it.

https://bugzilla.gnome.org/show_bug.cgi?id=782109
2017-05-08 15:41:11 -04:00
Jonas Ådahl
6d7749898d GdkWaylandWindow: Clear export user data when used
It was only cleared when unexported, but we could just as well clear it
when its used too.

https://bugzilla.gnome.org/show_bug.cgi?id=782109
2017-05-08 15:41:11 -04:00
Michael Catanzaro
cfd15c95b0 menubutton: Remove prelight state when button is deactivated
If the button is deactivated, it should not appear to be hovered
anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=781992
2017-05-08 16:03:33 +02:00
Balázs Úr
00387c24ca Update Hungarian translation 2017-05-05 18:56:59 +00:00
Christoph Reiter
004aba44df gtkdnd: restore drag window movement for the unmanaged case
5bb12474d9 removed the dnd window movement code to let
the gdk backends handle the window movement instead. While this
works for X11/wayland the win32 backend still uses the unmanaged
interface and expects the window movement to be handled on the gtk
side. This restores the functionality in case the dnd is unmanaged.

This fixes the drag window on Windows being stuck in the top left
corner instead of following the drag position.

https://bugzilla.gnome.org/show_bug.cgi?id=781737
2017-05-05 17:42:39 +02:00
Matej Urbančič
c0efc9ede9 Updated Slovenian translation 2017-05-05 13:25:51 +02:00
Emmanuele Bassi
db2c80d9db meson: Generate man pages for the installed tools 2017-05-05 11:35:31 +01:00
Emmanuele Bassi
777906e26c meson: Silence the introspection scanner
We want the warnings, but not every single message.
2017-05-05 11:17:02 +01:00
Olof-Joachim Frahm
1681d4ad77 Move style change for popover creation.
Creating with `gtk_popover_new_from_model` should be exactly the same as
if via `gtk_popover_new` plus `gtk_popover_bind_model`.

Also remove the style if the model is unbound at any point.
2017-05-05 11:37:20 +02:00
Mohammed Sadiq
00cd92ea71 linkbutton: Fix memory leak
strings returned by gtk_widget_get_tooltip_text() and
gtk_widget_get_tooltip_markup() has to be freed when no longer
required.

https://bugzilla.gnome.org/show_bug.cgi?id=782202
2017-05-05 11:18:25 +02:00
Timm Bäder
3d21128dbb Remove gtk_widget_get_preferred_*
They are unnecessary now that we have gtk_widget_measure.
2017-05-05 11:18:25 +02:00
Timm Bäder
1a7a089e2c window: Stop using gtk_widget_get_preferred* 2017-05-05 11:18:24 +02:00
Timm Bäder
8b2c71703e widget: Remove useless assignment
We don't use adjusted_allocation after this line.
2017-05-05 11:18:05 +02:00
Timm Bäder
91932ffbc7 button: Remove baseline_align value
It's unused.
2017-05-05 11:18:05 +02:00
Matthias Clasen
7625e40e82 clipboard: Try the mimetype first
Try text/plain;charset=utf-8 first, before falling back to
X11-isms like UTF8_TEXT. This makes things work on Wayland
compositors that don't carry a heavy X11 legacy around.

https://bugzilla.gnome.org/show_bug.cgi?id=781814
2017-05-03 18:50:21 -04:00
Tim-Philipp Müller
88900814cd meson: simplify cups version check in printbackends
Using cc.compute_int() instead of cc.get_define() for now
as there seems to be some issue with get_define() (#1726).
2017-05-03 18:40:56 +01:00
Lapo Calamandrei
77a0fc92c8 Adwaita: regenerate css using sassc 2017-05-03 17:43:45 +02:00
Lapo Calamandrei
9be18363e7 Adwaita: add more space between check/radio and label in popovers
See https://bugzilla.gnome.org/show_bug.cgi?id=779570 for details.
2017-05-03 17:39:21 +02:00
Lapo Calamandrei
96fc66d327 Adwaita: add a sassc based parse-sass.sh script 2017-05-03 17:31:50 +02:00
Emmanuele Bassi
0dad501d16 meson: Remove G_LOG_USE_STRUCTURED from target C flags
The G_LOG_USE_STRUCTURED symbol is defined in the project flags, so we
don't need to add it again in the per-target flags.
2017-05-03 16:22:52 +01:00
Ernestas Kulik
fee3f9afa1 meson: depend on glib >= 2.53.1
The code uses g_object_new_with_properties(), which is only available in
versions 2.53.1 and up.

https://bugzilla.gnome.org/show_bug.cgi?id=782123
2017-05-03 16:14:58 +01:00
Emmanuele Bassi
fb6f9e10da build: Use appropriate linker flag for the builder test
The `-export-dynamic` flag is a libtool-specific flag; since we're not
using libtool with Meson, we should instruct the C compiler to use the
appropriate linker flag instead.
2017-05-03 16:11:17 +01:00
Emmanuele Bassi
c05fcdbba0 window: Remove property definition
Commit 92b0d2e8ea removed the
hide-titlebar-when-maximized property handlers, but it still installed
the GParamSpec into the GtkWindow class.
2017-05-03 15:58:49 +01:00
Emmanuele Bassi
69ec6234a4 Specify more options to sassc
We should use the compact style, to minimize the whitespace; and we
should omit the source map URL comment as well.
2017-05-03 15:47:45 +01:00
Emmanuele Bassi
3b9233910f build: De-duplicate options to sassc
If we want to change the list of options we use with sassc, not having
to copy-paste them in multiple rules would be a good start.
2017-05-03 15:47:45 +01:00
Emmanuele Bassi
bc0a08eced testsuite: Remove unused function
Silence a compiler warning.
2017-05-03 15:21:20 +01:00
Emmanuele Bassi
3ba514d31f build: Port the a11y test suite to Meson
Copy the location of the test data and binaries from the autotools
build, even though it's not really correct; currently we install the
test data under libexecdir, but it should live under datadir, and we
should use `G_TEST_DIST` to figure it out.

The `state` subdirectory is missing.
2017-05-03 15:15:17 +01:00
Emmanuele Bassi
a54b6be606 build: Add common settings for tests
We are going to reuse them in the various parts of the test suite.
2017-05-03 15:10:58 +01:00
Emmanuele Bassi
8acf5a8174 build: Update autotools for API reference changes 2017-05-03 15:10:58 +01:00
Emmanuele Bassi
15c4d7121c build: Add Meson-related files to the autotools dist
This way, a tarball generated via autotools will also allow building
GTK+ via Meson.
2017-05-03 15:10:58 +01:00
Emmanuele Bassi
9b7148cdbd build: Use link_whole for GDK backends
When linking libgdk4 to each backend's static library, we want to use
the whole-archive support.
2017-05-03 15:10:58 +01:00
Emmanuele Bassi
d09ccaaf35 build: Define G_LOG_USE_STRUCTURED in GDK
We want to use the new structured logging support in GLib.
2017-05-03 15:10:58 +01:00
Emmanuele Bassi
9e8ba70d69 build: Add common flags to GDK backends
The common compiler and linker flags control, among other things, the
default visibility of symbols; without them, we leak symbols that ought
to be private.
2017-05-03 15:10:58 +01:00
Emmanuele Bassi
efd2ce2be5 build: Fix the introspection build
GSK has various enumeration types that are currently not used; while
they may go away, currently they are built and introspected. If we want
the introspection machinery to work, and still use static libraries to
build GDK and GSK into the GTK shared library, then we need to reference
the get_type() function of these enumeration types somewhere, to avoid
the linker discarding it, and thus breaking the build.

As luck would have it, we have an autogenerated bit of C that refers to
all the get_type() functions in the library; if we add the GSK types to
it, then we get the reference we're looking for, and the build succeeds.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
ea32f4c020 build: Depend on Meson 0.40 at least 2017-05-03 15:10:57 +01:00
Emmanuele Bassi
c984c3b55e build: Initial attempt at fixing the docs build
We need to reference the types file directly, because it won't be copied
into the builddir by Meson — except for GTK, which needs to generate its
own types file using configure_file().
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
91dee46497 build: Use get_pkgconfig_variable()
There's no need to run pkg-config ourselves.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
17518ef89b build: Improve consistency of the "coding" style
We're mixing a lot of styles in the Meson build files. This is an
attempt at making everything slightly more consistent in terms of
whitespace and indentation.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
1afd415583 build: Clean up print backends Meson rules 2017-05-03 15:10:57 +01:00
Emmanuele Bassi
6dd35248d5 build: Put the xkbcommon required version into a variable
We use it in two places.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
6728f45aa0 build: Ensure that Vulkan shaders are rebuilt if glslc is found
If glslc is found, rebuild the shaders from GLSL to SPIR-V; otherwise,
we're just going to use the built files we have committed in the source
repository.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
c1965150c7 build: Add post-install script
When building GTK+ straight from the repository without any assistance
from packaging tools, we need to trigger system-wide updates, like the
icon theme cache update, or the schema compilation.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
561f41d112 build: Clean up Wayland protocol code generation
We can build the name of the input and output files for the Wayland
protocols we use from the protocol name, stability, and version. This is
similar to how the autotools build does it, except much more clear and
without shelling out twice to sed just to resolve the Makefile rule.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
6b4b3f2f6c build: Add Meson options for quartz/win32 backends 2017-05-03 15:10:57 +01:00
Emmanuele Bassi
99d353003e build: Disable introspection generation
Currently gobject-introspection is badly borked with Meson.

This will need to be reverted.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
d35d82fb35 build: Rename GSK resource generator script
Maintain the naming convention, since we have similar scripts for GDK
and GTK already.
2017-05-03 15:10:57 +01:00
Emmanuele Bassi
ba87e857e2 build: Generate the API references (WIP)
Still a work in progress.
2017-05-03 15:10:57 +01:00