Commit Graph

2237 Commits

Author SHA1 Message Date
Richard Hult
7d9ac29c93 Patch from Paul Davis to implement this in terms of scrollRect, fixes bug
2007-10-08  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (move_resize_window_internal):
	Patch from Paul Davis to implement this in terms of scrollRect,
	fixes bug #478377.

svn path=/trunk/; revision=18895
2007-10-08 17:30:02 +00:00
Richard Hult
7d66affd26 Don't do anything while in fullscreen mode. (gdk_window_set_decorations):
2007-10-02  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_move),
	(gdk_window_resize): Don't do anything while in fullscreen mode.
	(gdk_window_set_decorations): Update the size of the window after
	showing/hiding the title bar so the size of the content area
	doesn't change.
	(gdk_window_get_decorations): NSBorderlessWindowMask is 0, so
	don't try to check it as a bit being set.
	(gdk_window_fullscreen), (gdk_window_unfullscreen): Implement.

svn path=/trunk/; revision=18875
2007-10-02 17:51:06 +00:00
Kristian Rietveld
eab3ef3145 Fixes #426246.
2007-09-12  Kristian Rietveld  <kris@imendio.com>

	Fixes #426246.

	* gdk/gdk.symbols:
	* gdk/gdkwindow.[ch]
	(gdk_window_freeze_toplevel_updates_libgtk_only),
	(gdk_window_thaw_toplevel_updates_libgtk_only): new functions
	to freeze a toplevel window and all its descendants.  To be made
	public in 2.14,
	(gdk_window_schedule_update): return if toplevel is frozen,
	(gdk_window_process_all_updates): defer processing updates if toplevel
	is frozen.

	* gtk/gtkwindow.c (gtk_window_configure_event): directly size
	allocate for override redirect windows, freeze toplevel and
	descendants otherwise and wait until resizing is done.


