gtk4.git
3 years agoffmpeg: Hey, this variable is const now!
Benjamin Otte [Tue, 26 Apr 2022 17:39:20 +0000 (19:39 +0200)]
ffmpeg: Hey, this variable is const now!

3 years agoroaring: Remove extra careful code
Benjamin Otte [Tue, 26 Apr 2022 17:38:36 +0000 (19:38 +0200)]
roaring: Remove extra careful code

because gcc knows it's too careful

3 years agoMerge branch 'annotation-fix' into 'main'
Emmanuele Bassi [Tue, 26 Apr 2022 13:08:00 +0000 (13:08 +0000)]
Merge branch 'annotation-fix' into 'main'

gtk/popovermenu: Fix transfer annotation of new_from_model_full()

See merge request GNOME/gtk!4668

3 years agogtk/popovermenu: Fix transfer annotation of new_from_model_full()
Florian Müllner [Tue, 26 Apr 2022 12:25:15 +0000 (14:25 +0200)]
gtk/popovermenu: Fix transfer annotation of new_from_model_full()

The function doesn't return a full reference, but a floating widget
like comparable constructor functions.

3 years agoUpdate Georgian translation
Zurab Kargareteli [Sat, 23 Apr 2022 17:05:50 +0000 (17:05 +0000)]
Update Georgian translation

3 years agoUpdate Brazilian Portuguese translation
Rafael Fontenelle [Thu, 21 Apr 2022 01:34:01 +0000 (01:34 +0000)]
Update Brazilian Portuguese translation

3 years agoMerge branch 'vertical-spin-selection-fix' into 'main'
Matthias Clasen [Wed, 20 Apr 2022 03:35:44 +0000 (03:35 +0000)]
Merge branch 'vertical-spin-selection-fix' into 'main'

theme: Fix vertical spin button selection

Closes #4788

See merge request GNOME/gtk!4659

3 years agotheme: Fix vertical spin button selection
Matthias Clasen [Wed, 20 Apr 2022 03:14:37 +0000 (23:14 -0400)]
theme: Fix vertical spin button selection

The selection should be black-on-blue as it is
everywhere else now. This was just a leftover.

Fixes: #4788
3 years agoMerge branch 'ebassi/issue-4825' into 'main'
Emmanuele Bassi [Tue, 19 Apr 2022 21:04:25 +0000 (21:04 +0000)]
Merge branch 'ebassi/issue-4825' into 'main'

Fix crash when running GTK4 apps under Orca

Closes #4825

See merge request GNOME/gtk!4657

3 years agoa11y: Defer object registration after root registration
Emmanuele Bassi [Tue, 19 Apr 2022 15:12:08 +0000 (16:12 +0100)]
a11y: Defer object registration after root registration

The root accessible object is registered asynchronously, as it needs to
call a method on the AT-SPI registry daemon. This means we need to defer
registering the GtkAtSpiContext on the accessibility bus and in the
cache until after the registration is complete.

Fixes: #4825
3 years agoQuench the anger of GCC
Emmanuele Bassi [Tue, 19 Apr 2022 14:33:21 +0000 (15:33 +0100)]
Quench the anger of GCC

Direct access of the fields of the union trips compiler warnings with
GCC 12, such as:

  ../gtk/gtkimagedefinition.c:135:13: error: array subscript
  ‘GtkImageDefinition {aka union _GtkImageDefinition}[0]’ is partly
  outside array bounds of ‘GtkImageDefinitionEmpty[1]’ {aka
  ‘struct _GtkImageDefinitionEmpty[1]’} [-Werror=array-bounds]

3 years agoMerge branch 'file-filter-fix' into 'main'
Matthias Clasen [Tue, 19 Apr 2022 03:51:16 +0000 (03:51 +0000)]
Merge branch 'file-filter-fix' into 'main'

Fix file filter buildable support

Closes #4787

See merge request GNOME/gtk!4652

3 years agoFix file filter buildable support
Matthias Clasen [Tue, 19 Apr 2022 03:03:15 +0000 (23:03 -0400)]
Fix file filter buildable support

File filters creates from ui files had some
extraneous gunk in them. Fix that. Test included.

