Commit Graph

68012 Commits

Author SHA1 Message Date
Timm Bäder
34ea99006f settings: Load keyfiles ourselves
This does not change anything in the case where the .init file does not
exist. We still hit the disk once. Otherwise, we now only hit it once
instead of twice and avoid a potential race-condition.
2021-01-03 11:01:29 +01:00
Timm Bäder
06cce81a97 widget: Use gtk_widget_get_native() in get_surface_allocation() 2021-01-03 11:01:29 +01:00
Timm Bäder
4a1a7940d5 gtksettings: Remove unused defines 2021-01-03 11:01:29 +01:00
Timm Bäder
1108d00014 render: Inline function into only caller 2021-01-03 11:01:29 +01:00
Timm Bäder
034672e84e frame: Remove unnecessary function
Just call the vfunc directly in the only place we used to call the old
wrapper
2021-01-03 11:01:29 +01:00
Timm Bäder
00c885c93c gesture: Replace tabs 2021-01-03 11:01:29 +01:00
Timm Bäder
114f0bd8d6 box: Replace tabs with spaces 2021-01-03 11:01:29 +01:00
Timm Bäder
24c67efdfd scrolledwindow: Use g_clear_handle_id 2021-01-03 11:01:29 +01:00
Timm Bäder
6a3748146d viewport: Small cleanup
No need to check for visibility before calling gtk_widget_measure().
2021-01-03 11:01:29 +01:00
Timm Bäder
92ec754737 widget: Move quark_builder_set_id declaration to other GQuarks 2021-01-03 11:01:29 +01:00
Timm Bäder
d11fbbc478 widget: Re-arrange some more functions 2021-01-03 11:01:29 +01:00
Timm Bäder
f11f0da11c wiget: Fix whitespace issues
Switch from tabs to spaces everywhere consistently and remove all
trailing whitespace.
2021-01-03 11:01:29 +01:00
Timm Bäder
ebdf2989f8 widget: Move a few vfunc implementations above class_init
And save us the prototypes at the top of the file this way.
2021-01-03 11:01:29 +01:00
Timm Bäder
bc35c5d494 nevertrigger: Remove unused instance members 2021-01-03 11:01:29 +01:00
Timm Bäder
70a3e5e8ce shortcutmanager: Use g_list_store_find()
We require glib 2.66 these days, so we can unconditionally use
g_list_store_find().
2021-01-03 11:01:29 +01:00
Timm Bäder
74ff61a937 gesturelongpress: Remove a useless cast
We already get a GtkGestureLongPress here.
2021-01-03 11:01:29 +01:00
Timm Bäder
280d7e57bd gesturelongpress: Keep the pspec around
So we can use it to notify(), like we do everywhere else.
2021-01-03 11:01:29 +01:00
Timm Bäder
03f5a368ec label: Remove unused private functions 2021-01-03 11:01:29 +01:00
Timm Bäder
0b15aba82a label: Remove mnemonics_visible_apply_recursively from private header
This is only used in gtklabel.c
2021-01-03 11:01:28 +01:00
Timm Bäder
d8fa9de93a label: Modernize source file
Try to sort toplevel functions to minimize unnecessary function
prototypes at the beginning of the file, get rid of all tabs and
trailing whitespace.
2021-01-03 11:01:28 +01:00
Timm Bäder
afabbc4957 gtk4-demo: Remove unused size group 2021-01-03 11:01:28 +01:00
Timm Bäder
d978ba31d6 glcontext-wayland: Whitespace 2021-01-03 11:01:28 +01:00
Timm Bäder
71efa96ef2 gesturestylus: Only add histroy element if translation succeeded
Instead of always doing it and then undoing it if the translation does
not succeed.
2021-01-03 11:01:28 +01:00
Timm Bäder
e336fe2bf8 gesturestylus: Retrieve event and controller widget only once
Make it clear that these are not gonna chance while iterating the loop.
2021-01-03 11:01:28 +01:00
Timm Bäder
d7f15c15e9 glcontext-wayland: Avoid heap-alloacting small arrays...
every frame.
2021-01-03 11:01:28 +01:00
Timm Bäder
fff570538c glcontext-wayland: Only allocate configs we use
We only use the first one, so don't allocate space for more than that.
2021-01-03 11:01:28 +01:00
Matthias Clasen
38166a67c7 NEWS: Updates 2021-01-02 20:17:19 -05:00
Matthias Clasen
01b94db73d Merge branch 'matthiasc/for-master' into 'master'
video: Tweak the docs

