Commit Graph

3294 Commits

Author SHA1 Message Date
Lionel Landwerlin
30a52271e5 directfb: implement draw_drawable_with_src instead of draw_drawable in GdkDrawableImplDirectFB
This is required by the rotated button test in gtk-demo

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
b7b9a01efb TOFINISH: fixes on clear/scrolling
Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
4509240d0e directfb: fix gdk_directfb_child_at
When GDK looks for the window under pointer, the gdk-directfb backend
looks at windows starting from the root window to the upper window in
the stack. For this, it looks at window's size and position. This
patch fix the assumption that windows are always natives windows from
which we can retrieve backend's private data.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
65f7b09b39 directfb: fix GdkPixmap creation
Since GDK has introduced the offscreen window concept, pixmap can be
created using drawables which aren't native windows. This patch fix
this assumption.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
8e958f58c9 directfb: remove useless cairo_surface cleanup
This is done by gdk_directfb_cairo_surface_destroy via cairo_surface_set_user_data.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
333d53b342 directfb: remove useless code manipulating window's private data
The window management code used to deal with gdk internals. It seems a
lot of code has been pushed to the generic gdk code, so we remove
useless code.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
737f035959 directfb: rework backend initialization a little bit
Make it look more like the x11 backend. Also some people reported
crash early in the backend initialization about some colormap stuff,
this should avoid the problem.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
2970d775ed directfb: get rid of useless gdkWindow reference in GdkWindowImplDirectFB
Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
5538315d38 directfb: event manager rewrite
The event translation code used to deal a lot with gdk internals. It
seems a lot of code has been pushed to the generic gdk code, so we
needed to rewrite the things a little bit.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
ecb7734660 directfb: split gdk_directfb_event_make function
In prevision of coming event manager rewrite.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
9de2f4b9cc directfb: get rid of abs_x,abs_y computation within the backend
The computation of abs_x,abs_y is done by the generic code of GDK when
events are raised. We don't care about that anymore.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:21 +02:00
Lionel Landwerlin
68ba791720 directfb: use boilerplate macros for GdkWindow
This patch reduce boilerplate for GdkWindowImplDirectFB using G_DEFINE_TYPE macro.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Lionel Landwerlin
4e9be0c9e9 directfb: use boilerplate macros for GdkPixmap
This patch reduce boilerplate for GdkPixmapImplDirectFB using G_DEFINE_TYPE macro.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Lionel Landwerlin
000b2fa22b directfb: use boilerplate macros for GdkImage
This patch reduce boilerplate for GdkImage using G_DEFINE_TYPE macro.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Lionel Landwerlin
59d6e84459 directfb: drop cairo < 1.6 dependency
This removes the cairo's versions checks < 1.6 since GTK+ now requires
cairo >= 1.6.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Lionel Landwerlin
f8d42326ea directfb: coding style coherency
Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Lionel Landwerlin
3c3aa2778b directfb: add missing symbols for gdk input 2.22
Also make it look more like the x11 backend.

Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Lionel Landwerlin
8637b3eb37 directfb: drop internal reference to gdk-pixbuf
Signed-off-by: Lionel Landwerlin <llandwerlin@gmail.com>
2010-08-31 21:08:20 +02:00
Matthias Clasen
4e2ade8d6b Make gdk_keymap_map_virtual_modifiers work early
It needs to ensure that we have an uptodate modmap. Bug 616401
(cherry picked from commit d5a8a3c9bc)
2010-08-30 12:52:40 -04:00
Philip Withnall
818ef9aaf6 Miscellaneous string fixes
Mostly capitalisation fixes. Closes: bgo#528257
2010-08-29 19:05:26 +01:00
Fridrich Štrba
895b9ff43f A proper fix for win32 build 2010-08-29 18:16:58 +02:00
Fridrich Štrba
af44019baf Revert "Fix windows build of the branch"
This reverts commit c7e650ae5d.
2010-08-29 18:16:19 +02:00
Hans Breuer
17269e6c1d win32: Fix a bunch of c99isms
With c89 (which msvc implements) variables still need to be
declared at the beginning of a block.
2010-08-29 14:31:06 +02:00
Hans Breuer
707f1a9a84 win32: Further fixing _gdk_window_impl_new()
- attributes->wclass is not consistently set anymore,
   use private->input_only instead [1]
 - don't put window into parent->children a second time
   (now there is no window reference problem anymore)
2010-08-29 14:22:08 +02:00
Fridrich Štrba
c7e650ae5d Fix windows build of the branch 2010-08-28 18:50:45 +02:00
Martin Schlemmer
770e308c42 win32: cummulated backport of xp theme fixes from master 2010-08-28 15:14:31 +02:00
Hans Breuer
e339d36a02 win32: Resurrect some enter/leave notify events for native windows
The button highlighting in testgtk works again, even with
GDK_NATIVE_WINDOWS. Unfortunately testgtk:menus still does
not work for the forced-native-window-case.
2010-08-27 21:29:33 +02:00
Hans Breuer
068515ad96 Further fix _gdk_window_impl_new() for win32 and ...
Beside fixing _gdk_window_impl_new() as adviced in
http://mail.gnome.org/archives/gtk-devel-list/2010-August/msg00214.html
the patch adds implementations for set_background, set_back_pixmap,
restack_under, restack_toplevel and clear_region methods.
2010-08-27 21:23:59 +02:00
Neil Roberts
2e08524481 win32: Never pass SWP_NOSIZE or SWP_NOMOVE to SetWindowPos
In _gdk_window_move_resize_child it tries to decide whether to pass
SWP_NOSIZE and SWP_NOMOVE based on whether the new size and position
is different from the window's existing position. However it seems
that GDK now ends up updating the window's position before calling
_gdk_window_move_resize_child so this would mean it would think the
window never changes size or position so SWP_NOSIZE|SWP_NOMOVE would
always be set. This causes child windows to never be resized.

