summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick McLean <chutzpah@gentoo.org>2016-06-29 13:28:47 -0700
committerPatrick McLean <chutzpah@gentoo.org>2016-06-29 13:29:18 -0700
commit533bd6dac8e8c9fcec94bfad564ea6fb893b7db8 (patch)
tree4e8ce113d189e5cc9f2e196e115d5b01f206ecf3 /media-gfx/inkscape/files
parentwww-client/chromium: require USE=gnome for GN build; for bug #587366 by floppym (diff)
downloadgentoo-533bd6dac8e8c9fcec94bfad564ea6fb893b7db8.tar.gz
gentoo-533bd6dac8e8c9fcec94bfad564ea6fb893b7db8.tar.bz2
gentoo-533bd6dac8e8c9fcec94bfad564ea6fb893b7db8.zip
media-gfx/inkscape: Revision bump, port to EAPI=6, add patch to fix compilation with glibmm-2.48 (bug #587098)
Package-Manager: portage-2.3.0
Diffstat (limited to 'media-gfx/inkscape/files')
-rw-r--r--media-gfx/inkscape/files/inkscape-0.91-fix-gtkmm-2.48.patch63
1 files changed, 63 insertions, 0 deletions
diff --git a/media-gfx/inkscape/files/inkscape-0.91-fix-gtkmm-2.48.patch b/media-gfx/inkscape/files/inkscape-0.91-fix-gtkmm-2.48.patch
new file mode 100644
index 000000000000..f9c06601e837
--- /dev/null
+++ b/media-gfx/inkscape/files/inkscape-0.91-fix-gtkmm-2.48.patch
@@ -0,0 +1,63 @@
+--- a/src/ui/clipboard.cpp 2016-04-02 15:15:43 +0000
++++ b/src/ui/clipboard.cpp 2016-04-07 16:30:32 +0000
+@@ -146,8 +146,6 @@
+ void _setClipboardColor(guint32);
+ void _userWarn(SPDesktop *, char const *);
+
+- void _inkscape_wait_for_targets(std::list<Glib::ustring> &);
+-
+ // private properites
+ SPDocument *_clipboardSPDoc; ///< Document that stores the clipboard until someone requests it
+ Inkscape::XML::Node *_defs; ///< Reference to the clipboard document's defs node
+@@ -1302,9 +1300,7 @@
+ */
+ Glib::ustring ClipboardManagerImpl::_getBestTarget()
+ {
+- // GTKmm's wait_for_targets() is broken, see the comment in _inkscape_wait_for_targets()
+- std::list<Glib::ustring> targets; // = _clipboard->wait_for_targets();
+- _inkscape_wait_for_targets(targets);
++ std::list<Glib::ustring> targets = _clipboard->wait_for_targets();
+
+ // clipboard target debugging snippet
+ /*
+@@ -1456,39 +1452,6 @@
+ desktop->messageStack()->flash(Inkscape::WARNING_MESSAGE, msg);
+ }
+
+-
+-// GTKMM's clipboard::wait_for_targets is buggy and might return bogus, see
+-//
+-// https://bugs.launchpad.net/inkscape/+bug/296778
+-// http://mail.gnome.org/archives/gtk-devel-list/2009-June/msg00062.html
+-//
+-// for details. Until this has been fixed upstream we will use our own implementation
+-// of this method, as copied from /gtkmm-2.16.0/gtk/gtkmm/clipboard.cc.
+-void ClipboardManagerImpl::_inkscape_wait_for_targets(std::list<Glib::ustring> &listTargets)
+-{
+- //Get a newly-allocated array of atoms:
+- GdkAtom* targets = NULL;
+- gint n_targets = 0;
+- gboolean test = gtk_clipboard_wait_for_targets( gtk_clipboard_get(GDK_SELECTION_CLIPBOARD), &targets, &n_targets );
+- if (!test || (targets == NULL)) {
+- return;
+- }
+-
+- //Add the targets to the C++ container:
+- for (int i = 0; i < n_targets; i++)
+- {
+- //Convert the atom to a string:
+- gchar* const atom_name = gdk_atom_name(targets[i]);
+-
+- Glib::ustring target;
+- if (atom_name) {
+- target = Glib::ScopedPtr<char>(atom_name).get(); //This frees the gchar*.
+- }
+-
+- listTargets.push_back(target);
+- }
+-}
+-
+ /* #######################################
+ ClipboardManager class
+ ####################################### */
+