Commit Graph

3152 Commits

Author SHA1 Message Date
Johan Dahlin
3871291ba3 Make sure Gdk-2.0.gir is installed
Fixes a variable name typo
2010-04-03 20:53:47 -04:00
Johan Dahlin
9242d1414d Avoid warnings when introspetion is not available
-include is the same as include but will never warn if the
file is not available
2010-04-03 20:53:47 -04:00
Johan Dahlin
e4ac9609a2 Fix build with system install of introspection
Or redo it properly and remove previous hack by Matthias.
2010-04-03 20:53:47 -04:00
Kristian Rietveld
b8fa675a6a Release view after setting it as contentView
Fixes GdkQuartzView being leaked.
2010-04-03 20:53:47 -04:00
Kristian Rietveld
969ff4c863 Fix memleak in get_nsscreen_for_point()
One codepath did not go through GDK_QUARTZ_RELEASE_POOL, refactored
the code to fix this.
2010-04-03 20:53:47 -04:00
Kristian Rietveld
81cf73ae8a Fix memory leak in GdkQuartzView
Should remove the tracking rect in dealloc.
2010-04-03 20:53:46 -04:00
Kristian Rietveld
8273349eca Use CGFLOAT_DEFINED, don't rely on NSINTEGER_DEFINED for this 2010-04-03 20:53:46 -04:00
Kristian Rietveld
0d51400b29 Add gdk_keymap_map_virtual_modifiers() to Quartz backend 2010-04-03 20:53:46 -04:00
Kristian Rietveld
f7daeec10f Start using CGFloat
Fixes a bunch of compiler warnings.  Since CGFloat does not exist on
Tiger and earlier, we have added a typedef likewise as was done for
NSInteger.
2010-04-03 20:53:46 -04:00
Kristian Rietveld
5d3e414994 Fix compile warning in gdk_cursor_new_from_pixmap 2010-04-03 20:53:46 -04:00
Kristian Rietveld
b86b00b387 initWithContentRect: has a NSUInteger parameter now
The typedef in place for Tiger and earlier systems should change this
to unsigned int without problems.
2010-04-03 20:53:46 -04:00
Kristian Rietveld
e9b593c2e6 Start using NSInteger and NSUInteger
These have been introduced in Leopard and default to int and unsigned int.
In 64-bit Snow Leopard they are long and unsigned long.  This caused issues
with the getRectsBeingDrawn message which needs a pointer to a NSInteger
(long on 64-bit!) but we passed in an integer.  Surprisingly this problem
was visible when compiling with -O0 (segfault), but *not* when compiling
with -O1.  Other messages were NSInteger is now needed have also been
adapted.

Since NSInteger and NSUInteger are not available on Tiger, a define
has been added to add typedefs for these when they have not been defined
by the system headers.
2010-04-03 20:53:44 -04:00
Tor Lillqvist
a75065a458 Add gdk_keymap_map_virtual_modifiers() implementation 2010-04-03 20:53:38 -04:00
Matthias Clasen
afbc052916 Fix a think in the CSW input extension handling
This was causing stack overflow due to an obvious infinite recursion.
See e.g. RH #548849.
2010-04-03 20:53:38 -04:00
Matthias Clasen
d1c3745b07 Try harder to handle accelerators involving virtual modifiers
This patch changes GDK to add all matching virtual modifiers in
the state field of the key event. The corresponding GTK+ change makes
use of a new GdkKeymap function to map virtual modifiers back to
real modifiers and detect conflicts while doing so.

This should fix bug 603190 and bug 427409.
2010-04-03 20:53:37 -04:00
Matthias Clasen
4bc8dcede8 Properly free damage events
This was reported in bug 605008
2010-04-03 20:51:57 -04:00
Matthias Clasen
360820e9bf Fix a thinko in computing damage for segments
The code was not taking the endpoint of the first segment into account.
This was reported in bug 604747.
2010-04-03 20:51:56 -04:00
Matthias Clasen
214d5efdd4 Ensure native windows in gdk_property_change
Using X properties on non-toplevel windows is somewhat exotic,
but some people seem to do it, so better to keep it working.
See bug 604787.
2010-04-03 20:51:55 -04:00
Alexander Larsson
89ac81e767 Actually send exposes from gdk_window_clear_area_e 2010-04-03 20:51:55 -04:00
Javier Jardón
0c991c5645 Add 'Since: 2.18' tag
Add missing 'Since:' tag in gdk_window_get_root_coords() and
gdk_window_is_destroyed()

