CList event problems



More GTK oddities for you folks....

I've got this clist which I call using:

  gtk_signal_connect(GTK_OBJECT(signal_lists), "button_press_event",
GTK_SIGNAL_FUNC(clist_select), GINT_TO_POINTER(number));

I would prefer to use "select_row" signal but it won't work with a right
mouse button event so this will have to do!

static void clist_select(GtkWidget *list, GdkEventButton *event, gpointer
data)
{
  gint row, column;
// snip
  gtk_clist_get_selection_info(GTK_CLIST(list), event->x, event->y, &row,
&column);
// do other stuff
}

The problem with that method is that when I click and drag the CLIST column
title to alter the width of the widget it also registers it as a click on
row 0. I've not found a way to find a difference between a click on the
resize bar and normal click on the clist itself.

Obviously, I'd like to find a way to tell them apart! GDK_BUTTON1_MASK might
help but I'm not exactly sure how to use it!

Thanks for the help!

Rich




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