Matthias Clasen
08c699c745
wayland: Handle scale 3 for cursors
...
This is just a bandaid solution to make scale 3 work.
If people seriously want to go for scales larger than
that, we need a better solution.
2017-12-17 16:41:54 -05:00
Benjamin Otte
f824439137
dnd: Get rid of IPC widgets
...
Instead, pass the source window to gdk_drag_begin().
Also make Wayland use this window instead of the one under the pointer
(though those 2 Windows are most likely the same anyway).
2017-12-16 02:48:12 +01:00
Benjamin Otte
3438dcdd4e
x11: Add necessary NULL check
2017-12-16 02:48:12 +01:00
Benjamin Otte
aab86f8b98
x11: Try getting ipc_window vs source_window right
...
This is in preparation for splitting these. Unfortunately, source_window
== ipc_window, so this isn't very debuggable yet.
2017-12-16 02:48:12 +01:00
Benjamin Otte
510581e0ef
x11: Use gdk_drag_context_get_display()
2017-12-16 02:48:12 +01:00
Benjamin Otte
5f326d7ec6
x11: Create IPC window outselves
...
Ignore the passed in IPC window.
2017-12-16 02:48:12 +01:00
Benjamin Otte
a04afde35c
gdk: Remove DRAG_STATUS and DROP_FINISHED events
...
Those are source-side events that are handled by signals of the
Dragontext these days.
2017-12-15 23:48:36 +01:00
Matthias Clasen
61843d60b2
x11: Avoid crash in fallback move emulation
...
Quietly do nothing when there is already an ongoing operation.
This matches the behavior of the ewmh code, and is much nicer
than a crash.
https://bugzilla.gnome.org/show_bug.cgi?id=789054
2017-12-15 16:19:09 -05:00
Matthias Clasen
fa27d171d0
Drop gdk_keymap_get_for_display
...
It has been replaced by gdk_display_get_keymap.
2017-12-15 07:46:35 -05:00
Matthias Clasen
e92c0e85ec
Replace gdk_keymap_get_for_display by gdk_display_get_keymap
...
Replace all uses of the old function by the new one.
No functional change.
2017-12-15 07:44:58 -05:00
Matthias Clasen
1012bbeecf
Add gdk_display_get_keymap
...
This is just a better name for gdk_keymap_get_for_display.
2017-12-15 06:53:13 -05:00
Matthias Clasen
fd85ff0c7a
Drop gdk_keymap_get_default()
...
It is better to use the explicit keymap getter - the
default display may not even use the current gdk backend.
2017-12-14 23:57:54 -05:00
Matthias Clasen
9194ee4973
gdk: Drop GDK_DAMAGE
...
We haven't been generating events of this type
since we dropped offscreen windows.
2017-12-14 23:35:08 -05:00
Matthias Clasen
65fc43a1f3
Drop GDK_CLIENT_EVENT
...
We never generate events of this type, so no need
to carry it around.
2017-12-14 22:55:03 -05:00
Matthias Clasen
8d42ab6b91
gdk: Remove explicit event type numbering
...
The numeric values of event types are irrelevant,
so we don't need to declare them explicitly.
2017-12-14 22:43:53 -05:00
Matthias Clasen
bcf570cc16
Move code around
...
gdk_window_set_state is now an ordinary (private) setter,
so it should live in gdkwindow.c.
2017-12-14 22:35:27 -05:00
Matthias Clasen
11a946df39
gdk: Drop GdkEventWindowState
...
No longer generate this event. Instead, emit change
notification for GdkWindow::state.
2017-12-14 22:24:06 -05:00
Matthias Clasen
e5b1867118
gdk: Add a GdkWindow::state property
...
This will eventually replace the window state event.
2017-12-14 22:24:06 -05:00
Benjamin Otte
84431ab927
x11: Remove GdkAtom usage from dnd code
...
Use strings instead.
2017-12-14 13:46:37 +01:00
Benjamin Otte
5d70bbf4c4
display: Remove leftover old clipboard APIs
2017-12-14 13:35:32 +01:00
Krzesimir Nowak
5a0fb278d1
x11: Fix erroneous & to be &&
2017-12-14 13:35:32 +01:00
Benjamin Otte
920259c250
x11: Get rid of default Atom converters
...
No, using the default Wayland display is not okay to query Atoms.
2017-12-14 13:35:32 +01:00
Benjamin Otte
52b1a46549
device: Make axis label a regular string
...
Atoms are about to die.
2017-12-14 13:35:32 +01:00
Matthias Clasen
84eaf3da7d
Drop atom-related cast macros
...
These don't really add anything, just drop them.
2017-12-13 23:47:02 -05:00
Matthias Clasen
54a6273191
Drop gdk_atom_intern
...
Atoms are just interned strings now, so we can just
use g_intern_string.
2017-12-13 23:39:03 -05:00
Matthias Clasen
4c083c1ed4
Drop gdk_atom_name
...
Since atoms are just interned strings now, we can just
cast them to const char * where needed.
2017-12-13 23:26:23 -05:00
Benjamin Otte
b49a9b9933
dnd: Remove gdk_drag_get_selection()
...
Without selections, drags can't have them either.
Also included is removing the selection from GtkSelectionData.
Includes a bunch of crude cleanups to Wayland code that no longer has to
care about selection atoms.
2017-12-14 04:39:22 +01:00
Benjamin Otte
65fcff87b2
gdk: Remove ability to request selection notifications
...
Without selections, that's kinda pointless.
2017-12-14 04:20:48 +01:00
Benjamin Otte
f2bb2024c8
gdk: Remove properties
...
They are not used anymore.
Gone with them are PropertyNotify events.
2017-12-14 03:05:34 +01:00
Benjamin Otte
82aa0eacb2
broadway: Make compile after GdkEvent objectification
2017-12-14 03:05:34 +01:00
Benjamin Otte
d7f34874ab
x11: Make unsetting transient-for work
...
... and just unset it from GtkWindow instead of fiddling with
properties.
2017-12-14 03:05:34 +01:00
Benjamin Otte
a4b42f0b73
gdk: Remove selection defines
...
And with it, remove the selections section from the docs.
So selections are gone for good now.
2017-12-14 03:05:34 +01:00
Carlos Garnacho
2f65a2f5cc
gdk: Make gdk_display_peek_event() Return a reference to the event
...
No need to copy it.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
b03d3fb268
gdk/wayland: s/gdk_event_free/g_object_unref/
2017-12-14 01:05:48 +01:00
Carlos Garnacho
3021edc38d
gdk/x11: s/gdk_event_free/g_object_unref/
2017-12-14 01:05:48 +01:00
Carlos Garnacho
f79ac6d30b
gdk: Remove gdk_window_[gs]et_event_compression()
...
Motion compression is now the unmodifiable default, callers may
call gdk_event_get_motion_history() to check the uncoalesced
motion history.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
ea216accd7
gdk: Implement motion history as motion event data
...
In the motion compression phase the coalesced events will be saved
as a GdkTimeCoord on the motion event that shall be delivered.
For simplicity (and because history doesn't make much sense otherwise)
event history is only recorded while there are buttons pressed, this
also tidily ensures that those coalesced events would have the same
target widget on the gtk side than the delivered one, because of
implicit grabs.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
a040ed55cc
gdk: Keep reference on tools from motion/button events.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
8c9231dbb4
gdk: Move additional code in gdk_event_new() to GdkEvent::constructed
...
Now that the type is a construct only property, we can initialize the
event fields properly here.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
5ee1d4893a
gdk: Make GdkEvent type a construct only property
...
So it must be set at the time of doing g_object_new().
2017-12-14 01:05:48 +01:00
Carlos Garnacho
ca89ad75b4
gdk: Remove gdk_event_is_allocated()
...
All events are allocated now.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
2acbb7b01d
gdk: Turn GdkEvent into a GObject
...
Two warts remain. gdk_event_copy() should be unnecessary as
events should be considered static after delivery, so g_object_ref()
should be just as good. There's a few exceptional cases that the event
is copied and then modifier for later processing, those cases should be
reconsidered individually.
And gdk_event_free() could be likewise turned into g_object_unref(),
many callers remain though.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
1e1f2a6e67
gdk: Remove GdkDisplay from GdkEventPrivate
...
And add it to GdkEventAny.
2017-12-14 01:05:08 +01:00
Carlos Garnacho
8595e4b1d1
gdk: Figure out the GdkSeat of an event from the GdkDevice
...
Removes the need for gdk_event_set_seat() and the GdkSeat field from
GdkEventPrivate.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
526486da6b
gdk: Use allocated events
...
Stack allocated GdkEvent structs will not be ok when events become
objects.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
59cab36035
gdk: Fold GdkEventPrivate fields into event structs
...
Now all events structs are private, it doesn't make as much sense
having GdkEventPrivate wrapping allocating events. This is a first
step towards removing it.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
64decbfd74
gdk: Remove GdkEventType argument from GdkEvent union
...
It won't stand true anymore that the GdkEventType argument is the
first field of the GdkEvent* structs. All callers have been updated
to use event->any.type instead.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
b9db0b55cb
gdk: Refurbish GdkEvent struct hierarchy
...
Make all specific event structs contain a GdkEventAny, so the base
struct can be extended without modifying structs all over the place.
2017-12-14 00:58:32 +01:00
Benjamin Otte
54f9aef0d4
gdk: Remove gdk_selection_convert()
...
It's not used anymore.
2017-12-14 00:44:26 +01:00
Benjamin Otte
ca5f859dc8
dnd: Only send DELETE request on X11
...
This is Xdnd-specific and doesn't need to happen elsewhere.
2017-12-13 23:52:55 +01:00