Reported by Rafal Luzynski in
https://bugzilla.gnome.org/show_bug.cgi?id=604821
2010-04-03 20:51:55 -04:00
Tor Lillqvist
9d4e82a0dc Make the OLE2 DND code selectable at run-time instead of compile-time
(It still doesn't work, though.)
2010-04-03 20:51:54 -04:00
Johan Dahlin
3a4f027074 Use Makefile.introspection
Use the new fancy rules from the Makefile.introspection, it makes
the rules prettier and avoids quite a bit of duplication
2010-04-03 20:51:54 -04:00
Johan Dahlin
6c9bfc5f39 Make sure dist check works with introspection
We need to prepend the srcdir to all variables
passed into the scanner as it runs with srcdir != builddir during
distcheck.
2010-04-03 20:51:53 -04:00
Johan Dahlin
9d4674a5ec Re-add accidentially removed gtkintl header 2010-04-03 20:51:53 -04:00
Johan Dahlin
7c0624aa92 Separate private from public gdk headers
We don't want to parse the private gdk headers when
creating the GIR.
2010-04-03 20:51:52 -04:00
Colin Walters
f584679cfa Merge in Gdk-custom.c introspection annotations
The Gdk-custom.c file in gir-repository contained a number of
introspection annotations.  Merge those into the GDK source files.

Some documentation was moved from the tmpl/ files to accomodate
the addition of annotations.

https://bugzilla.gnome.org/show_bug.cgi?id=592279
2010-04-03 20:51:51 -04:00
Colin Walters
41342b23e5 Build introspection data for gdk-pixbuf, gdk, and gtk
Generate .gir and .typelib files for gdk-pixbuf, gdk, and gtk.

https://bugzilla.gnome.org/show_bug.cgi?id=592279
2010-04-03 20:51:51 -04:00
Tor Lillqvist
3546feb389 Add copyright note and comment for merged old code 2010-04-03 20:51:51 -04:00
Tor Lillqvist
af37f76bc6 Work on OLE2-based generic DND
Intermediate commit of work in progress on integrating the old code
for OLE2-based generic drag and drop from Arhaeopteryx Software, from
a long time ago in the GTK+ 1.3 timeframe. Does still not work and is
as before not compiled in unless OLE2_DND is defined in
gdkdnd-win32.c. (Thus, for inter-process DND, still only WM_DROPFILES
style dropping of files on GTK+ apps works.)

Related slight refactoring of other code that shouldn't change how it
works. Add more global variables for run-time constants (once
initialized) representing well-known GdkAtoms and registered Windows
clipboard formats, as they with the generic DND code will be needed in
several source files. Some improved debugging output.
2010-04-03 20:51:51 -04:00
Tor Lillqvist
e5b4a51b6b Make more GdkAtom variables visible in all gdk/win32 files
Make the GdkAtoms for the image formats extern and usable from all
gdk/win32 files.
2010-04-03 20:51:51 -04:00
Tor Lillqvist
750fa5398e Make the gdk/win32 event debug printing function non-static
Make print_event() extern and rename it to _gdk_win32_print_event() so
it can be used from all gdk/win32 source files.
2010-04-03 20:51:51 -04:00
Tor Lillqvist
e70ef71c3a Remove unused functions and variables 2010-04-03 20:51:50 -04:00
Matthias Clasen
182108c68e Implement gdk_screen_get_primary_monitor in all GDK backends
The implementations are all trivial, just returning 0. At least
for Quartz, we could probably do better than that. Bug 604459.
2009-12-13 20:40:02 -05:00
Cody Russell
53ab5c0b63 Add gdk_screen_get_primary_monitor to gdk.symbols 2009-12-09 23:20:30 -06:00
Cody Russell
662e69ad3e Add gdk_screen_get_primary_monitor(). This fixes bug #601712 2009-12-08 11:27:02 -06:00
Matthias Clasen
0748cf563d Never do implicit paints for foreign windows
They don't need double buffer combination since they have no
client-side children, and creating pixmaps for them is risky
since they could disappear at any time.

May fix bug 598476 and 603652.
2009-12-08 10:09:04 -05:00
Matthias Clasen
105b007545 Set colormap of offscreen pixmaps
This fixes problems in clutter-gtk. See bug 603619.
2009-12-08 09:58:23 -05:00
Alexander Larsson
22d1d0d507 Fix up last commit 2009-12-08 12:28:44 +01:00
Alexander Larsson
159214173d Handle input extension events when making a window native
It may happen when turning a client side window into a native window
that the window, or some of its children with the same native parent
have extension events enabled, and thus have an input window enabled
for the native parent which needs to change as the window is made
native.

We fix this by temporarily disabling extension events on all the affected
windows while we create the native window, and then reenable them afterwards.

This fixes: https://bugzilla.redhat.com/show_bug.cgi?id=544624
2009-12-08 12:22:59 +01:00
Alexander Larsson
98a9c5c69a Fix damage report for lines drawn on offscreen windows
All kinds of lines (lines, segments, arcs, etc) need to take into
account the line properties (width, miter limit, joins, caps, etc)
to get proper damage extents.

This is not really possible to do, but we can make it likely to work
with some ad-hoc estimates.

Fixes bug 603904.
2009-12-07 10:49:57 +01:00
Alexander Larsson
48fc0f36c2 Fix mouse pointer handling on multiple screens
The fix in 786b589d95 for the
"Cannot click buttons more than once without moving the mouse cursor"
did not correctly handle setups with multiple screens in one display.

We need to handle the case where the first XQueryPointer returns
a different root window than the default one.

This fixes bug 597386 (agaion)
2009-12-07 10:49:57 +01:00
Alexander Larsson
b509f28559 Don't filter out BUTTON_MOTION event masks
We don't really need to filter these out, it was just a leftover
safety check to not override the GDK_POINTER_MOTION_MASK.

Furthermore when we changed behaviour to not always select for native
pointer motion it is actually wrong. We'll still get normal motion
events for the toplevel which we will emulate as button motion on the
child, but the button motion mask will not be inherited by implicit
grabs which makes us not get any motion events during grabs.

This fixes bug 601473
2009-12-02 11:19:21 +01:00
Javier Jardón
ee2c797e70 [gdk/directfb] Made dfb_events_dispatch() thread save
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=591438
2009-11-30 06:02:49 +01:00
Matthias Clasen
36ca3fd5e9 Add a missing include
memset() is used in gdk/x11/gdkinput-xfree.c but string.h is not included.
Patch by Vincent Untz, bug 597026.
2009-11-27 20:59:42 -05:00
Matthias Clasen
43a07af9b1 Be a bit more forgiving about invalid monitor number
By moving the g_return_if_fail() checks into individual monitor functions.
See bug 561130.
2009-11-27 18:39:15 -05:00
Matthias Clasen
5bfab2b9d4 Short-circuit get_frame_extents for override-redirect windows
There's no reason to do our expensive round-trips for an override-redirect
window; just use local information. See bug 581145. Patch by Owen Taylor.
2009-11-27 18:19:20 -05:00
Matthias Clasen
d4b92737ab Make level3 keys work again
We were not paying attention to consumed modifiers when adding
virtual modifiers. This fixes RH bug 537567.
2009-11-25 01:02:40 -05:00
Kristian Rietveld
cffddd2adc Document how Cocoa coordinate and monitor layout transforms to GDK work 2009-11-15 15:29:45 +01:00
Tor Lillqvist
7fda8e6378 Awful hack for problem in dnd of images from Firefox on Windows
Bypassed with #if 0 because it is an awful hack and not really
acceptable from a privacy point of view for instance. It prevents
Firefox from deleting temporary files containing images being dragged,
so they stay on disk. Bug #561973.
2009-11-15 00:37:17 +02:00
Kjartan Maraas
d03b53800e Fix typo 2009-11-11 21:39:32 +01:00