Re: [gtk-list] Re: gtk_entry and signals



On 22 Aug 1997 17:32:09 -0500, Daniel R Risacher wrote:

	d> Yes, this is a very good idea.  I was looking at this issue
	d> when I got distracted by the fact that, in gtkwindow.c,
	d> only the default widget gets GDK_Return and GDK_KP_Enter.
	d> If there is no default wigdet, I think the focus widget
	d> needs to get these events.

I had a different patch to this, which I posted on the list later.

	case GDK_KP_Enter:
          if (window->default_widget) {
            gtk_widget_activate (window->default_widget);
	    return_val = TRUE;
	  }
	  break;

This way, the widget gets the return key as a key_press event, which
it can handle in any way it pleases. Further, for a correct
implementation of the text widget, the return key has to be propagated
to it as a key press event.

	d> These two changes go together well.  I encourage you to
	d> implement your suggestion.

I've sent the patches to Peter. Let me know, if you're interested in
grabbing a copy.

	-Arun



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