This patch changes it so that it never passes either flag to
SetWindowPos. I don't know whether this will cause any side effects
but you'd think it shouldn't do any harm to reassert the current size.

https://bugzilla.gnome.org/show_bug.cgi?id=628049

Signed-off-by: Hans Breuer <hans@breuer.org>
2010-08-27 20:38:01 +02:00
Hans Breuer
0e781823cb Update mscv/win32 build
Fix makefiles for separated gdk-pixbuf and declare variable at
the beginning of a block (fix c99ism).
2010-08-27 20:34:23 +02:00
Matthias Clasen
1d5a6e790a Fix up some documentation issues 2010-08-16 17:38:23 -04:00
Benjamin Otte
9f1cb0798b API: Add gdk_window_get_background_pattern()
This is the suggested way for GTK3 to store a Window's background so it
makes sense to use the same function today already.
2010-08-16 20:01:49 +02:00
Kristian Rietveld
77b703c2fc quartz: stop offscreen windows code from crashing.
This is an adapted version of commit
bde0f9a8f6 on master.

Mainly fixes to properly differentiate bewteen toplevel and offscreen
windows, since these sometimes need different treatment.  Furthermore,
usage of gdk_window_get_effective_foo() instead of gdk_window_get_foo()
where applicable.

There is an drawing issue left when scrolling e.g. tree views in
offscreen windows.  I think this is likely an issue with
gdk_quartz_draw_drawable() which is used for the copy area code in
offscreen windows.  It works fine in master, since this was converted
to Cairo.
2010-08-15 17:34:33 +02:00
Benjamin Otte
370dfc16ca Remove window background getters again
They were added as accessors for 2.22 even though querying the
background wasn't possible previously. As GTK 3.0 will change background
handling, it doesn't make sense at all to expose these getters.
2010-08-15 03:31:37 +02:00
Benjamin Otte
997d3aada6 API: Add gdk_window_create_similar_surface() 2010-08-12 23:30:19 +02:00
Benjamin Otte
0e183fe745 pixmap: Deprecate create_from_data() constructors
And document that GdkPixmap will go away in GTK 3.
2010-08-12 03:02:38 +02:00
Benjamin Otte
cedf52fb81 x11: Deprecate GdkGC functions
They are gone in GTK3, just like the rest of GdkGC.
2010-08-12 01:54:58 +02:00
Benjamin Otte
e8915ae422 gdk: Undeprecate gdk_region_xor()
cairo_region_xor() does now exist, so there's no need to deprecate this
function.
2010-08-10 18:26:12 +02:00
Benjamin Otte
bff0d11c4d gdk: Deprecate GdkRGB functions 2010-08-08 02:59:21 +02:00
Benjamin Otte
a907d5e2cc Deprecate all of GdkImage 2010-08-07 22:17:43 +02:00
Benjamin Otte
8a2a736af4 Deprecated all GdkGC functions 2010-08-07 22:08:21 +02:00
Benjamin Otte
3d506df234 gdk: Deprecate all drawing functions
These functions will be gone in Gtk 3.0 and be replaced by Cairo
functions.

Includes not disabling deprecated functions in old widgets that aren't
going to be ported.
2010-08-07 15:35:51 +02:00
Benjamin Otte
f36bb4d91d gdk: Simplify deprecation guards in gdkdrawable.h 2010-08-07 15:35:49 +02:00
John Stowers
32c4f471d5 Add gdk_display_is_closed
https://bugzilla.gnome.org/show_bug.cgi?id=624224
2010-08-07 23:11:42 +12:00
Tomeu Vizoso
23f7d3a0ea Annotate gdk_rectangle_intersect 2010-07-28 16:53:14 +02:00
Tomeu Vizoso
fd75ced492 Generate GdkX11-2.0.typelib (backported from HEAD)
https://bugzilla.gnome.org/show_bug.cgi?id=625491
2010-07-28 15:03:28 +02:00
Benjamin Otte
01fea4032f gdk: Revert making get_size optional
49a0ec6e95 added this hunk without
explanations and it's obviously wrong because failing to have a get_size
vfunc will now not set width and height and they'll end up with invalid
values.

In fact, the GdkDrawableImpl{X11,Win32,Quartz} functions do not have
get_size implemented, so the patch was most likely an attempt to work
around calling this function erroneously on the impl objects.

The correct fix is to call impl->wrapper instead.
2010-07-26 11:58:23 +02:00
Benjamin Otte
e1c7ff8ee0 x11: Query size on real drawable
The X11 drawable does not have a clue about the real size of the
surface.

This might also be the cause for:
https://bugzilla.gnome.org/show_bug.cgi?id=599574
2010-07-26 11:58:23 +02:00
Emmanuele Bassi
7a68f42d2e Do not return values from a function returning void 2010-07-26 11:58:23 +02:00
John Stowers
dc2fea413b Add gdk_device_get_n_axes
https://bugzilla.gnome.org/show_bug.cgi?id=624221
2010-07-25 12:32:43 +12:00