[vte] Don't use internal GTK+ api



commit 86225e5f053bf8bfb3e851fda437455624514eec
Author: Matthias Clasen <mclasen redhat com>
Date:   Sun Jan 16 11:07:14 2011 -0500

    Don't use internal GTK+ api
    
    GtkTargetPair was always documented as private, and in
    GTK+ 3 it is gone from the headers. Just use existing API.

 src/vte.c |    8 +-------
 1 files changed, 1 insertions(+), 7 deletions(-)
---
diff --git a/src/vte.c b/src/vte.c
index 5b95b1c..651c653 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -6354,13 +6354,7 @@ vte_terminal_copy(VteTerminal *terminal, GdkAtom board)
 
 			list = gtk_target_list_new (NULL, 0);
 			gtk_target_list_add_text_targets (list, 0);
-
-			n_targets = g_list_length (list->list);
-			targets = g_new0 (GtkTargetEntry, n_targets);
-			for (l = list->list, i = 0; l; l = l->next, i++) {
-				GtkTargetPair *pair = (GtkTargetPair *)l->data;
-				targets[i].target = gdk_atom_name (pair->target);
-			}
+                        targets = gtk_target_table_new_from_list (list, &n_targets);
 			gtk_target_list_unref (list);
 		}
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]