Re: [gtkmm] Getting key events?
- From: wdewey1 comcast net
- To: gtkmm-list gnome org
- Subject: Re: [gtkmm] Getting key events?
- Date: Mon, 08 Dec 2003 12:28:08 +0000
I believe this is what you are looking for, but I could be wrong (I'm still pretty new to this stuff). I pulled these out of a pop up menu example:
virtual bool on_button_press_event(GdkEventButton* event);
bool ExampleWindow::on_button_press_event(GdkEventButton* event)
{
if( (event->type == GDK_BUTTON_PRESS) && (event->button == 3) )
{
m_Menu_Popup.popup(event->button, event->time);
return true; //It has been handled.
}
else
return false;
}
This works at least for mouse buttons.
Bill Dewey
> Greetings,
>
> I have a quick question to ask that I couldn't find answered in the gtkmm
> documentation:
>
> How does one receive the keys that are being pressed/released from a
> GdkEventKey that is the parameter of an function called by a callback?
>
> Thanks in advance.
>
> _________________________________________________________________
> Hot chart ringtones and polyphonics. Go to
> http://ninemsn.com.au/mobilemania/default.asp
>
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]