Commit Graph

7152 Commits

Author SHA1 Message Date
Matthias Clasen
42a5608af6 Fix the build
Copy-paste error.
2016-10-26 10:45:04 -04:00
Matthias Clasen
9aa1257bd0 GdkWindow: Use the seat to enumerate devices
GdkDeviceManager is going away.
2016-10-26 10:36:32 -04:00
Matthias Clasen
7fa09a3e3a quartz: Stop using gdk_device_manager_list_devices
The function has been deprecated.
2016-10-26 10:36:32 -04:00
Matthias Clasen
35fda80a4b x11: Stop using gdk_device_manager_list_devices
The function has been deprecated.
2016-10-26 10:36:32 -04:00
Matthias Clasen
d2d209865b broadway: Stop using gdk_device_manager_list_devices
The function is deprecated.
2016-10-26 10:36:32 -04:00
Alexander Larsson
723b588b5d Make gdk.la and gsk.la a noninst helper library
This merged gtk, gdk and gsk into one library, making it possible to
have internal private APIs between gtk them, as well as producing more
efficient code.

https://bugzilla.gnome.org/show_bug.cgi?id=773100
2016-10-26 16:34:15 +02:00
Chun-wei Fan
4b3c0314dd gdk/win32/gdkevents-win32.c: Avoid gdk_device_manager_get_core_pointer()
This function has been removed, so replace it with gdk_seat_get_pointer().

https://bugzilla.gnome.org/show_bug.cgi?id=773299
2016-10-26 18:54:51 +08:00
Chun-wei Fan
2ba64e0b62 MSVC builds: Support MSVC 2013 and later
We now need C99 features from the compiler which are only supported by
Visual Studio 2013 and later, so drop the MSVC 2008~2012 projects, and make
the baseline supported Visual Studio version be 2013.  Update the build files
as a result.
2016-10-26 16:46:38 +08:00
Rico Tzschichholz
b4c37bfff8 visual: Remove deprecated API 2016-10-26 10:12:58 +02:00
Rico Tzschichholz
e0b1f2e5f4 Remove deprecated gdk_display_open_default_libgtk_only 2016-10-26 10:06:23 +02:00
Matthias Clasen
cbe1337aa1 Revert "Remove gdk_device_grab/ungrab from the API"
This reverts commit efc37d0855.

Turns out we need to clean up the dnd code some more, first.
2016-10-25 21:24:37 -04:00
Matthias Clasen
f350e346e4 Drop the deprecated gdk_device_manager_get_client_pointer 2016-10-25 21:06:25 -04:00
Matthias Clasen
efc37d0855 Remove gdk_device_grab/ungrab from the API
These are still used in a few places internally,
so make them private.
2016-10-25 20:03:34 -04:00
Matthias Clasen
5e4a05e5b7 Remove deprecated gdk_window_get_pointer 2016-10-25 19:45:48 -04:00
Matthias Clasen
1396d6c92a Remove some more deprecated display API
gdk_display_get_pointer, gdk_display_get_window_at_pointer and
gdk_display_warp_pointer have long been deprecated.
2016-10-25 19:31:24 -04:00
Matthias Clasen
ee7ddefce9 Remove deprecated gdk_display_list_devices 2016-10-25 16:04:01 -04:00
Matthias Clasen
dcda9c3d8c Remove deprecated GDK_DISPLAY_OBJECT macro 2016-10-25 16:02:07 -04:00
Matthias Clasen
e041345fcb Remove the last uses of GDK_DISPLAY_OBJECT
This is an obsolete macro.
2016-10-25 16:01:50 -04:00
Matthias Clasen
e642909823 Remove deprecated display ungrab functions 2016-10-25 15:56:52 -04:00
Matthias Clasen
6b231af45e Remove deprecated gdk_app_launch_context_set_display 2016-10-25 15:52:57 -04:00
Matthias Clasen
5cb3fc4c4f Drop deprecated gdk_display_get_screen 2016-10-25 15:35:44 -04:00
Matthias Clasen
0ba67021a9 Remove an unused function
This function is no longer used, now that offscreen windows are gone.
2016-10-25 15:32:02 -04:00
Matthias Clasen
4f1e06380c Remove deprecated gdk_app_launch_context_new 2016-10-25 15:27:42 -04:00
Matthias Clasen
78d0876c46 Remove deprecated gdk_display_get_n_screens 2016-10-25 15:21:46 -04:00
Alexander Larsson
70935f0952 Drop support for offscreen GdkWindows
These complicate a lot of GdkWindow internals to implement features
that not a lot of apps use, and will be better achieved using gsk.
So, we just drop it all.
2016-10-25 09:54:37 +02:00
Rico Tzschichholz
639898000e gdkwindow: Remove deprecated API 2016-10-24 12:22:32 +02:00
Rico Tzschichholz
7630c86468 gdk: Remove deprecated gdk_cairo_set_source_color 2016-10-24 10:36:55 +02:00
Rico Tzschichholz
e528819d00 gdk: Remove deprecated gdk_add_option_entries_libgtk_only and gdk_pre_parse_libgtk_only 2016-10-24 10:33:51 +02:00
Rico Tzschichholz
b19fe8f4e0 gdk: Remove deprecated gdk_threads_set_lock_functions 2016-10-24 10:33:17 +02:00
Rico Tzschichholz
b12e3b5cf2 gdk: Remove deprecated gdk_get_display 2016-10-24 10:33:17 +02:00
Rico Tzschichholz
16ded8d47b gdk: Remove deprecated {keyboard,pointer}_{grab,ungrab} API 2016-10-24 10:33:11 +02:00
Rico Tzschichholz
02d500ac70 cursor: Remove deprecated API 2016-10-24 09:18:53 +02:00
Emmanuele Bassi
8e85f55240 gl: Check whether use_es is positive
Now that the use_es field is an int with a possible negative value, we
cannot use it its truth value directly; we need to check if it's a
positive value, instead.
2016-10-22 02:40:08 +01:00
Emmanuele Bassi
31c05771e9 gl: Set legacy bit depending on OpenGL version
GDK defaults to asking for an OpenGL 3.2 Core Profile, but if we get a
legacy profile from the underlying windowing system, the OpenGL version
will be fixed to 3.0. If that happens, we need to set the legacy bit on
the GdkGLContext, since that bit will be used to determine the version
and type of GLSL shaders that will be used by application and toolkit
code alike.
2016-10-22 02:40:08 +01:00
Emmanuele Bassi
b878ec7f2f gdk/gl: Allow autodetection for GL/GLES
If the GdkGLContext was not explicitly instructed to use or not GLES, we
can detect whether the underlying API is going to be desktop GL or GLES.

