Matthias Clasen
793689789c
Misc cleanups
...
Detangle compute_size, among other things.
2023-01-06 16:50:19 -05:00
Matthias Clasen
120396fa40
wip: Split off GdkWaylandPopup
...
Like the GdkWaylandToplevel split-off, this needs some
more cleanup.
2023-01-06 16:50:19 -05:00
Matthias Clasen
d61ec38974
wip: Split off GdkWaylandToplevel
...
This still needs some more cleanup.
2023-01-06 16:50:19 -05:00
Matthias Clasen
2a463baed0
wayland: Rearrange the surface code
2023-01-06 16:50:19 -05:00
Matthias Clasen
348acde6bd
wayland: Split public headers
...
Split gdkwaylandsurface.h into itself,
gdkwaylandtoplevel.h and gdkwaylandpopup.h.
This is in preparation for splitting the
types for real.
2023-01-06 13:47:34 -05:00
Matthias Clasen
5ba793842b
wayland: Split display_server sub-structs
...
Move these to GdkWaylandToplevel and GdkWaylandPopup
as appropriate.
2023-01-06 13:47:34 -05:00
Matthias Clasen
149b608bfc
wayland: Move next_layout into popup and toplevel
...
This is where it belongs.
2023-01-06 13:47:34 -05:00
Matthias Clasen
3348ea81f2
wayland: Move pending toplevel state to GdkWaylandToplevel
...
Another toplevel-only thing.
2023-01-06 13:47:34 -05:00
Matthias Clasen
63e69131bd
wayland: Move input_grab_seat to GdkWaylandPopup
...
This is popup-only functionality.
2023-01-06 13:47:34 -05:00
Matthias Clasen
d42a34b0b3
wayland: Move reposition_token to GdkWaylandPopup
...
This is only used for popups, so move it there.
2023-01-06 13:47:34 -05:00
Matthias Clasen
5ee10fc669
wayland: Move shortcuts_inhibitors to GdkWaylandToplevel
...
Another toplevel-only feature.
2023-01-06 13:47:22 -05:00
Matthias Clasen
b0a4917ce4
wayland: Move imported_transient_for to GdkWaylandToplevel
...
Another toplevel-only thing.
2023-01-06 13:47:22 -05:00
Matthias Clasen
47e22d6301
wayland: Move geometry hints to GdkWaylandToplevel
...
Another toplevel-only thing.
2023-01-06 13:47:12 -05:00
Matthias Clasen
b970b60503
wayland: Move title to GdkWaylandToplevel
...
This is a toplevel property.
2023-01-06 13:47:06 -05:00
Matthias Clasen
7406f8165d
wayland: Move drag surfaces to their own file
2023-01-06 13:46:58 -05:00
Matthias Clasen
9435e689c3
wayland: Drop create_dnd_surface
...
It is only used in one place.
2023-01-06 13:46:58 -05:00
Matthias Clasen
66c947b86b
Merge branch 'swap-3-4' into 'main'
...
docs: Place example-{3,4} in numerical order
See merge request GNOME/gtk!5319
2023-01-06 18:06:55 +00:00
Matthias Clasen
ad1af87834
Merge branch 'gtk4-fix-xdg-activation-set-surface' into 'main'
...
gdk/wayland: set requesting surface to xdg-activation
See merge request GNOME/gtk!5293
2023-01-06 14:03:01 +00:00
Matthias Clasen
68700f8722
Merge branch 'drop-file-dialog-shortcuts' into 'main'
...
filedialog: Drop shortcut folders
See merge request GNOME/gtk!5396
2023-01-06 13:35:14 +00:00
Matthias Clasen
f76270167c
Merge branch 'wip/otte/for-5496' into 'main'
...
filedialog: Never set the chooser's file
Closes #5496
See merge request GNOME/gtk!5393
2023-01-06 13:34:55 +00:00
Matthias Clasen
2a442c4fbb
Merge branch 'macos-command-symbol' into 'main'
...
macos: Use Command key symbol in Keyboard shortcuts window
See merge request GNOME/gtk!5296
2023-01-06 13:17:36 +00:00
Matthias Clasen
9356dfc404
filedialog: Drop shortcut folders
...
The filechooser portal does not support this,
and we are defaulting to using the portal now.
Lets not offer a non-functional API.
2023-01-06 07:40:57 -05:00
Matthias Clasen
7eb8439047
Merge branch 'matthiasc/for-main' into 'main'
...
testfiledialog: Be more lenient
See merge request GNOME/gtk!5395
2023-01-06 12:34:10 +00:00
Matthias Clasen
0ccf9ad8fc
testfiledialog: Be more lenient
...
Accept both open_multiple and open-multiple.
2023-01-06 07:12:36 -05:00
Arjan Molenaar
c52978dfa4
macos: Command should not come from gettext
...
Instead, just provide the right character.
See also
https://gitlab.gnome.org/GNOME/gtk/-/blob/main/gtk/gtkaccelgroup.c#L916 .
2023-01-06 12:08:55 +01:00
Matthias Clasen
52dfa54301
Merge branch 'test-file-dialog' into 'main'
...
Test file dialog
See merge request GNOME/gtk!5394
2023-01-06 04:28:28 +00:00
Matthias Clasen
b6f9e00a9e
Add a test for GtkFileDialog
2023-01-05 23:13:58 -05:00
Matthias Clasen
8780aa02d7
filedialog: Cosmetics
2023-01-05 23:06:31 -05:00
Benjamin Otte
8d5a39d765
Merge branch 'wip/corey/dnd-use-cursor' into 'main'
...
Fix accidental DnD
See merge request GNOME/gtk!5275
2023-01-05 22:39:26 +00:00
Benjamin Otte
446e6a8d62
filedialog: Never set the chooser's file
...
Instead, get by with setting the name and hope the filechooser figures
things out by itself.
Fixes #5496
2023-01-05 21:30:15 +01:00
Matthias Clasen
9b1bee99b8
Merge branch 'openuri-activation-token' into 'main'
...
Pass an activation token to OpenURI
See merge request GNOME/gtk!5389
2023-01-05 14:06:14 +00:00
Matthias Clasen
77cf0f1719
Merge branch 'filechooser-multi-folder' into 'main'
...
filechooser: Don't assert for possible cases
Closes #5494
See merge request GNOME/gtk!5392
2023-01-05 14:01:35 +00:00
Matthias Clasen
fc1f1366b4
filechooser: Don't assert for possible cases
...
switch_to_selected_folder can be called when the
selection contains more than one item. Handle it
like it used to be handled: switch to the first
folder we find.
Fixes : #5494
2023-01-05 08:41:33 -05:00
Matthias Clasen
6efd1a9dad
Pass an activation token to OpenURI
...
The OpenURI portal can take an activation_token
nowadays. So it give one.
2023-01-04 16:39:24 -05:00
Matthias Clasen
8349ae2bc4
x11: Make a call NULL-safe
...
Make it safe to call gdk_x11_app_launch_context_get_startup_notify_id
with a NULL info.
2023-01-04 16:37:31 -05:00
Matthias Clasen
7c5c843b5b
Merge branch 'matthiasc/for-main' into 'main'
...
Drop gtkmain.c from POTFILES
See merge request GNOME/gtk!5390
2023-01-04 17:22:54 +00:00
Matthias Clasen
bc11bc4f8d
Drop gtkmain.c from POTFILES
...
No longer any translations here.
2023-01-04 12:03:01 -05:00
Matthias Clasen
be24e4a1f7
Merge branch 'deprecate-toggled' into 'main'
...
Deprecate gtk_toggle_button_toggled
See merge request GNOME/gtk!5388
2023-01-04 12:57:32 +00:00
Matthias Clasen
918ff1d0f4
Deprecate gtk_toggle_button_toggled
...
The function is documented as useless.
2023-01-04 07:32:51 -05:00
Anders Jonsson
20723613bc
Update Swedish translation
2023-01-04 12:32:38 +00:00
Matthias Clasen
604aafe15d
Merge branch 'wip/carlosg/startup-vs-focus' into 'main'
...
Consider startup vs focus requests for the Wayland platform
See merge request GNOME/gtk!5386
2023-01-03 15:14:35 +00:00
Carlos Garnacho
4041ca0f69
gdkdisplay: Deprecate gdk_display_notify_startup_complete()
...
We have various layers where we store the startup ID for a request,
since this API does not have a GdkToplevel that we can refer about
for the Wayland platform, this is the most obvious candidate to
start untangling these various layers.
Deprecate this call, it is already unused in the gtk/ side.
2023-01-03 14:58:33 +01:00
Carlos Garnacho
3526d8b299
gtkapplication: Do not call gdk_display_notify_startup_complete()
...
This should do nothing worthwhile anymore, the X11/Wayland GtkApplication
implementations do already pass the startup ID from the platform_data
via windowing specific APIs, and the application handling the request
via show()/present() should trigger the activation request.
2023-01-03 14:58:33 +01:00
Carlos Garnacho
e8adfa2a88
gtkwindow: Shuffle gdk_toplevel_set_startup_id() calls
...
While this used to be tangential to windows showing or requesting
focus, the xdg-activation Wayland protocol does merge both concepts
together.
But also, for a correct interaction with the compositor, the
toolkit should ideally merge the activation request resulting from
both into the same one, so that the gdk_toplevel_focus() request
replies to the startup token that started the application and
correct focus-stealing prevention/etc happens, instead making up
one just in time for the focus request.
This kind of requires doing things in the right order, a show()
request on the GtkWindow should activate any pending activation
token on the toplevel, a present() request should additionally
create a new token if there was none pending. And
xdg_activation_v1_activate() should happen once on both.
Shuffle the gdk_toplevel_set_startup_id() calls so that this
happens in the right order for Wayland, while making X11 happy
too.
2023-01-03 14:58:33 +01:00
Carlos Garnacho
7fab1b85ad
gdk/x11: Emit "remove" s-n message from gdk_toplevel_set_startup_id
...
In the way towards deprecating gdk_display_notify_startup_complete(),
make gdk_toplevel_set_startup_id() on X11 perform this piece of messaging
itself. It should be harmless that the message is emitted twice, if
callers do still use that API.
2023-01-03 14:58:25 +01:00
Carlos Garnacho
5aeabdb3d4
gdk/wayland: Perform xdg_activation on gdk_toplevel_set_startup_id
...
This call has everything to perform activation as specified by the
xdg_activation protocol, notably a surface to activate as opposed to
gdk_display_notify_startup_complete().
Make activation happen here, so that the surface gets activated when
its gets a startup ID assigned.
2023-01-03 14:57:49 +01:00
Carlos Garnacho
6f01f846dc
gtkwindow: Minor refactor
...
Move the handling of the startup ID to a separate function, since
this will be called from several places.
2023-01-03 14:57:44 +01:00
Matthias Clasen
3c4f6144a0
Merge branch 'fix-introspection' into 'main'
...
meson.build: build introspection according to option only
See merge request GNOME/gtk!5382
2023-01-03 11:56:49 +00:00
Alexander Kanavin
ae71d338d7
meson.build: build introspection according to option only
...
The way the check is written, if the build is native, then the
introspection option has no effect.
Particularly yocto project does want to disable introspection in
native builds and enable it in cross builds (both via the option),
and without this patch the former is not possible.
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
2023-01-03 08:26:07 +01:00
Matthias Clasen
8b469a2727
Merge branch 'nullable-gdk' into 'main'
...
gdk_display_open: Mark arg as nullable
See merge request GNOME/gtk!5380
2023-01-03 00:25:55 +00:00