svn path=/trunk/; revision=18802
2007-09-12 17:13:24 +00:00
Behdad Esfahbod
c99b1edf39 Fix serial number comparison regression introduced recently. (#474897)
2007-09-10  Behdad Esfahbod  <behdad@gnome.org>

        * gdk/x11/gdkgeometry-x11.c (gdk_window_queue),
        (_gdk_window_process_expose): Fix serial number comparison regression
        introduced recently. (#474897)


svn path=/trunk/; revision=18789
2007-09-10 18:07:39 +00:00
18:22:28 Tim Janik
57e8bdcb54 fix invalid list node accesses, spotted by Benjamin Berg, bug #475158.
2007-09-09 18:22:28  Tim Janik  <timj@gtk.org>

        * gdk/x11/gdkgeometry-x11.c (_gdk_window_process_expose): fix invalid
        list node accesses, spotted by Benjamin Berg, bug #475158.



svn path=/trunk/; revision=18769
2007-09-09 16:24:34 +00:00
Matthias Clasen
835c0a1510 Allow dest to be NULL. (#464528, Xan Lopez)
2007-09-06  Matthias Clasen  <mclasen@redhat.com>

        * gdk/gdkrectangle.c (gdk_rectangle_intersect): Allow
        dest to be NULL.  (#464528, Xan Lopez)



svn path=/trunk/; revision=18742
2007-09-07 03:53:23 +00:00
Richard Hult
8b6f388cbc Patch from William Pitcock: Ungrab windows if necessary when they are
2007-09-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c (_gdk_windowing_window_destroy):
	Patch from William Pitcock: Ungrab windows if necessary when they
	are destroyed, fixes bug #473441.

svn path=/trunk/; revision=18727
2007-09-06 08:16:40 +00:00
Richard Hult
3b2e8eacf1 Implement those. Based on patch from Stefan Gehn, bug #459459.
2007-08-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_set_decorations,
	gdk_window_get_decorations): Implement those. Based on patch from
	Stefan Gehn, bug #459459.

svn path=/trunk/; revision=18704
2007-08-30 09:01:12 +00:00
Richard Hult
ecfa539307 Patch from Stefan Gehn to implement those, bug #459667.
2007-08-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_set_keep_above,
	gdk_window_set_keep_below): Patch from Stefan Gehn to implement
	those, bug #459667.

svn path=/trunk/; revision=18703
2007-08-30 08:21:32 +00:00
Richard Hult
af1b34d494 Patch from Stefan Gehn to implement copying from a pixmap, bug #348493.
2007-08-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkimage-quartz.c: (_gdk_quartz_image_copy_to_image):
	Patch from Stefan Gehn to implement copying from a pixmap, bug
	#348493.

svn path=/trunk/; revision=18702
2007-08-30 07:57:25 +00:00
Tim Janik
592dc62de8 fix X serial handling to cope with wraparounds and maintain referential
Thu Aug 23 15:32:09 2007  Tim Janik  <timj@imendio.com>

	* gdk/x11/gdkgeometry-x11.c (_gdk_window_process_expose): fix
	X serial handling to cope with wraparounds and maintain referential
	integrity when removing list nodes. based on a patch by Hui Wang,
	fixes #461648.

svn path=/trunk/; revision=18693
2007-08-28 15:26:23 +00:00
Cody Russell
d59a6d2a6a Committing changes to the source bdf font file that I forgot to commit
2007-08-16  Cody Russell  <bratsche@gnome.org>

	* gdk/win32/cursor.bdf: Committing changes to the source
	bdf font file that I forgot to commit yesterday for #458088.


svn path=/trunk/; revision=18639
2007-08-17 03:40:39 +00:00
Cody Russell
a30a76c3e0 Modified the sb_h_double_arrow and sb_v_double_arrow mouse cursors to
2007-08-15  Cody Russell  <bratsche@gnome.org>

        * gdk/win32/xcursors.h: Modified the sb_h_double_arrow and
        sb_v_double_arrow mouse cursors to match the ones that Windows
        uses for split container controls.  This allows our paned
        widgets to be more easily identified as paned widgets on
        Windows, since we don't have any prelighting on the draggable
        pane part.  (#458088)


svn path=/trunk/; revision=18621
2007-08-15 14:58:45 +00:00
Björn Lindqvist
e1f1121149 Note in docs that @dest's width and height is set to 0, 0 if the
2007-08-11  Björn Lindqvist  <bjourne@gmail.com>

	* gdk/gdkrectangle.c (gdk_rectangle_intersect): Note in docs
        that @dest's width and height is set to 0, 0 if the rectangles
        does not intersect. (#464524)

svn path=/trunk/; revision=18602
2007-08-10 23:34:26 +00:00
Behdad Esfahbod
69cce50cd0 Revert commit that was accidentally made. Sorry.
svn path=/trunk/; revision=18596
2007-08-08 22:30:26 +00:00
Behdad Esfahbod
398a61e43d Use gtk_true instead of rolling a new one. Patch from Xan Lopez.
2007-08-08  Behdad Esfahbod  <behdad@gnome.org>

        * gdk/gdkwindow.c (gdk_window_invalidate_region): Use gtk_true
        instead of rolling a new one.  Patch from Xan Lopez.


svn path=/trunk/; revision=18595
2007-08-08 22:25:58 +00:00
Richard Hult
b0b47c9b49 Implement, fixes bug #405868. Based on patch from metz81@web.de.
2007-07-31  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_get_geometry):
	Implement, fixes bug #405868. Based on patch from metz81@web.de.

svn path=/trunk/; revision=18560
2007-07-31 19:25:28 +00:00
Attilio Fiandrotti
fc81607f22 Attempts to load stock X cursors no longer results in annoying error messages under DirectFB
svn path=/trunk/; revision=18549
2007-07-27 16:27:37 +00:00
Tor Lillqvist
441f048426 Cosmetic changes.
2007-07-24  Tor Lillqvist  <tml@novell.com>

	* gdk/win32/gdkkeys-win32.c (update_keymap): Cosmetic changes.


svn path=/trunk/; revision=18538
2007-07-24 14:40:21 +00:00
Matthias Clasen
6ec22dfc1d Documentation fixes
svn path=/trunk/; revision=18522
2007-07-22 04:19:19 +00:00
Ryan Lortie
f0cfba930c add note that the semantics of this call, when mixed with the new
2007-07-20  Ryan Lortie  <desrt@desrt.ca>

        * gtk/gtkwidget.c (gtk_widget_is_composited): add note that the
        semantics of this call, when mixed with the new
        gdk_window_set_composited(), will change in the future.

        * gdk/x11/gdkevents-x11.c (gdk_event_translate): only grab Damage
        events that belong to us.


svn path=/trunk/; revision=18506
2007-07-19 23:50:39 +00:00
Richard Hult
032b0aab6b Ref the cursor in the cached case.
2007-07-18  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkcursor-quartz.c (gdk_cursor_new_for_display): Ref
	the cursor in the cached case.

svn path=/trunk/; revision=18490
2007-07-18 09:52:25 +00:00
Richard Hult
eb52c4f1f8 Plug leak.
2007-07-14  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c:
	(_gdk_quartz_events_update_cursor): Plug leak.

svn path=/trunk/; revision=18468
2007-07-14 12:14:36 +00:00
Richard Hult
ed82448b9a Move from here... ...to here. (_gdk_windowing_window_destroy): Update the
2007-07-13  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkprivate-quartz.h:
	* gdk/quartz/gdkevents-quartz.c: (gdk_window_is_ancestor): Move
	from here...
	* gdk/quartz/gdkwindow-quartz.c: (_gdk_quartz_window_is_ancestor):
	...to here.
	(_gdk_windowing_window_destroy): Update the mouse window if the
	destroyed window is an ancestor of the current one, not only if
	they are the same.
	(gdk_window_hide): Update the mouse window here too.

svn path=/trunk/; revision=18467
2007-07-13 19:09:10 +00:00
Richard Hult
7f66d205e8 Add stubs.
2007-07-13  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkcolor-quartz.c: (gdk_colors_alloc),
	(gdk_colors_free): Add stubs.

svn path=/trunk/; revision=18466
2007-07-13 19:02:07 +00:00
Cody Russell
e992008541 gdk/win32/gdkevents-win32.c Fix transient windows on Win32 so that when a
2007-07-12  Cody Russell  <bratsche@gnome.org>

	* gdk/win32/gdkevents-win32.c
	* gdk/win32/gdkwindow-win32.[ch]: Fix transient windows on Win32 
	so that when a transient child window is closed (particularly when 
	there are 3 or more levels of transient windows), the correct window
	receives focus rather than a seemingly random window. (#112404) 


svn path=/trunk/; revision=18461
2007-07-12 23:38:30 +00:00
Attilio Fiandrotti
34dfd591da Fixed memory leak at window closing in DirectFB backend, patch provided by Simon Lanzmich
svn path=/trunk/; revision=18459
2007-07-12 17:09:02 +00:00
Tim Janik
508baa258c clarified documentation example.
Thu Jul 12 18:03:02 2007  Tim Janik  <timj@gtk.org>

        * gdk/gdk.c (gdk_threads_add_idle_full): clarified documentation example.



svn path=/trunk/; revision=18458
2007-07-12 16:13:36 +00:00
Richard Hult
2048ec5925 Add hack to workaround the broken tracking rect implementation in quartz,
2007-07-10  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_new),
	(show_window_internal), (gdk_window_show), (gdk_window_hide): Add
	hack to workaround the broken tracking rect implementation in
	quartz, that doesn't seem to produce events if the window shows up
	under the mouse.

svn path=/trunk/; revision=18440
2007-07-10 19:18:59 +00:00
Tim Janik
2af3c53e47 docu fixup by Bjoern Lindqvist, #454703.
Sun Jul  8 01:33:45 2007  Tim Janik  <timj@gtk.org>

        * gdk/gdkwindow.c: docu fixup by Bjoern Lindqvist, #454703.



svn path=/trunk/; revision=18398
2007-07-07 23:36:33 +00:00
Richard Hult
8b9cbdb2b6 ]) ([GdkQuartzWindow -windowDidBecomeMain:]): Keep a stack of main windows
2007-07-07  Richard Hult  <richard@imendio.com>

	* gdk/quartz/GdkQuartzWindow.c ([GdkQuartzWindow -windowDidResignMain:]) 
	([GdkQuartzWindow -windowDidBecomeMain:]): 
	* gdk/quartz/gdkwindow-quartz.c (_gdk_quartz_window_did_resign_main)
	(_gdk_quartz_window_did_become_main, gdk_window_hide)
	(_gdk_windowing_window_destroy): Keep a stack of main windows and
	select the most recent one when hiding/closing the current one.

svn path=/trunk/; revision=18396
2007-07-07 16:19:40 +00:00
Richard Hult
5a4ed10fae Fix (de)miniaturizing transient windows, by (un)setting the parent before
2007-07-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkprivate-quartz.h:
	* gdk/quartz/gdkwindow-quartz.c:
	* gdk/quartz/GdkQuartzWindow.c: Fix (de)miniaturizing transient
	windows, by (un)setting the parent before and after miniaturizing.

svn path=/trunk/; revision=18388
2007-07-06 19:49:42 +00:00
Richard Hult
9ba84faa5a Add stub.
2007-07-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkkeys-quartz.c (gdk_keymap_have_bidi_layouts): Add
	stub.

svn path=/trunk/; revision=18387
2007-07-06 18:46:39 +00:00
Tim Janik
52c134e007 added usage example to gdk_event_request_motions() docs.
Wed Jul  4 12:20:23 2007  Tim Janik  <timj@imendio.com>

        * gdk/gdkevents.c (gdk_event_request_motions): added usage example
        to gdk_event_request_motions() docs.



svn path=/trunk/; revision=18378
2007-07-04 10:21:05 +00:00
Richard Hult
a07742849e Keep track of button state and include it in key events. Needed for gimp's
2007-07-03  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c: Keep track of button state and
	include it in key events. Needed for gimp's selection tools and
	fixes bug #453411.

svn path=/trunk/; revision=18369
2007-07-03 20:31:59 +00:00
Richard Hult
eb3dcdf094 Include modifier state in key release events. Fixes bug #453413.
2007-07-03  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (create_key_event): Include
	modifier state in key release events. Fixes bug #453413.

svn path=/trunk/; revision=18367
2007-07-03 18:49:09 +00:00
Tor Lillqvist
92421f96f6 Implement. Just return FALSE for now. What should this function actually
2007-07-03  Tor Lillqvist  <tml@novell.com>

	* gdk/win32/gdkkeys-win32.c (gdk_keymap_have_bidi_layouts):
	Implement. Just return FALSE for now. What should this function
	actually do? Does keyboards layouts being "in use" mean that such
	layouts can be switched to on the fly? If so we need to actually
	check that.


svn path=/trunk/; revision=18359
2007-07-03 16:53:17 +00:00
Richard Hult
460833b2bc Continue the event handling cleanup:
2007-06-30  Richard Hult  <richard@imendio.com>

	Continue the event handling cleanup:

	* gdk/quartz/gdkevents-quartz.c: (synthesize_crossing_events):
	Don't do anything if the old and new windows are the same,
	simplifies the callers.
	(find_mouse_window_for_ns_event): Always return a window (root
	instead of NULL). Remove unneccessary check for the current mouse
	window being NULL, that was a workaround for a now fixed
	bug. Convert to root coordinates if we don't find a window.
	(synthesize_crossing_events_for_ns_event): Simplify and add
	comment.

svn path=/trunk/; revision=18316
2007-06-30 21:50:06 +00:00
Richard Hult
ee283b058a Simplify (get the origin directly from the window).
2007-06-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c:
	(synthesize_crossing_events_for_ns_event): Simplify (get the
	origin directly from the window).

svn path=/trunk/; revision=18315
2007-06-30 19:55:20 +00:00
Richard Hult
a598c633b5 No need to special case the root window now that it has the right size.
2007-06-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c: (create_crossing_event),
	(synthesize_crossing_events), (find_mouse_window_for_ns_event),
	(synthesize_crossing_events_for_ns_event): No need to special case
	the root window now that it has the right size.

svn path=/trunk/; revision=18314
2007-06-30 19:50:31 +00:00
Richard Hult
95f61d98f3 Improve comments in those files. Add a debugging helper to print out
2007-06-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c:
	* gdk/quartz/gdkevents-quartz.c: Improve comments in those
	files. Add a debugging helper to print out information about a
	window.

svn path=/trunk/; revision=18313
2007-06-30 19:39:45 +00:00
Richard Hult
d793d416da Make this work properly for the root window.
2007-06-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_get_origin): Make
	this work properly for the root window.

