[gtk+] gtk/gtknotebook.c: Use accessor functions to access GtkSelectionData
- From: Javier Jardón <jjardon src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] gtk/gtknotebook.c: Use accessor functions to access GtkSelectionData
- Date: Thu, 16 Dec 2010 00:07:38 +0000 (UTC)
commit ad4ac2182a2deffd88a8ac68886b54a77385b302
Author: Javier Jardón <jjardon gnome org>
Date: Wed Dec 15 23:54:22 2010 +0000
gtk/gtknotebook.c: Use accessor functions to access GtkSelectionData
gtk/gtknotebook.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index b66f421..8c4de65 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -3840,13 +3840,16 @@ gtk_notebook_drag_data_get (GtkWidget *widget,
guint info,
guint time)
{
- if (data->target == gdk_atom_intern_static_string ("GTK_NOTEBOOK_TAB"))
+ GdkAtom target;
+
+ target = gtk_selection_data_get_target (data);
+ if (target == gdk_atom_intern_static_string ("GTK_NOTEBOOK_TAB"))
{
GtkNotebook *notebook = GTK_NOTEBOOK (widget);
GtkNotebookPrivate *priv = notebook->priv;
gtk_selection_data_set (data,
- data->target,
+ target,
8,
(void*) &priv->detached_tab->child,
sizeof (gpointer));
@@ -3870,9 +3873,9 @@ gtk_notebook_drag_data_received (GtkWidget *widget,
source_widget = gtk_drag_get_source_widget (context);
if (source_widget &&
- data->target == gdk_atom_intern_static_string ("GTK_NOTEBOOK_TAB"))
+ gtk_selection_data_get_target (data) == gdk_atom_intern_static_string ("GTK_NOTEBOOK_TAB"))
{
- child = (void*) data->data;
+ child = (void*) gtk_selection_data_get_data (data);
do_detach_tab (GTK_NOTEBOOK (source_widget), notebook, *child, x, y);
gtk_drag_finish (context, TRUE, FALSE, time);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]