mc/gnome/gblist.c
Miguel de Icaza 824b7198ea Icon View mode for GNOME/mc:
1. My icons suck.
	2. Keyboard handling is not finished.
	3. Save current-mode, load current-mode is not
	   implemented yet.
	4. Listing mode is not working, as I have hardcoded
	   the icon view for now.
	5. Will finish this tomorrow.  Not much is missing.
	6. No, this is not the final implementation.
	7. Yes, later I will put some scheme for using
	   more icons as discussed in the ethernal "Re: Icons"
	   thread.

Miguel.

1998-05-07  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* gscreen.c (panel_icon_list_realized): Add drag and drop support
	to the icon list view;

1998-05-06  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* gscreen.c (panel_fill_panel_icons): New function:  Fill up the
	icon list.
	(x_create_panel): Change in the approach:  we create both of the
	widget views at creation time and we now carefully show every
	component.  I attach everything to the table, but not necesarly
	show it.
1998-05-08 02:25:00 +00:00

69 lines
1.4 KiB
C

/*
* gblist: Implements a GtkCList derived widget that does not take any action
* on select and unselect calls.
*
* Author: Miguel de Icaza (miguel@kernel.org)
* (C) 1998 the Free Software Foundation.
*/
#include <stdlib.h>
#include "config.h"
#include "gblist.h"
static void
blist_select_row (GtkCList *clist, gint row, gint column, GdkEventButton *event)
{
/* nothing */
}
static void
blist_unselect_row (GtkCList *clist, gint row, gint column, GdkEventButton *event)
{
/* nothing */
}
static void
gtk_blist_class_init (GtkBListClass *klass)
{
GtkCListClass *clist_class = (GtkCListClass *) klass;
clist_class->select_row = blist_select_row;
clist_class->unselect_row = blist_unselect_row;
}
GtkType
gtk_blist_get_type (void)
{
static GtkType blist_type = 0;
if (!blist_type){
GtkTypeInfo blist_info =
{
"GtkBList",
sizeof (GtkBList),
sizeof (GtkBListClass),
(GtkClassInitFunc) gtk_blist_class_init,
(GtkObjectInitFunc) NULL,
(GtkArgSetFunc) NULL,
(GtkArgGetFunc) NULL,
};
blist_type = gtk_type_unique (gtk_clist_get_type (), &blist_info);
}
return blist_type;
}
GtkWidget *
gtk_blist_new_with_titles (gint columns, gchar * titles[])
{
GtkWidget *widget;
g_return_val_if_fail (titles != NULL, NULL);
widget = gtk_type_new (gtk_blist_get_type ());
gtk_clist_construct (GTK_CLIST (widget), columns, titles);
return widget;
}