svn path=/trunk/; revision=18311
2007-06-30 09:12:56 +00:00
Richard Hult
8fd51a225e Improve the tracking rect updating: - No need to override setFrame. - Use
2007-06-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/GdkQuartzView.c: Improve the tracking rect updating:
	- No need to override setFrame.
	- Use our own size instead of the bounds from for the view as it's
	not always updated before the tracking rect.
	- Only reset the tracking rect if the new window is nil).
	
	* gdk/quartz/GdkQuartzWindow.c: Update the bounds of the content
	view when the window size changes.

svn path=/trunk/; revision=18309
2007-06-30 08:56:50 +00:00
Matthias Clasen
436a34e318 New function to determine if keyboard layouts for both LTR and LTR
2007-06-29  Matthias Clasen  <mclasen@redhat.com>

        * gdk/gdk.symbols:
        * gdk/gdkkeys.h:
        * gdk/x11/gdkkeys-x11.c (gdk_keymap_have_bidi_layouts): New
        function to determine if keyboard layouts for both LTR and LTR
        languages are in use. Refactor the direction caching code to
        make this information available.  (#451575, Behnam Esfahbod)



svn path=/trunk/; revision=18301
2007-06-30 01:43:04 +00:00
Ryan Lortie
e8e5af2d8c Connect the "destroy" signal so that the 'window' pointer is set back to
2007-06-29  Ryan Lortie  <desrt@desrt.ca>

        * tests/testgtk.c (create_composited_window): Connect the "destroy" 
        signal so that the 'window' pointer is set back to NULL (like for the 
        other examples).

        * gdk/x11/gdkwindow-x11.c (gdk_window_impl_x11_finalize): Don't 
        destroy the Damage here.  By finalize() XDestroyWindow has already 
        been called (and took the Damage with it).

        Bug #452046.


svn path=/trunk/; revision=18290
2007-06-29 16:02:24 +00:00
Richard Hult
9d66399094 Don't steal menu events while the keyboard is grabbed.
2007-06-25  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (gdk_event_translate): Don't steal
	menu events while the keyboard is grabbed.

svn path=/trunk/; revision=18231
2007-06-25 19:54:04 +00:00
Richard Hult
b4e0b5339b Fallback to X cursors for the ones that OS X doesn't provide. Fixes bug
2007-06-25  Richard Hult  <richard@imendio.com>

	* gdk/quartz/Makefile.am:
	* gdk/quartz/xcursors.h:
	* gdk/quartz/gdkcursor-quartz.c: Fallback to X cursors for the
	ones that OS X doesn't provide. Fixes bug #327912.

svn path=/trunk/; revision=18229
2007-06-25 19:43:22 +00:00
Tor Lillqvist
1d5ef907b2 Revert my attempted overly simple fix for #445284, as it causes a
2007-06-25  Tor Lillqvist  <tml@novell.com>

	* gdk/win32/gdkevents-win32.c (gdk_pointer_grab): Revert my
	attempted overly simple fix for #445284, as it causes a
	regression. (For instance, in GIMP the tool cursor gets used also
	for the right-click menu in image windows.) A more complex fix is
	needed to more completely emulate X11 behaviour.


svn path=/trunk/; revision=18225
2007-06-25 06:38:58 +00:00
Tim Janik
e7525262bd applied patch from Mark Tiefenbruck to add missing return_if_fail,
Fri Jun 22 00:34:34 2007  Tim Janik  <timj@gtk.org>

        * gdk/x11/gdkdisplay-x11.c (gdk_x11_display_get_xdisplay): applied
        patch from Mark Tiefenbruck to add missing return_if_fail, #449862.



svn path=/trunk/; revision=18215
2007-06-21 22:37:21 +00:00
Johan Dahlin
f43329fcd6 Fix a typo in a comment
* gdk/quartz/GdkQuartzView.c ([GdkQuartzView -updateTrackingRect]): Fix a typo
    in a comment


svn path=/trunk/; revision=18199
2007-06-19 22:42:51 +00:00
Richard Hult
0932e4be38 Don't create or update the tracking rect in the window, move it to the
2007-06-20  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c (gdk_window_new): 
	* gdk/quartz/GdkQuartzWindow.c (windowDidResize): Don't create or
	update the tracking rect in the window, move it to the view where
	it belongs.

	* gdk/quartz/GdkQuartzView.c (updateTrackingRect)
	(viewDidMoveToWindow, viewWillMoveToWindow)
	(setFrame, setBounds): Create and update the tracking rect here.

svn path=/trunk/; revision=18197
2007-06-19 22:09:56 +00:00
Mathias Hasselmann
708dba5dc6 Restore G_BEGIN_DECLS at the top of this file to make C++ compilers happy.
2007-06-19  Mathias Hasselmann  <mathias.hasselmann@gmx.de>

	* gdk/gdkinternals.h: Restore G_BEGIN_DECLS at the
	top of this file to make C++ compilers happy.

svn path=/trunk/; revision=18196
2007-06-19 18:37:14 +00:00
Richard Hult
decff53495 Forward Mac OS menu shortcut events to the right menu.
2007-06-17  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (gdk_event_translate): Forward
	Mac OS menu shortcut events to the right menu.

svn path=/trunk/; revision=18178
2007-06-17 20:36:26 +00:00
Richard Hult
33ec37ee9e More refactoring of the event handling: Extract synthesizing of crossing
2007-06-17  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (gdk_event_translate)
	(synthesize_crossing_events_for_ns_event)
	(find_window_for_ns_event): More refactoring of the event
	handling: Extract synthesizing of crossing events from
	find_window_for_ns_event so that it doesn't have any side effects,
	and call the new function from gdk_event_translate instead.

svn path=/trunk/; revision=18176
2007-06-17 18:41:36 +00:00
Richard Hult
cd03a9e977 Remove pointless logging for unhandled events. Activate the application on
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c: (find_window_for_ns_event),
	(gdk_event_translate): Remove pointless logging for unhandled events.
	Activate the application on non-left clicks, since that is only done
	for left clicks and we depend on it to get events routed properly for
	context menus and other popup windows.

svn path=/trunk/; revision=18175
2007-06-17 14:29:21 +00:00
Xan Lopez
9a0af6de47 replace GDK_WINDOW calls by cast to GdkWindow. Patch by Tilman Sauerbeck
2007-06-17  Xan Lopez  <xan@gnome.org>

	* gdk/x11/gdkgeometry-x11.c: replace GDK_WINDOW calls by cast to
	GdkWindow. Patch by Tilman Sauerbeck from #2063820.

svn path=/trunk/; revision=18170
2007-06-17 11:24:25 +00:00
Richard Hult
e206f6dd3a Ignore events and break any grabs while the window is being dragged.
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c: (gdk_event_translate): Ignore
	events and break any grabs while the window is being dragged.

svn path=/trunk/; revision=18165
2007-06-16 21:39:42 +00:00
Richard Hult
526fecc2f9 Defer setting the parent until the window is shown, otherwise it gets
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_set_transient_for):
	Defer setting the parent until the window is shown, otherwise it
	gets unconditionally shown here.