Fixes: #4787
3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Mon, 18 Apr 2022 15:36:45 +0000 (15:36 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

gtk-builder-tool: Error out if screenshooting fails

See merge request GNOME/gtk!4649

3 years agogtk-builder-tool: Error out if screenshooting fails
Matthias Clasen [Mon, 18 Apr 2022 15:16:05 +0000 (11:16 -0400)]
gtk-builder-tool: Error out if screenshooting fails

If we don't produce a texture for whatever reason,
apologize and fail.

3 years agoMerge branch 'badcel/fix-typo' into 'main'
Timm Bäder [Mon, 18 Apr 2022 09:27:05 +0000 (09:27 +0000)]
Merge branch 'badcel/fix-typo' into 'main'

docs: Fix typo in description of GtkExpression

See merge request GNOME/gtk!4647

3 years agodocs: Fix typo in description of GtkExpression
Marcel Tiede [Mon, 18 Apr 2022 06:20:19 +0000 (06:20 +0000)]
docs: Fix typo in description of GtkExpression

3 years agoMerge branch 'screenshot-command' into 'main'
Matthias Clasen [Sun, 17 Apr 2022 17:40:46 +0000 (17:40 +0000)]
Merge branch 'screenshot-command' into 'main'

gtk-builder-tool: Add a screenshot command

See merge request GNOME/gtk!4645

3 years agogtk-builder-tool: Add a screenshot command
Matthias Clasen [Sun, 17 Apr 2022 04:26:25 +0000 (00:26 -0400)]
gtk-builder-tool: Add a screenshot command

This is an obvious variation of the preview
command. It can save a .ui file as either
.png or .node.

3 years agogtk-builder-tool: Reshuffle --help
Matthias Clasen [Sun, 17 Apr 2022 15:59:06 +0000 (11:59 -0400)]
gtk-builder-tool: Reshuffle --help

Use GOptionContext better.

3 years agoMerge branch 'wip/exalm/scrolled-window' into 'main'
Matthias Clasen [Sun, 17 Apr 2022 16:07:59 +0000 (16:07 +0000)]
Merge branch 'wip/exalm/scrolled-window' into 'main'

scrolledwindow: Pick up gtk-overlay-scrolling changes on the fly

See merge request GNOME/gtk!4642

3 years agogtk-builder-tool: Small reshuffle
Matthias Clasen [Sun, 17 Apr 2022 15:19:07 +0000 (11:19 -0400)]
gtk-builder-tool: Small reshuffle

Move the display check into the preview command.

3 years agoMerge branch 'filechooser-entry-popup' into 'main'
Matthias Clasen [Sun, 17 Apr 2022 03:51:32 +0000 (03:51 +0000)]
Merge branch 'filechooser-entry-popup' into 'main'

filechooser: Prevent random completion popups

See merge request GNOME/gtk!4643

3 years agoMerge branch 'filechooser-save-sensitive' into 'main'
Matthias Clasen [Sun, 17 Apr 2022 03:31:39 +0000 (03:31 +0000)]
Merge branch 'filechooser-save-sensitive' into 'main'

filechooser: Small fix for save mode

Closes #4851

See merge request GNOME/gtk!4644

3 years agofilechooser: Prevent random completion popups
Matthias Clasen [Sun, 17 Apr 2022 03:29:04 +0000 (23:29 -0400)]
filechooser: Prevent random completion popups

It is very irritating when the entry completion popup
appears not in response to user input in the entry.
In particular, when that happens right as the dialog
is shown.

To prevent that, temporarily disable completion
when setting the entry text programmatically.

3 years agofilechooser: Small fix for save mode
Matthias Clasen [Sun, 17 Apr 2022 02:00:22 +0000 (22:00 -0400)]
filechooser: Small fix for save mode

When changing folders, we were making the select
button insensitive when there's no files around.
That doesn't make sense in save mode when we don't
want to select a file but create one.

Fixes: #4851
3 years agoscrolledwindow: Pick up gtk-overlay-scrolling changes on the fly
Alexander Mikhaylenko [Sat, 16 Apr 2022 12:56:17 +0000 (16:56 +0400)]
scrolledwindow: Pick up gtk-overlay-scrolling changes on the fly

3 years agoscrolledwindow: Fix :kinetic-scrolling setter
Alexander Mikhaylenko [Sat, 16 Apr 2022 12:30:07 +0000 (16:30 +0400)]
scrolledwindow: Fix :kinetic-scrolling setter

3 years agoMerge branch 'wip/exalm/tooltip' into 'main'
Matthias Clasen [Sat, 16 Apr 2022 00:07:21 +0000 (00:07 +0000)]
Merge branch 'wip/exalm/tooltip' into 'main'

tooltipwindow: Don't restrict minimum tooltip label length

Closes #3741

See merge request GNOME/gtk!4640

3 years agotooltipwindow: Don't restrict minimum tooltip label length
Alexander Mikhaylenko [Fri, 15 Apr 2022 23:48:21 +0000 (03:48 +0400)]
tooltipwindow: Don't restrict minimum tooltip label length

We only care about wrapping at that length, we still want short tooltips
for short labels.

Fixes https://gitlab.gnome.org/GNOME/gtk/-/issues/3741

3 years agotooltipwindow: Remove a duplicate gtk_widget_class_set_css_name() call
Alexander Mikhaylenko [Fri, 15 Apr 2022 23:28:22 +0000 (03:28 +0400)]
tooltipwindow: Remove a duplicate gtk_widget_class_set_css_name() call

3 years agoMerge branch 'ebassi/for-main' into 'main'
Matthias Clasen [Fri, 15 Apr 2022 00:09:42 +0000 (00:09 +0000)]
Merge branch 'ebassi/for-main' into 'main'

docs: Fix the GtkPaned style

See merge request GNOME/gtk!4637

3 years agoMark nullable arguments in GtkPaned
Emmanuele Bassi [Thu, 14 Apr 2022 21:44:17 +0000 (22:44 +0100)]
Mark nullable arguments in GtkPaned

The set_start_child() and set_end_child() methods take NULL for the
child argument, as a way to remove the child from the paned widget.

3 years agodocs: Fix the GtkPaned style
Emmanuele Bassi [Thu, 14 Apr 2022 21:43:40 +0000 (22:43 +0100)]
docs: Fix the GtkPaned style

Use proper links to properties and methods, and drop gtk-doc'isms.

3 years agoMerge branch 'fix_tooltip' into 'main'
Matthias Clasen [Thu, 14 Apr 2022 18:00:43 +0000 (18:00 +0000)]
Merge branch 'fix_tooltip' into 'main'

label: Maintain value for `has-tooltip` for labels with links

See merge request GNOME/gtk!4635

3 years agoMerge branch 'fix_link_tabs' into 'main'
Matthias Clasen [Thu, 14 Apr 2022 11:36:19 +0000 (11:36 +0000)]
Merge branch 'fix_link_tabs' into 'main'

label: Move focus out of widget after last link

Closes #4681

See merge request GNOME/gtk!4636

3 years agolabel: Move focus out of widget after last link
Julian Sparber [Thu, 14 Apr 2022 10:14:17 +0000 (12:14 +0200)]
label: Move focus out of widget after last link

This allows the user to navigate via tab the links in a label and exits
the widget after the last link, when moving forward, and first link,
when moving backward.

This also ensures that ellipsised links arn't focused.

Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4681
3 years agolabel: Maintain value for `has-tooltip` for labels with links
Julian Sparber [Wed, 13 Apr 2022 16:56:29 +0000 (18:56 +0200)]
label: Maintain value for `has-tooltip` for labels with links

The `has-tooltip` property gets set to `false` for label with links if no
link is selected. This makes sure to only change the property to `true`
but never to `false`.

3 years agoMerge branch 'clarify-scrollable-docs' into 'main'
Benjamin Otte [Tue, 12 Apr 2022 23:48:55 +0000 (23:48 +0000)]
Merge branch 'clarify-scrollable-docs' into 'main'

scrollable: Clarify when to set adjustment props

See merge request GNOME/gtk!4632

3 years agoscrollable: Clarify when to set adjustment props
Ivan Molodetskikh [Mon, 11 Apr 2022 07:31:52 +0000 (10:31 +0300)]
scrollable: Clarify when to set adjustment props

Instead of populating the properties right away (when the widget might
not have been allocated yet, and hence cannot know the right values),
the widget should queue an allocation, where it will populate the
values.

3 years agoMerge branch 'gles-win32' into 'main'
Benjamin Otte [Fri, 8 Apr 2022 22:00:33 +0000 (22:00 +0000)]
Merge branch 'gles-win32' into 'main'

Inspector: Fix running on Windows with GLES (was: fix running GL demos with GLES on Windows)

See merge request GNOME/gtk!4595

3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Fri, 8 Apr 2022 16:14:43 +0000 (16:14 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

gsk/gl: Typo fix

See merge request GNOME/gtk!4628

3 years agogsk/gl: Typo fix
Matthias Clasen [Fri, 8 Apr 2022 15:18:15 +0000 (11:18 -0400)]
gsk/gl: Typo fix

3 years agoMerge branch 'gdk-win32-fix-mouse-move-crossing-events' into 'main'
Luca Bacci [Fri, 8 Apr 2022 08:31:14 +0000 (08:31 +0000)]
Merge branch 'gdk-win32-fix-mouse-move-crossing-events' into 'main'

GdkWin32: Mouse events fixes

Closes #4722 and #4813

See merge request GNOME/gtk!4620

3 years agoMerge branch 'nonoverlapping-containers' into 'main'
Matthias Clasen [Thu, 7 Apr 2022 14:32:53 +0000 (14:32 +0000)]
Merge branch 'nonoverlapping-containers' into 'main'

gsk/gl: Avoid offscreening in more cases

See merge request GNOME/gtk!4619

3 years agoMerge branch 'n-docs-fixes' into 'main'
Matthias Clasen [Thu, 7 Apr 2022 14:05:40 +0000 (14:05 +0000)]
Merge branch 'n-docs-fixes' into 'main'

More doc fixes

See merge request GNOME/gtk!4618

3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Thu, 7 Apr 2022 11:46:11 +0000 (11:46 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

gl: Don't leak big glyphs

See merge request GNOME/gtk!4626

3 years agogtk-demo: Small fixup to the cursors demo
Matthias Clasen [Sun, 5 Dec 2021 03:16:01 +0000 (22:16 -0500)]
gtk-demo: Small fixup to the cursors demo

3 years agoGdkWin32: Generate crossing event after button release
Luca Bacci [Wed, 6 Apr 2022 18:01:51 +0000 (20:01 +0200)]
GdkWin32: Generate crossing event after button release

Fixes #4813

3 years agoGdkWin32: Correct generation of crossing events when holding an implicit grab
Luca Bacci [Mon, 4 Apr 2022 13:29:52 +0000 (15:29 +0200)]
GdkWin32: Correct generation of crossing events when holding an implicit grab

Fixes #4722

3 years agoGdkWin32: Report serial for events
Luca Bacci [Wed, 6 Apr 2022 17:45:50 +0000 (19:45 +0200)]
GdkWin32: Report serial for events

3 years agoMerge branch 'push-history-position-fix' into 'main'
Matthias Clasen [Wed, 6 Apr 2022 15:56:26 +0000 (15:56 +0000)]
Merge branch 'push-history-position-fix' into 'main'

gdk: always populate GDK_AXIS_{X,Y} in merged event history

Closes #4809

See merge request GNOME/gtk!4623

3 years agoMerge branch 'wip/carlosg/osk-activation' into 'main'
Matthias Clasen [Wed, 6 Apr 2022 15:44:43 +0000 (15:44 +0000)]
Merge branch 'wip/carlosg/osk-activation' into 'main'

imwayland: Connect OSK activating gesture to parent widget on editables

Closes #4795

See merge request GNOME/gtk!4624

3 years agoimwayland: Do not defer commit() after set_surrounding_text()
Carlos Garnacho [Wed, 6 Apr 2022 11:08:00 +0000 (13:08 +0200)]
imwayland: Do not defer commit() after set_surrounding_text()

For reasons that only apply to the old serial handling, asking for
the surrounding after IM changes resulted in lazy handling of
commit() afterwards.

With the recent interpretation of serials, this problem became more
apparent, since it is in fact very likely that the last interaction
step after an IM change is notifying of the changed surrounding
text after the IM change was applied.

Make handling of surrounding text similar to caret position changes,
always commit() after the state change, but skip through non-changes.

This makes the compositor state fully up-to-date after an IM change.

3 years agoimwayland: Connect OSK activating gesture to parent widget on editables
Carlos Garnacho [Wed, 6 Apr 2022 09:01:01 +0000 (11:01 +0200)]
imwayland: Connect OSK activating gesture to parent widget on editables

The gesture as connected currently on the child GtkText is easily overridden
by the parent editables (and gently done so in the attempt to consume all
clicks).

Connect this gesture to the parent editable widget in these cases, so the
gesture can cohabit with the click-consuming one. It's not part of the same
group, but it won't be abruptly cancelled.

Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4795
3 years agogdk: always populate GDK_AXIS_{X,Y} in merged event history
Hemidark [Tue, 5 Apr 2022 21:56:33 +0000 (14:56 -0700)]
gdk: always populate GDK_AXIS_{X,Y} in merged event history

Since GdkTimeCoord stores only axis values, prior to this change,
if a device didn't report GDK_AXIS_X or GDK_AXIS_Y, the history
attached to merged motion events wouldn't contain any positional
information.

Commit 6012276093ea10dc0913c38d9123c37b08a20264 already addressed
this issue for devices without tools by storing the event position
in GdkTimeCoord using GDK_AXIS_X and GDK_AXIS_Y and augmenting the
GdkTimeCoord's axis bitmask accordingly.

This change generalizes that workaround to all devices. Note that
if a device DOES report values for GDK_AXIS_X and GDK_AXIS_Y, those
values won't be overwritten.

Closes #4809

3 years agogsk/gl: Use pre-collected opacity information
Matthias Clasen [Sun, 3 Apr 2022 23:37:42 +0000 (19:37 -0400)]
gsk/gl: Use pre-collected opacity information

We now collect this information during node
construction, so use it here.

The concrete change here is that we now avoid
offscreens for container nodes with multiple children,
as long as they don't overlap. In particular, this
avoid offscreens for ellipsized dim labels.

3 years agogsk: Collect opacity information
Matthias Clasen [Tue, 5 Apr 2022 18:55:36 +0000 (14:55 -0400)]
gsk: Collect opacity information

Collect information about whether to use offscreens
for opacity during node construction, so we don't
need to walk the tree repeatedly, later.

3 years agogsk: Track disjointness of container nodes
Matthias Clasen [Sun, 3 Apr 2022 23:28:53 +0000 (19:28 -0400)]
gsk: Track disjointness of container nodes

This can be used to optimize some things in the
GL renderer.

3 years agoMerge branch 'blurry-offscreen' into 'main'
Matthias Clasen [Tue, 5 Apr 2022 12:25:59 +0000 (12:25 +0000)]
Merge branch 'blurry-offscreen' into 'main'

gsk/gl: Always align offscreen rendering with the pixel grid

Closes #3833

See merge request GNOME/gtk!4621

3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Tue, 5 Apr 2022 03:15:53 +0000 (03:15 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

gl: Don't leak big glyphs

See merge request GNOME/gtk!4622

3 years agogl: Don't leak big glyphs
Matthias Clasen [Mon, 4 Apr 2022 00:25:22 +0000 (20:25 -0400)]
gl: Don't leak big glyphs

We were never resetting the accessed bit of
glyphs that are big enough to be stored individually,
so these would just accumulate and never be dropped.

3 years agotestsuite: Add unaligned-offscreen test
Sebastian Keller [Mon, 4 Apr 2022 20:55:16 +0000 (22:55 +0200)]
testsuite: Add unaligned-offscreen test

Tests whether text rendered to an offscreen node unaligned with the
pixel grid introduces blurriness.

3 years agogsk/gl: Always align offscreen rendering with the pixel grid
Sebastian Keller [Thu, 31 Mar 2022 14:44:34 +0000 (16:44 +0200)]
gsk/gl: Always align offscreen rendering with the pixel grid

This fixes two issues with the offscreen rendering code for nodes with
bounds not aligned with the pixel grid:

1.) When drawing to an offscreen buffer the size of the offscreen buffer
was rounded up, but then later when used as texture the vertices
correspond to the original bounds with the unrounded size. This could
then result in the offscreen texture being drawn onscreen at a slightly
smaller size, which then lead to it being visually shifted and blurry.

This is fixed by adjusting the u/v coordinates to ignore the padding
region in the offscreen texture that got added by the size increase from
rounding.

2.) The viewport used when rendering to the offscreen buffer was not
aligned with the pixel grid for nodes at coordinates not aligned with
the pixel grid. Then because the content of the offscreen buffer is not
aligned with the pixel grid and later when used as textures sampling
from it will result in interpolated values for an onscreen pixel. This
could also result in shifting and blurriness, especially for nested
offscreen rendering at different offsets.

This is fixed by adding similar padding at the beginning of the
texture and also adjusting the u/v coordinates to ignore this region.

Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3833
3 years agoMerge branch 'sumibi-yakitori/fix-minimize-window-macos' into 'main'
Christian Hergert [Mon, 4 Apr 2022 18:53:19 +0000 (18:53 +0000)]
Merge branch 'sumibi-yakitori/fix-minimize-window-macos' into 'main'

macos: Fix problem that window cannot be minimized by user operation

Closes #4811

See merge request GNOME/gtk!4613

3 years agomacos: Skip running `showAndMakeKey` when a window is minimized by user action
sumibi-yakitori [Sat, 2 Apr 2022 12:29:27 +0000 (21:29 +0900)]
macos: Skip running `showAndMakeKey` when a window is minimized by user action

When a window is minimized by user action, the `showAndMakeKey` method is not executed when idle. This prevents the window from being un-minimized immediately.
And allow programmatic minimization of a window by un-minimizing them in `_gdk_macos_toplevel_surface_present`

Closes #4811

3 years agoapplication: Add link and inline code blocks
Maximiliano Sandoval R [Mon, 4 Apr 2022 12:11:16 +0000 (14:11 +0200)]
application: Add link and inline code blocks

3 years agofilter: Add link to FilterListmodel
Maximiliano Sandoval R [Mon, 4 Apr 2022 12:10:56 +0000 (14:10 +0200)]
filter: Add link to FilterListmodel

3 years agotexttag: Correct typo
Maximiliano Sandoval R [Mon, 4 Apr 2022 12:10:18 +0000 (14:10 +0200)]
texttag: Correct typo

Does not generate a gir docstring without it.

3 years agogl: Don't leak big glyphs
Matthias Clasen [Mon, 4 Apr 2022 00:25:22 +0000 (20:25 -0400)]
gl: Don't leak big glyphs

We were never resetting the accessed bit of
glyphs that are big enough to be stored individually,
so these would just accumulate and never be dropped.

3 years agoMerge branch 'sumibi-yakitori/fix-maximize-window-macos' into 'main'
Christian Hergert [Sun, 3 Apr 2022 22:14:52 +0000 (22:14 +0000)]
Merge branch 'sumibi-yakitori/fix-maximize-window-macos' into 'main'

macos: prohibit fullscreen transition if in transtion

This prevents performing additional fullscreen transitions while
a transition is already in progress.

Closes #4808

See merge request GNOME/gtk!4612

3 years agomacos: prohibit fullscreen transition if in transtion
sumibi-yakitori [Sun, 3 Apr 2022 22:14:52 +0000 (22:14 +0000)]
macos: prohibit fullscreen transition if in transtion

This prevents performing additional fullscreen transitions while
a transition is already in progress.

3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Sun, 3 Apr 2022 20:11:29 +0000 (20:11 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

inspector: Avoid a crash

See merge request GNOME/gtk!4617

3 years agoinspector: Avoid another crash
Matthias Clasen [Sun, 3 Apr 2022 19:53:52 +0000 (15:53 -0400)]
inspector: Avoid another crash

We need to handle all event types here.
This was tripping over GDK_TOUCHPAD_HOLD events.

3 years agoinspector: Avoid a crash
Matthias Clasen [Sun, 3 Apr 2022 19:53:34 +0000 (15:53 -0400)]
inspector: Avoid a crash

Attribute lists can be NULL, it turns out.

3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Sun, 3 Apr 2022 14:21:13 +0000 (14:21 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

gsk: Plug a memory leak

See merge request GNOME/gtk!4616

3 years agoMerge branch 'meson_fixes' into 'main'
Matthias Clasen [Sun, 3 Apr 2022 12:41:14 +0000 (12:41 +0000)]
Merge branch 'meson_fixes' into 'main'

meson: Use proper type for bools

See merge request GNOME/gtk!4615

3 years agocss: Plug a memory leak
Matthias Clasen [Sun, 3 Apr 2022 12:04:35 +0000 (08:04 -0400)]
css: Plug a memory leak

We were leaking the terms of calc values. Oops.

3 years agomeson: Use proper type for bools
illiliti [Sun, 3 Apr 2022 11:55:33 +0000 (14:55 +0300)]
meson: Use proper type for bools

Fix invalid usage of bools which violates official meson specification and thus
breaks muon, an implementation of meson written in C.

3 years agogsk: Plug a memory leak
Matthias Clasen [Sun, 3 Apr 2022 11:34:09 +0000 (07:34 -0400)]
gsk: Plug a memory leak

This was introduced in 9defc7fc647.

3 years agoMerge branch 'matthiasc/for-main' into 'main'
Matthias Clasen [Sat, 2 Apr 2022 19:47:03 +0000 (19:47 +0000)]
Merge branch 'matthiasc/for-main' into 'main'

imcontextsimple: Plug a memory leak

See merge request GNOME/gtk!4614

3 years agoimcontextsimple: Plug a memory leak
Matthias Clasen [Sat, 2 Apr 2022 19:22:12 +0000 (15:22 -0400)]
imcontextsimple: Plug a memory leak

3 years agoMerge branch 'selection-model-docs' into 'main'
Emmanuele Bassi [Fri, 1 Apr 2022 11:20:11 +0000 (11:20 +0000)]
Merge branch 'selection-model-docs' into 'main'

docs: Fix links in selection models

See merge request GNOME/gtk!4609

3 years agodocs: Fix links in selection models
Maximiliano Sandoval R [Fri, 1 Apr 2022 11:04:14 +0000 (13:04 +0200)]
docs: Fix links in selection models

3 years agoUpdate Indonesian translation
Andika Triwidada [Fri, 1 Apr 2022 03:56:36 +0000 (03:56 +0000)]
Update Indonesian translation

3 years agoMerge branch 'clipboard-seg' into 'main'
Matthias Clasen [Fri, 1 Apr 2022 00:56:32 +0000 (00:56 +0000)]
Merge branch 'clipboard-seg' into 'main'

x11: Check return of gdk_x11_get_xatom_name_for_display

See merge request GNOME/gtk!4607

3 years agoMerge branch 'fix-win32-empty-clipboard' into 'main'
Matthias Clasen [Fri, 1 Apr 2022 00:56:02 +0000 (00:56 +0000)]
Merge branch 'fix-win32-empty-clipboard' into 'main'

gdkclipboard-win32.c: Fix call to gdk_clipboard_claim_remote() (check GdkContentFormat is not NULL

Closes #4796

See merge request GNOME/gtk!4604

3 years agoMerge branch 'nls' into 'main'
Matthias Clasen [Thu, 31 Mar 2022 17:07:37 +0000 (17:07 +0000)]
Merge branch 'nls' into 'main'

Remove #ifdef ENABLE_NLS

See merge request GNOME/gtk!4606

3 years agoMerge branch 'wip/carlosg/immulticontext-display-switch' into 'main'
Matthias Clasen [Thu, 31 Mar 2022 16:29:38 +0000 (16:29 +0000)]
Merge branch 'wip/carlosg/immulticontext-display-switch' into 'main'

gtkimmulticontext: Handle switches between displays

Closes #4805

See merge request GNOME/gtk!4605

3 years agoMerge branch 'msys2-ci-cleanup' into 'main'
Christoph Reiter [Thu, 31 Mar 2022 15:46:54 +0000 (15:46 +0000)]
Merge branch 'msys2-ci-cleanup' into 'main'

CI: clean up MSYS2 build dependencies

See merge request GNOME/gtk!4600

3 years agoRemove #ifdef ENABLE_NLS
Xavier Claessens [Thu, 31 Mar 2022 15:41:34 +0000 (11:41 -0400)]
Remove #ifdef ENABLE_NLS

libintl API is guaranteed to always be available, glib will fallback to
proxy-libintl in case gettext is not found.

3 years agox11: Check return of gdk_x11_get_xatom_name_for_display
Dr. David Alan Gilbert [Thu, 31 Mar 2022 14:56:09 +0000 (15:56 +0100)]
x11: Check return of gdk_x11_get_xatom_name_for_display

When given an invalid atom, gdk_x11_get_xatom_name_for_display can
return NULL and trigger a seg in gdk_x11_clipboard_formats_from_atoms.
Check for NULL.

Why I'm seeing a bad atom there is probably a separate question.
https://bugzilla.redhat.com/show_bug.cgi?id=2037786

3 years agogtkimmulticontext: Handle switches between displays
Carlos Garnacho [Thu, 31 Mar 2022 14:29:34 +0000 (16:29 +0200)]
gtkimmulticontext: Handle switches between displays

Currently the GtkIMMultiContext may stick to a delegate GtkIMContext
that no longer applies after the multicontext is dissociated from
any widget.

Handle set_client_widget() so that it can handle changes between
widgets from 2 different display, but also so the delegate is made
NULL whenever the context has a NULL widget.

Doing so, any new client widget results in a new delegate IM context
lookup from the right GdkDisplay and GtkSettings, which avoids any
mix up.

Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/4805
3 years agogdkclipboard-win32.c: Fix call to gdk_clipboard_claim_remote()
Chun-wei Fan [Thu, 31 Mar 2022 02:36:45 +0000 (10:36 +0800)]
gdkclipboard-win32.c: Fix call to gdk_clipboard_claim_remote()

The call to gdk_win32_clipboard_request_contentformats() can return NULL even
without an error condition being hit (such as when the system clipboard is
empty), so check whether the returned GdkContentFormat pointer is not NULL
before calling gdk_clipboard_claim_remote(), which expects it to be not NULL,
otherwise we face a warning from that funtion and the subsequent
g_object_unref().

This at least partially fixes issue #4796.

3 years agoinspector/general.c: Check whether GL context supports WGL
Chun-wei Fan [Wed, 30 Mar 2022 02:23:49 +0000 (10:23 +0800)]
inspector/general.c: Check whether GL context supports WGL

We may well be using an EGL context that does not support Desktop (W)GL on
Windows, such as in the case of using libANGLE.  So, check whether WGL is
supported for this running instance before trying to query WGL extensions.

This will get rid of warning messages from libepoxy.

3 years agoMerge branch 'wip/exalm/scroll-hold' into 'main'
Carlos Garnacho [Mon, 28 Mar 2022 14:27:55 +0000 (14:27 +0000)]
Merge branch 'wip/exalm/scroll-hold' into 'main'

eventcontrollerscroll: Always propagate hold events

See merge request GNOME/gtk!4599

3 years agoeventcontrollerscroll: Always propagate hold events
Alexander Mikhaylenko [Sun, 27 Mar 2022 21:05:23 +0000 (01:05 +0400)]
eventcontrollerscroll: Always propagate hold events

Otherwise a stray scroll controller may prevent others from getting hold
events, even if it always propagates scroll events and does absolutely
nothing.

3 years agoUpdate Latvian translation
Rūdolfs Mazurs [Sun, 27 Mar 2022 20:19:10 +0000 (20:19 +0000)]
Update Latvian translation

(cherry picked from commit 3b50f2e8b996f92f49d2974ccff2b160905e8e73)

3 years agoUpdate Latvian translation
Rūdolfs Mazurs [Sun, 27 Mar 2022 19:53:51 +0000 (19:53 +0000)]
Update Latvian translation

(cherry picked from commit d4dd7969d64c85984d6dd1e3535347b1669ecfff)

3 years agoCI: clean up MSYS2 build dependencies
Christoph Reiter [Sun, 27 Mar 2022 17:08:36 +0000 (19:08 +0200)]
CI: clean up MSYS2 build dependencies

We only need a C compiler and not the whole toolchain,
and gst-plugins-bad was split into libraries and plugins.
pkg-config -> pkgconf.

This should speed the CI setup up a bit.