Commit Graph

1121 Commits

Author SHA1 Message Date
Alexander Larsson
904f0ccb7c Base pointer grab on get-offscreen-parent 2009-06-08 19:39:14 +02:00
Alexander Larsson
4720bbc15e Make window_get_pointer a window impl virtual 2009-06-05 15:18:36 +02:00
Alexander Larsson
1d739c2ff6 Fix up gdk_window_set_has_native rename issues
Seems like i forgot a bunch of things.
2009-06-01 14:47:38 +02:00
Alexander Larsson
287b821705 Rename gdk_window_set_has_native to gdk_window_ensure_native
This also removes the (unimplemented) possibility to change a window to
non-native. This seems generally not very useful, and there are some problems
with it, for instance if two "users" need a window to be native and then
one of the "users" doesn't need it anymore it can't change it back, because
it is unaware of the other reason the window is native.
2009-06-01 11:57:59 +02:00
Alexander Larsson
d1f5050262 Make disabled xinput work again 2009-05-29 16:45:06 +02:00
Alexander Larsson
7372379c24 Initial version of input support 2009-05-29 16:39:12 +02:00
Alexander Larsson
0b586a5ad7 Add support for client side graphics exposures in gdk_draw_drawable 2009-05-27 17:10:32 +02:00
Alexander Larsson
7698daf97a Merge branch 'master' into client-side-windows
Conflicts:
	gdk/x11/gdkwindow-x11.c
2009-05-25 14:30:01 +02:00
Matthias Clasen
96912b564f Avoid another case of treating None as an atom 2009-05-24 00:30:58 -04:00
Matthias Clasen
375d19aa92 Avoid warnings when handling SelectionNotify
The property field in SelectionNotify events may be None instead
of an atom.
2009-05-17 20:41:49 -04:00
Matthias Clasen
141ddd99f3 Avoid unintended side-effect in gdk_window_get_events
Calling gdk_window_get_events() had the side-effect of letting
property change notification through to the application, which
was not intended. Now we keep StructureNotify and PropertyNotify
filtered out when they were before. Reported in bug 582003.
2009-05-10 02:08:41 -04:00
Matthias Clasen
4fc49fd8db Don't enforce property change events on the root window
The code in gdk_x11_window_set_events is only meant to enforce
property change events on child windows. Pointed out in bug 531490.
2009-05-10 01:54:43 -04:00
Matthias Clasen
6fc6b8b4e8 Add diagnostics for XID collisions
This should help with diagnosing crashes caused by over-eager XID
reuse in Xlib, see bug 581526.
2009-05-05 19:29:05 -04:00
Behdad Esfahbod
a398c840be Add git.mk to generate .gitignore files
Add four new doc templates that were not in repository.
2009-05-04 14:29:21 -04:00
Matthias Clasen
6aa6338578 Fix handling of GDK_NONE
Don't intern "NONE" and warn if GDK_NONE is converted to an
X atom. Problem pointed out in bug 580511.
2009-05-03 21:38:54 -04:00
Christian Persch
0e99a5849e Allow unsetting the icon title set with gdk_window_set_icon_name
Change gdk_window_set_icon_name to allow using NULL to unset a
previously set icon title, so that the icon title tracks the normal
title again. Bug #535557.
2009-04-20 14:53:51 +02:00
Carlos Garcia Campos
5261d14d6f Fix memory leak in gdkscreen-x11
When RandR 1.2 X driver doesn't return any usable multihead data the
monitors array is freed, without freeing the memory allocated by the array
elements before. Fixes bug #578354
2009-04-10 00:14:23 -04:00
Alexander Larsson
87459ff86c Don't move global user time backwards
When setting the user_time on a specific app to something, make sure
we're not moving the global per-display user time backwards.
2009-04-07 15:37:40 +02:00
Alexander Larsson
c72e93de16 Workaround X11 clipping bug
It turns out that XCopyArea handling of obscured source regions is
buggy. It clears the destination area even outside the GC clip
region. We work around this for the pixmap->window case as that
can happen in gtk+ and is easy to work around.

X Bug report at:
http://lists.freedesktop.org/archives/xorg/2009-February/043318.html
2009-04-02 10:15:33 +02:00
Alexander Larsson
7b67393b8a Make sure we report grab broken on window destroy 2009-04-02 10:15:30 +02:00
Alexander Larsson
5be3f38535 Move implicit grab tracking totally to common code 2009-04-02 10:15:30 +02:00
Alexander Larsson
26cbf87d7d New approach for grab tracking code
We try to track the exact grab state, i.e. whats valid on the client
now and whats comming soon via the xserver roundtrip (and when).
2009-04-02 10:15:30 +02:00
Alexander Larsson
526ff6dd68 Ref windows during _gdk_x11_roundtrip_async 2009-04-02 10:15:29 +02:00
Alexander Larsson
abb7a32fbe Fix up indentation 2009-04-02 10:15:29 +02:00
Alexander Larsson
1cc4712ea1 Move bitfield in GdkWindowImplX11 to make struct more compact 2009-04-02 10:15:29 +02:00
Alexander Larsson
a6e647863d Only sync the display if creating a native window implicitly 2009-04-02 10:15:29 +02:00
Alexander Larsson
bfd29e62b5 Update clip region etc, when creating a foreign window 2009-04-02 10:15:29 +02:00
Alexander Larsson
d9fcda1072 Don't recursively set bg none on the parent when e.g. moving children
To avoid drawing the window background of other windows in the area
where the window was we set the bg to none recursively. However, this
is quite costly it the moved window has many siblings. Furthermore, it
is uncommon that siblings overlap, so this cost has little gain.