svn path=/trunk/; revision=18164
2007-06-16 21:21:52 +00:00
Richard Hult
2902d87a22 Move the checks for no window or a non-GDK window from here...
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (find_mouse_window_for_ns_event):
	Move the checks for no window or a non-GDK window from here...
	(gdk_event_translate): ...to here. Reorder the code so that we
	detect the cases where we need to break grabs before bailing
	out.

svn path=/trunk/; revision=18161
2007-06-16 16:16:43 +00:00
Richard Hult
4fd1fb4d9b Break out into a separate function.
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (gdk_event_translate) 
	(break_all_grabs): Break out into a separate function.

svn path=/trunk/; revision=18160
2007-06-16 15:43:23 +00:00
Richard Hult
48a45ff672 Implement, to be used to detect if the window is currently being moved
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/GdkQuartzWindow.c: (isInMove): Implement, to be used
	to detect if the window is currently being moved with the mouse.

svn path=/trunk/; revision=18159
2007-06-16 15:41:27 +00:00
Richard Hult
f55096fc74 Don't set parent/child relationship for tooltip windows since that moves
2007-06-16  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c (gdk_window_set_transient_for):
	Don't set parent/child relationship for tooltip windows since that
	moves the parent window to the front, due to the tooltip having a
	high window level.

svn path=/trunk/; revision=18158
2007-06-16 15:38:33 +00:00
Hans Breuer
49fc7e15ee updated explicit usage of RegisterClassExW to match the WNDCLASSEXW. True
2007-06-15  Hans Breuer <hans@breuer.org>

	* gtk/makefile.msc.in tests/makefile.msc : updated
	* gdk/win32/gdkwindow-win32.c : explicit usage of RegisterClassExW
	to match the WNDCLASSEXW. 
	True dynamic linking of SetLayeredWindowAttributes
	* tests/testprint.c tests/testnouiprint.c : use G_PI