See merge request GNOME/gtk!3026
2021-01-02 19:04:26 +00:00
Matthias Clasen
c804645382 video: Tweak the docs
Point out the limitations and use cases of GtkVideo
and mention that GtkPicture can display video just fine.
2021-01-02 12:21:03 -05:00
Matthias Clasen
384081ce0a Merge branch 'matthiasc/for-master' into 'master'
video: Pause on unset too

See merge request GNOME/gtk!3025
2021-01-02 15:49:46 +00:00
Florentina Mușat
afccb86f7e Update Romanian translation 2021-01-02 11:21:43 +00:00
Matthias Clasen
0ba5631100 video: Pause on unset too
When new media stream is set on the GtkVideo
widget and we're autoplaying, pause the old one.

Otherwise, the music keeps playing unexpectedly.
2021-01-02 01:33:48 -05:00
Matthias Clasen
c72589f0ee Merge branch 'wip/chergert/fix-macos-compute-size' into 'master'
macos: fix compute_size and request_layout

Closes #3532

See merge request GNOME/gtk!3023
2021-01-01 23:33:01 +00:00
Matthias Clasen
f2e5775380 Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master

Closes #3506 and #3530

See merge request GNOME/gtk!3024
2021-01-01 22:48:11 +00:00
Benjamin Otte
a7164208d3 Merge branch 'video-stop' into 'master'
video: Stop playing when appropriate

See merge request GNOME/gtk!3022
2021-01-01 21:54:22 +00:00
Matthias Clasen
20f3d1608d video: Be consistent about play/pause
Always check that the stream is prepared, and the
widget is mapped, before calling gtk_media_stream_play().
2021-01-01 16:25:54 -05:00
Christian Hergert
9320148d71 macos: implement compute_size and request_layout
These functions were not implemented when the sizing changes
landed before GTK 4 was released. This fixes an issue with non-
resizeable windows not reacting to layout changes.

Fixes #3532
2021-01-01 13:17:47 -08:00
Christian Hergert
ad617a0e06 macos: avoid setHasShadow unless shadow changes 2021-01-01 13:17:47 -08:00
Christian Hergert
62af8365f6 macos: fix toplevel present function prototype
No need to return anything here.
2021-01-01 13:17:47 -08:00
Matthias Clasen
29afe5a688 video: Stop playing when appropriate
When the widget gets unrealized or hidden, pause
the mediastream. Otherwise, audio might keep playing
unexpectedly.
2021-01-01 15:17:59 -05:00
Matthias Clasen
2d3885a44a center layout: Fix handling of expanding center child
We were not taking spacing into account when adjusting
the size of an expanding center child, causing it to slip
under the end child at times.

Fixes: #3506
2021-01-01 11:02:57 -05:00
Matthias Clasen
75a297632e Merge branch 'wip/chergert/fix-macos-window-check' into 'master'
macos: ensure GdkMacosWindow in surface discovery

Closes #3533

See merge request GNOME/gtk!3021
2021-01-01 15:39:08 +00:00
Matthias Clasen
572649740e docs: Flesh out the gtk4-builder-tool man page
Add some details about the --3to4 conversion, and
set expectations.
2021-01-01 10:14:01 -05:00
Yuri Chornoivan
b5938faa06 Update Ukrainian translation 2021-01-01 14:50:35 +00:00
Matthias Clasen
a4baac7193 docs: Complete a sentence
Fixes: #3530
2021-01-01 09:40:40 -05:00
Matthias Clasen
bdde41e290 Merge branch 'encode-symbolic-debug' into 'master'
gtk4-encode-symbolic: Add debug output

See merge request GNOME/gtk!3017
2021-01-01 14:23:08 +00:00
Christian Hergert
d888402bf9 macos: ensure GdkMacosWindow in surface discovery
We want to ignore windows that are not related to those controlled
by the GDK backend.

Fixes #3533
2020-12-31 10:55:50 -08:00
Christian Hergert
378bd9fab2 Merge branch 'macos-mojave' into 'master'
macos: do not crash in mojave

See merge request GNOME/gtk!3020
2020-12-31 18:13:46 +00:00
Ignacio Casal Quinteiro
4ad5e77907 macos: do not crash in mojave
The localizedName property is not available in Mojave
so just ifdef in that case the code out.
2020-12-31 11:35:04 +01:00
Matthias Clasen
d5963ad109 Merge branch 'revert-224c2674' into 'master'
Revert "Merge branch 'gtk_egl_wayland' into 'master'"

See merge request GNOME/gtk!3018
2020-12-30 03:34:51 +00:00