So, we only set bg None on the parent, which means that there will
be some more flicker in the uncommon case of overlapping siblings.
2009-04-02 10:15:28 +02:00
Alexander Larsson
8de6ae26e4 Remove_gdk_pixmap_set_as_backing etc, as this is not used anymore
We don't copy from a window to a pixmap anymore, so all the code
for this can be removed.
2009-04-02 10:15:28 +02:00
Alexander Larsson
e542f734a8 Fix warning about XChangeProperty argument type 2009-04-02 10:15:28 +02:00
Alexander Larsson
3eb2b62120 Remove unused code 2009-04-02 10:15:28 +02:00
Alexander Larsson
75cb664049 Fix warning about wrong type in assignment 2009-04-02 10:15:28 +02:00
Alexander Larsson
482b333d92 Fix warning due to typo 2009-04-02 10:15:28 +02:00
Alexander Larsson
a711f51629 Fix setting of private->shaped when setting input shape
I.e. it should only be set/unset when setting ShapeBounding.
2009-04-02 10:15:28 +02:00
Alexander Larsson
fe6f46c589 Don't look for EXPOSE mask set to disable bg none setting
We always set EXPOSE in the client-side-windows world, so this
doesn't make sense anymore.
2009-04-02 10:15:28 +02:00
Alexander Larsson
cc32207534 Fix typos in X11 details of new OSX APIs 2009-04-02 10:15:27 +02:00
Alexander Larsson
016c5fd081 Track pointer grabs on Xserver time
After a successful grab/ungrab we wait for an xserver
roundtrip until we change the tracked grab in GdkDisplay.
This way that data is always up-to-date wrt events comming in.
2009-04-02 10:15:27 +02:00
Alexander Larsson
d2c1c0a8db Add _gdk_x11_roundtrip_async 2009-04-02 10:15:27 +02:00
Richard Hult
1a47356485 Remove invalidate_maybe_recurse and process_updates from the paintable interface
Replace them with two new functions
_gdk_windowing_{before,after}_process_all_updates() that are called
around the guts of gdk_window_process_all_updates(). Add empty ones
for X11 (nothing more needed), quartz ones will be implemented next.
2009-04-02 10:15:27 +02:00
Richard Hult
1ee03b35d0 Expose _gdk_window_process_updates_recurse for backends
We use this in the added windowing function
_gdk_windowing_window_process_updates_recurse. The X11 implementation
just calls _gdk_window_process_updates_recurse directly, but at least
quartz will need to do some more work.
2009-04-02 10:15:27 +02:00
Alexander Larsson
e24c9e291d Switch motion hint emulation to be serial based.
For backends not supporting serials, just have
_gdk_windowing_window_get_next_serial return zero.
2009-04-02 10:15:26 +02:00
Alexander Larsson
19cd4d6af8 Revert "Convert all pending X events in _gdk_events_queue"
This reverts commit 7cc15ec6ea1504133dfe6febbdb12615550bb966.

Its risky to convert all the events in a go like this, as it
increases the out-of-order issues. It also isn't a full solution
to the motion hint issue as it will only work for the events
we happen to convert. It would be better to use serials to
handle motion hinting.
2009-04-02 10:15:26 +02:00
Alexander Larsson
6a0d317866 Keep track of the impl windows wrapper directly with a ref
This is needed so that the ->wrapper of the impl window doesn't
go away while there are virtual windows referencing the impl
window.
2009-04-02 10:15:26 +02:00
Alexander Larsson
290de401a5 Move keyboard grab state tracking code to common code 2009-04-02 10:15:26 +02:00
Alexander Larsson
e60af9d315 Move keyboard grab info to common code
This is the first stage in tracking keyboard grabs in the common code.
This lets us handle destroying or unmapping virtual window with a
keyboard grab.
2009-04-02 10:15:26 +02:00
Alexander Larsson
c0ad534d81 Convert all pending X events in _gdk_events_queue
If we only convert the first then motion hint emulation won't
work since we don't see the next motion even until we've
fully handled this one.

However, this changes a behaviour that has been like this since
the mists of time. I don't know if it could cause other issues.
I haven't seen any yet though.
2009-04-02 10:15:25 +02:00
Alexander Larsson
7da48afcaa Don't allow native window > 65535 pixels 2009-04-02 10:15:25 +02:00
Alexander Larsson
4ec5b7648b Fix typo in pixmap window backing
It should be backing_y_offset, not backing_x_offset for exposure_y_offset.
2009-04-02 10:15:21 +02:00
Alexander Larsson
8a0ef57ba3 Don't expose a temporary grab during a scrollwheel button press/release cycle.
If we do this there is a short window where we think there is a grab, and
if we generate a client side pointer motion event in this time (e.g. from
a window move) we could be delivering that according to the grab. But in
the Xserver that grab is infinitely short as it sends Press and then
Release immediately.

To see a problem from this, try using the scrollwheel to quickly scroll
in the testgtk list of buttons.
2009-04-02 10:15:21 +02:00
Alexander Larsson
b298ebc415 Fix resize of native children
We now set the size to the right value before calling move_resize, so
the check for if the move_resize is just a move broke. Always call
move_resize()
2009-04-02 10:15:20 +02:00