Entry->signal_key_release_event not received

Hello!

I’m on gtkmm-3.22.x (linux x86_64) and I have the following code:

Glib::RefPtr<Gtk::Builder> m_builder;
Gtk::Dialog *dialog = 0x0;
Gtk::Entry *entry = 0x0;

[snip]
dialog->add_events(Gdk::KEY_PRESS_MASK | Gdk::KEY_RELEASE_MASK | Gdk::BUTTON_PRESS_MASK | Gdk::BUTTON_RELEASE_MASK | Gdk::POINTER_MOTION_MASK);
m_builder->get_widget("entry_otp", entry);
entry->signal_key_press_event().connect(
		sigc::mem_fun(*this, &SS_Window_InitOTP::on_entry_otp_key_press_event), false);

entry->signal_key_release_event().connect(
		sigc::mem_fun(*this,&SS_Window_InitOTP::on_entry_otp_key_release_event), false);
[snip]

When I type into the entry on_entry_otp_key_press_event is called on each keystroke, but on_entry_otp_keystroke isn’t. And I don’t understand why…

Any hints?

Thanks and best regards,
Christian

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.