gnome-commander r2216 - in trunk: . src



Author: epiotr
Date: Sat Oct 18 17:40:02 2008
New Revision: 2216
URL: http://svn.gnome.org/viewvc/gnome-commander?rev=2216&view=rev

Log:
GnomeCmdFileList: operator for casting to GtkWidget *

Modified:
   trunk/ChangeLog
   trunk/src/gnome-cmd-file-list.cc
   trunk/src/gnome-cmd-file-list.h

Modified: trunk/src/gnome-cmd-file-list.cc
==============================================================================
--- trunk/src/gnome-cmd-file-list.cc	(original)
+++ trunk/src/gnome-cmd-file-list.cc	Sat Oct 18 17:40:02 2008
@@ -686,8 +686,7 @@
 {
     g_return_if_fail (GNOME_CMD_IS_FILE_LIST (fl));
 
-    gtk_drag_source_set (GTK_WIDGET (fl), GDK_BUTTON1_MASK,
-                         drag_types, G_N_ELEMENTS (drag_types),
+    gtk_drag_source_set (*fl, GDK_BUTTON1_MASK, drag_types, G_N_ELEMENTS (drag_types),
                          (GdkDragAction) (GDK_ACTION_LINK | GDK_ACTION_MOVE | GDK_ACTION_COPY | GDK_ACTION_ASK | GDK_ACTION_DEFAULT));
 
     gtk_signal_connect (*fl, "drag-data-get", GTK_SIGNAL_FUNC (drag_data_get), fl);
@@ -1101,7 +1100,7 @@
             gint row = fl->get_row_from_file(finfo);
 
             fl->select_row(row);
-            gtk_widget_grab_focus (GTK_WIDGET (fl));
+            gtk_widget_grab_focus (*fl);
 
             if (event->button == 1)
             {

Modified: trunk/src/gnome-cmd-file-list.h
==============================================================================
--- trunk/src/gnome-cmd-file-list.h	(original)
+++ trunk/src/gnome-cmd-file-list.h	Sat Oct 18 17:40:02 2008
@@ -68,6 +68,7 @@
     void operator delete (void *p)      {  g_free (p);  }
 
     operator GtkObject * ()             {  return GTK_OBJECT (this);       }
+    operator GtkWidget * ()             {  return GTK_WIDGET (this);       }
     operator GtkCList * ()              {  return GTK_CLIST (this);        }
     operator GnomeCmdCList * ()         {  return GNOME_CMD_CLIST (this);  }
 



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