svn path=/trunk/; revision=18140
2007-06-15 15:25:50 +00:00
Tor Lillqvist
eb1876f305 Use g_win32_get_windows_version() instead of _winver so that this compiles
2007-06-14  Tor Lillqvist  <tml@novell.com>

	* gdk/win32/gdkwindow-win32.c (RegisterGdkClass): Use
	g_win32_get_windows_version() instead of _winver so that this
	compiles on Cygwin, too. Not that I know if it makes sense to
	build GTK+ with the Win32 backend for Cygwin, but some people want
	to.


svn path=/trunk/; revision=18132
2007-06-14 09:41:08 +00:00
Behdad Esfahbod
e7ad5239a5 #undef GDK_DISABLE_DEPRECATED to get prototype for gdk_font_ref().
2007-06-13  Behdad Esfahbod  <behdad@gnome.org>

        * gdk/directfb/gdkgc-directfb.c: #undef GDK_DISABLE_DEPRECATED to
        get prototype for gdk_font_ref(). (#447163, Dann Frazier, Loïc Minier)


svn path=/trunk/; revision=18126
2007-06-13 21:24:21 +00:00
Matthias Clasen
f7add802e2 Remove linux-fb leftovers
svn path=/trunk/; revision=18113
2007-06-13 02:07:15 +00:00
Behdad Esfahbod
1adaeba11f Improve docs. (#446138, Björn Lindqvist)
2007-06-12  Behdad Esfahbod  <behdad@gnome.org>

        * gdk/gdkwindow.c (gdk_window_get_pointer): Improve docs.
        (#446138, Björn Lindqvist)


svn path=/trunk/; revision=18109
2007-06-12 05:34:26 +00:00
Matthias Clasen
9b8d335ade Handle child_setup being NULL. (#445691, Christopher Taylor)
2007-06-10  Matthias Clasen  <mclasen@redhat.com>

        * gdk/x11/gdkspawn-x11.c (set_environment): Handle child_setup
        being NULL.  (#445691, Christopher Taylor)



svn path=/trunk/; revision=18097
2007-06-11 00:18:51 +00:00
Michael Natterer
f7ba83c613 fix angles by flipping the coordinate system back to its original y
2007-06-10  Michael Natterer  <mitch@imendio.com>

	* gdk/quartz/gdkdrawable-quartz.c (gdk_quartz_draw_arc): fix
	angles by flipping the coordinate system back to its original y
	direction. The implementtion is still broken for ellipses, will
	have to simulate them using bezier curves.


svn path=/trunk/; revision=18095
2007-06-10 16:29:31 +00:00
Cody Russell
83d5a36c9f Don't revert the mouse cursor to the built-in one when the user holds the
2007-06-10  Cody Russell  <bratsche@gnome.org>

        * gdk/win32/gdkevents-win32.c (gdk_pointer_grab):
        Don't revert the mouse cursor to the built-in one when
        the user holds the mouse button down. (#445284, Tor Lillqvist)


svn path=/trunk/; revision=18093
2007-06-10 16:13:09 +00:00
Michael Natterer
6c3637ea3e add utility function gdk_quartz_fix_cap_not_last_line() which fixes the
2007-06-08  Michael Natterer  <mitch@imendio.com>

	* gdk/quartz/gdkdrawable-quartz.c: add utility function
	gdk_quartz_fix_cap_not_last_line() which fixes the coordinates for
	GDK_CAP_NOT_LAST lines at least for horizontal and vertical lines.

	(gdk_quartz_draw_segments)
	(gdk_quartz_draw_lines): use it here.


svn path=/trunk/; revision=18080
2007-06-07 22:26:27 +00:00
Michael Natterer
dde0d5ffa5 add gdk_gc_quartz_init() and set some values to the defaults used by X11.
2007-06-07  Michael Natterer  <mitch@imendio.com>

	* gdk/quartz/gdkgc-quartz.c: add gdk_gc_quartz_init() and set
	some values to the defaults used by X11.

	(gdk_quartz_gc_set_values): really set cap_style when
	GDK_GC_CAP_STYLE is in the mask, not line_style.


svn path=/trunk/; revision=18079
2007-06-07 21:22:15 +00:00
Michael Natterer
88a05af64f use the same code for GDK_XOR as for GDK_INVERT. Xor with an arbitrary
2007-06-07  Michael Natterer  <mitch@imendio.com>

	* gdk/quartz/gdkgc-quartz.c (_gdk_quartz_gc_update_cg_context):
	use the same code for GDK_XOR as for GDK_INVERT. Xor with an
	arbitrary color is impossible to implement with quartz.


svn path=/trunk/; revision=18077
2007-06-07 18:25:15 +00:00
Matthias Clasen
498dac7ed2 Fix a doc formatting thing
svn path=/trunk/; revision=18071
2007-06-07 04:28:56 +00:00
Richard Hult
ec32b2aaa3 Rework how we get the event window: don't get the window from the NSEvent,
2007-06-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (find_mouse_window_for_ns_event)
	(find_window_for_ns_event): Rework how we get the event window:
	don't get the window from the NSEvent, always use the mouse window
	instead. Fix mouse window tracking by only using MouseExited for
	non-gdk windows, and to always use the NSEvent window to get the
	right gdk window in MouseEntered. Add comments to the code. Fixes bug
	#350460.

svn path=/trunk/; revision=18065
2007-06-06 18:42:07 +00:00
Richard Hult
ed8d0fc691 Don't do anything if the two windows are the same.
2007-06-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (get_converted_window_coordinates):
	Don't do anything if the two windows are the same.
	(find_window_for_ns_event): Translate coordinates to be relative
	the grab window when appropriate.

svn path=/trunk/; revision=18064
2007-06-06 16:23:50 +00:00
Ross Burton
58d99db469 Set DISPLAY in the child process using g_setenv() instead of constructing
2007-06-06  Ross Burton  <ross@openedhand.com>

	* gdk/x11/gdkspawn-x11.c:
	Set DISPLAY in the child process using g_setenv() instead of
	constructing a new envp, which lets callers use child setup
	functions which call putenv (#442617).

svn path=/trunk/; revision=18062
2007-06-06 15:57:58 +00:00
Matthias Clasen
50fca8df5e Fix the build
svn path=/trunk/; revision=18055
2007-06-06 13:05:34 +00:00
Brian Cameron
b67d9a7dd0 Add gdkmedialib.h to EXTRA_DIST so this header file gets included with the
2007-06-06  Brian Cameron  <brian.cameron@sun.com>

        * gdk/Makefile.am: Add gdkmedialib.h to EXTRA_DIST so this header
          file gets included with the distribution, as needed.  Fixes bug
          #442888.  Reviewed by Matthias Clasen.

svn path=/trunk/; revision=18050
2007-06-06 10:15:23 +00:00
Richard Hult
726c23e20f Ignore if the old and new windows are the same.
2007-06-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c
	(_gdk_quartz_events_update_mouse_window): Ignore if the old and new
	windows are the same.

svn path=/trunk/; revision=18049
2007-06-06 09:06:59 +00:00
Richard Hult
fb6a0314fd Update comment to be more clear and print a warning if we try to create a
2007-06-06  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (synthesize_crossing_events):
	Update comment to be more clear and print a warning if we try to
	create a crossing event without knowing what the current mouse
	window is, to help track down focus bugs.

	* gdk/quartz/gdkevents-quartz.c
	(_gdk_quartz_events_update_focus_window): Fix indentation.

svn path=/trunk/; revision=18047
2007-06-06 08:29:20 +00:00
Richard Hult
949a86729d Don't let temp windows become key window.
2007-06-05  Richard Hult  <richard@imendio.com>

	* gdk/quartz/GdkQuartzWindow.c: Don't let temp windows become key
	window.

svn path=/trunk/; revision=18046
2007-06-06 08:21:14 +00:00
Tor Lillqvist
c62db99be2 Fix embarrassing crash. (#444457, Torsten Schoenfeld)
2007-06-06  Tor Lillqvist  <tml@novell.com>

	* gdk/x11/gdkwindow-x11.c (gdk_window_set_opacity): Fix
	embarrassing crash. (#444457, Torsten Schoenfeld)


svn path=/trunk/; revision=18045
2007-06-06 00:03:25 +00:00
Matthias Clasen
3047c1fcf2 Check that window_private is not NULL before using it. (#444351, David
2007-06-05  Matthias Clasen <mclasen@redhat.com>

        * gdk/x11/gdkevents-x11.c (gdk_event_translate): Check that
        window_private is not NULL before using it.  (#444351, David Ronis)



svn path=/trunk/; revision=18043
2007-06-05 15:53:41 +00:00
Richard Hult
3337ee8fa2 Don't try to make temp windows key windows, fixes problem introduced
2007-06-04  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c:
	(show_window_internal): Don't try to make temp windows key
	windows, fixes problem introduced below.

svn path=/trunk/; revision=18040
2007-06-04 21:25:42 +00:00
Richard Hult
72469142a0 * gdk/quartz/gdkwindow-quartz.c: Implement simple versions of
2007-06-04  Richard Hult  <richard@imendio.com>

	* gdk/quartz/GdkQuartzWindow.c: * gdk/quartz/gdkwindow-quartz.c:
	Implement simple versions of gdk_window_set_accept_focus and
	gdk_window_set_focus_on_map.

svn path=/trunk/; revision=18038
2007-06-04 20:45:30 +00:00
Richard Hult
60be3caaaa Implement.
2007-06-04  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c: (gdk_window_raise),
	(gdk_window_raise): Implement.

svn path=/trunk/; revision=18037
2007-06-04 20:08:31 +00:00
Richard Hult
05e560661f Implement gdk_window_set_transient_for.
2007-06-04  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkwindow-quartz.c:
	* gdk/quartz/gdkwindow-quartz.h: Implement 
	gdk_window_set_transient_for.

svn path=/trunk/; revision=18036
2007-06-04 20:02:58 +00:00
Matthias Clasen
0f4d0f8e62 2.11.1
svn path=/trunk/; revision=18027
2007-06-04 17:01:14 +00:00
Richard Hult
9daa2554b5 Set the key modifier state.
2007-06-03  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c: (create_crossing_event): Set the key
	modifier state.

svn path=/trunk/; revision=18017
2007-06-03 18:51:16 +00:00
Richard Hult
975e7683b8 Make pointer grab emulation work a bit better:
2007-06-03  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c: Make pointer grab emulation work a bit
	better:
	(gdk_display_pointer_is_grabbed): Do what the docs say and don't
	consider implicit grabs here.
	(gdk_pointer_grab): Overriding a grab by the same app should always be
	succesful.
	(gdk_event_translate): Implicit grabs should not be owner events.

svn path=/trunk/; revision=18016
2007-06-03 18:48:47 +00:00
Richard Hult
1c413a691c Fix the coordinates in crossing events so they are relative to the right
2007-06-01  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c:
	(get_converted_window_coordinates), (create_crossing_event): Fix the
	coordinates in crossing events so they are relative to the right
	window.

svn path=/trunk/; revision=18007
2007-06-01 21:46:45 +00:00
Richard Hult
be540c29ac Make function naming consistent for the various functions that retrieve
2007-06-01  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.[ch]: Make function naming
	consistent for the various functions that retrieve data from an
	event.

	* gdk/quartz/gdkprivate-quartz.h: 
	* gdk/quartz/gdkwindow-quartz.[ch]: Remove the now unused
	_gdk_quartz_window_find_child_by_point() function.

svn path=/trunk/; revision=18006
2007-06-01 21:03:34 +00:00
Matthias Clasen
885ba04648 Add support for composited child windows. (#412882, Ryan Lortie)
2007-06-01  Matthias Clasen  <mclasen@redhat.com>

        Add support for composited child windows.  (#412882, Ryan Lortie)

        * gdk/gdk.symbols:
        * gdk/gdkdisplay.h:
        * gdk/gdkinternals.h:
        * gdk/gdkwindow.[hc]: Add gdk_display_supports_composite() and
        gdk_window_set_composited().

        * gdk/x11/gdkevents-x11.c:
        * gdk/x11/gdkdisplay-x11.[hc]:
        * gdk/x11/gdkwindow-x11.[hc]: X11 implementation.

        * gdk/win32/gdkdisplay-win32.c:
        * gdk/win32/gdkwindow-win32.c: Dummy win32 implementration.

        * gdk/quartz/gdkdisplay-quartz.c:
        * gdk/quartz/gdkwindow-quartz.c: Dummy Quartz implementation.

        * gdk/directfb/gdkdisplay-directfb.c:
        * gdk/directfb/gdkwindow-directfb.c: Dummy DirectFB implementation.

        * tests/testgtk.c: Add a "composited window" test.


svn path=/trunk/; revision=18004
2007-06-01 12:16:12 +00:00
Alp Toker
5ffdc33df0 Fix doc typos.
2007-06-01  Alp Toker  <alp.toker@collabora.co.uk>

	* gdk/gdkcairo.c (gdk_cairo_set_source_pixmap): Fix doc typos.


svn path=/trunk/; revision=17999
2007-06-01 05:10:50 +00:00
Richard Hult
71cf54aef3 Add this function, bug #438440.
2007-05-30  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkselection-quartz.c (gdk_free_text_list): Add this
	function, bug #438440.

svn path=/trunk/; revision=17991
2007-05-30 17:20:26 +00:00
Tor Lillqvist
d022f4c32d Subtract the multi-monitor offset from x and y before setting up the
2007-05-30  Tor Lillqvist  <tml@novell.com>

	* gdk/win32/gdkevents-win32.c (gdk_pointer_grab): Subtract the
	multi-monitor offset from x and y before setting up the rectangle
	for ClipCursor(). Fixes #442326.


svn path=/trunk/; revision=17988
2007-05-30 15:44:28 +00:00
Simos Xenitellis
f2f53a6955 Closed #442183 – Updated gdk/gdkkeysyms-update.pl
svn path=/trunk/; revision=17984
2007-05-30 13:23:40 +00:00
Cody Russell
b5fe5d5bea Fix initialization of last cursor
svn path=/trunk/; revision=17973
2007-05-29 01:04:59 +00:00
Richard Hult
f2f1be4e4f Break out code that was repeated into separate functions and call them
2007-05-28  Richard Hult  <richard@imendio.com>

	* gdk/quartz/gdkevents-quartz.c (get_child_coordinates_from_ancestor)
	(get_ancestor_coordinates_from_child): Break out code that was
	repeated into separate functions and call them instead.
	(find_window_for_mouse_nsevent): Break out this from
	find_window_for_nsevent to make the code clearer.
	(find_window_for_nsevent): Use the above and fix the returned
	coordinates in the process so that they are always relative the
	found window, both for the normal case and during grabs. Still
	needs fixing for the case where we get nsevents for a window other
	than than grab window during grabs.

svn path=/trunk/; revision=17971
2007-05-28 21:11:55 +00:00