https://bugzilla.gnome.org/show_bug.cgi?id=773180
2016-10-21 11:39:24 -04:00
Adam Jackson
627867863f gdk: Don't second-guess whether a context is GLES
We've already set ->use_es correctly at context creation time, all this
can possibly do is change our mind about what kind of GL we're using.

Signed-off-by: Adam Jackson <ajax@redhat.com>

https://bugzilla.gnome.org/show_bug.cgi?id=773180
2016-10-21 11:39:24 -04:00
Chun-wei Fan
5140bc97b3 gdkwindow-win32.c: Make code compatible with GDK 4.0 APIs
Port the code here so that things will continue to build and work on 4.x.

https://bugzilla.gnome.org/show_bug.cgi?id=773299
2016-10-21 16:21:32 +08:00
Carlos Garnacho
31db11dd5b wayland: Allow grabless xdg_popups
xdg_shell v6 allows grabless popups, whose behavior is not that
different from override redirect windows with no grab to take
keyboard input (and pointer events outside).

This means we can relax the requirement to have a grab before
creating an xdg_popup. The warning is still useful to have so
people stop relying on gdk_window_show();gdk_device_grab() being
an ok pattern to popup a window, it's been moved to wayland
implementation of gdk_device_grab() instead, so we warn if trying
to grab a GDK_WINDOW_TEMP window that's already visible.

https://bugzilla.gnome.org/show_bug.cgi?id=771694
2016-10-20 11:41:59 +02:00
Chun-wei Fan
8b8f378050 Visual Studio builds: Update from [gdk|gtk]-3 to [gdk|gtk]-4
This updates all the projects files to be be named appropriately as we move from GTK-3.x to 4.x,
and updates the autotools files so that things are distributed and generated properly.

Also remove deprecated/gtkstatusicon-quartz.c from gtk/Makefile.am, as that was causing 'make dist'
to fail as that file has been removed.

This fixes 'make dist' with the updated existing project files in proper order.

Note that this does not include the new GSK, which will be added later, so the project files do
not yet build the whole stack on Visual Studio at this point.
2016-10-19 18:39:36 +08:00
Rico Tzschichholz
6fb8f61124 gdk: Fix Since tag of gdk_cairo_surface_upload_to_gl 2016-10-18 13:38:08 +02:00
Rico Tzschichholz
310a1f7e90 gdk: Add missing Since tags for gdk_window_new_child/input
In addition to d22e5e69d9
2016-10-18 13:27:19 +02:00
Alexander Larsson
1c7c77bc94 gdk_cairo_surface_upload_to_gl: Don't apply device scale
The arguments to this function is the texture width/height, and these
are already scaled.
2016-10-18 11:49:14 +01:00
Emmanuele Bassi
0ce9815bd1 gdk: Add more GDK_GL_ERROR error ids
We're going to use them in other locations.
2016-10-18 11:49:07 +01:00
Emmanuele Bassi
b425cff689 gdk: Add utility for uploading Cairo surfaces to GL
The surface-to-GL upload logic has become more complicated with the
addition of the GLES code paths; it's more logical to have a public
utility function that can be called from GDK users, instead of copy
pasting the whole thing multiple times.
2016-10-18 11:29:34 +01:00
Matthias Clasen
95c7de70c7 x11: Add the same message as the wayland backend has
This seems prudent, if we make noise about missing cursors
on Wayland, we should do the same on X11.
2016-10-17 19:11:32 -04:00
Matthias Clasen
a0140cad15 Reduce a warning to a message
The warning interferes with having a testcase to check this behavior,
so reduce this to a message.
2016-10-17 19:11:32 -04:00
Benjamin Otte
d22e5e69d9 API: gdk: Add gdk_window_new_child() and gdk_window_new_input()
This is an attempt to get rid of gdk_window_new() for more specific use
cases. These 2 are for client-side windows - regular ones and input-only
ones resepectively.

So far all those functions just call into gdk_window_new().
2016-10-18 00:22:35 +02:00
Emmanuele Bassi
a0aa1d963a broadway: Remove redundant declaration 2016-10-17 14:56:38 +01:00
Emmanuele Bassi
20b2e479f8 build: Add various compiler warnings and errors
Just like GLib, GTK+ would benefit from getting warnings and errors from
the compilers.

We check various, common warnings, especially for a future use of C99;
additionally, we promote some warnings to errors, in order to ensure
that simple mistakes are caught during the development phase, before
they are submitted to the code repository.
2016-10-17 11:44:11 +01:00
Emmanuele Bassi
923b868400 gdk/x11: Constify argument 2016-10-17 11:10:14 +01:00