Support Gtk+3
cover Support Gtk+3
This patch is part of the quest to make Sato compatible with GTK+3. Complete WIP collection of patches can be found in jku/matchbox-wip branch at git://git.yoctoproject.org/poky-contrib
The following changes since commit 3a9688e8a01b63a78f402b4e7c0b8b005fcdfa29:
build: change link ordering to fix link problems (2013-06-17 16:58:49 +0100)
are available in the git repository at:
git://github.com/jku/sato-screenshot gtk3
https://github.com/jku/sato-screenshot/tree/gtk3
Jussi Kukkonen (1):
Quick port to Gtk/Gdk 3
configure.ac | 2 +- screenshot-utils.c | 77 +++++++++++++++++++++++++++++------------------------- 2 files changed, 43 insertions(+), 36 deletions(-)
Signature · 1 line
2.8.1
PATCH 1/1 Quick port to Gtk/Gdk 3
This still has all the problems that the new API would allow us to
fix: mainly that multiple displays will almost certainly not work at all.
--- configure.ac | 2 +- screenshot-utils.c | 77 +++++++++++++++++++++++++++++------------------------- 2 files changed, 43 insertions(+), 36 deletions(-)
configure.ac +1 -1
@@ -12,7 +12,7 @@ AC_PROG_CC AC_STDC_HEADERS AC_PROG_LIBTOOL -PKG_CHECK_MODULES(DEPS, x11 gdk-x11-2.0 gtk+-2.0) +PKG_CHECK_MODULES(DEPS, x11 gdk-x11-3.0 gtk+-3.0) MB_APPLET="yes"
screenshot-utils.c +42 -35
192 lines not on this page · raw message
Signature · 1 line
2.8.1
Re: [screenshot][PATCH 1/1] Quick port to Gtk/Gdk 3
Quoted 4 lines · Jussi Kukkonen
This still has all the problems that the new API would allow us to
fix: mainly that multiple displays will almost certainly not work at all.
screenshot-utils.c: In function 'screenshot_grab_lock':
screenshot-utils.c:251:3: warning: 'gdk_pointer_grab' is deprecated: Use 'gdk_device_grab' instead [-Wdeprecated-declarations]
gdk_pointer_grab (gtk_widget_get_window (selection_window), FALSE, 0,
NULL,
^
In file included from /usr/include/gtk-3.0/gdk/gdk.h:47:0,
from /usr/include/gtk-3.0/gtk/gtk.h:30,
from screenshot-utils.h:4,
from screenshot-utils.c:2:
/usr/include/gtk-3.0/gdk/gdkmain.h:86:15: note: declared here
GdkGrabStatus gdk_pointer_grab (GdkWindow *window,
^screenshot-utils.c:253:3: warning: 'gdk_cursor_unref' is deprecated: Use 'g_object_unref' instead [-Wdeprecated-declarations]
gdk_cursor_unref (cursor);
^
In file included from /usr/include/gtk-3.0/gdk/gdk.h:34:0,
from /usr/include/gtk-3.0/gtk/gtk.h:30,
from screenshot-utils.h:4,
from screenshot-utils.c:2:
/usr/include/gtk-3.0/gdk/gdkcursor.h:247:13: note: declared here
void gdk_cursor_unref (GdkCursor *cursor);
^screenshot-utils.c: In function 'get_text_property':
screenshot-utils.c:121:3: warning: ignoring return value of 'gdk_error_trap_pop', declared with attribute warn_unused_result [-Wunused-result]
gdk_error_trap_pop ();
^
CC screenshot-ui.loscreenshot-ui.c: In function 'screenshot':
screenshot-ui.c:49:46: warning: 'GtkStock' is deprecated [-Wdeprecated-declarations]
GTK_STOCK_CANCEL,GTK_RESPONSE_REJECT,
^
screenshot-ui.c:50:46: warning: 'GtkStock' is deprecated [-Wdeprecated-declarations]
GTK_STOCK_SAVE,GTK_RESPONSE_ACCEPT,
^
The stock ones look easy to fix, the device ones less so so unless I'm wrong we can leave those for now.
Ross
Re: [screenshot][PATCH 1/1] Quick port to Gtk/Gdk 3
Quoted 2 lines · Ross
The stock ones look easy to fix, the device ones less so so unless I'm wrong we can leave those for now.
The grab code was trickier with current API (which is why I left it as is), but I took another look and it turns out that code has never actually been used...
So I removed _grab_lock() and _release_lock(), and replaced STOCK items with text.
I've added these changes to the same branch (should now compile without warnings):
git://github.com/jku/sato-screenshot gtk3
https://github.com/jku/sato-screenshot/tree/gtk3
Jussi
Re: [screenshot][PATCH 1/1] Quick port to Gtk/Gdk 3
Quoted 11 lines · Jussi Kukkonen
The grab code was trickier with current API (which is why I left it as is), but I took another look and it turns out that code has never actually been used...
So I removed
_grab_lock()and_release_lock(), and replaced STOCK items with text.
I've added these changes to the same branch (should now compile without warnings):
git://github.com/jku/sato-screenshotgtk3
https://github.com/jku/sato-screenshot/tree/gtk3
Merged and tagged, thanks Jussi.
Ross