I am writing an application with a cursive GUI, and I would like to do certain things when the user presses certain keys. For example, when using a TableView I would like to perform different actions when the user has selected a row and presses a key (other than Enter which is handled by TableView and allows me to implement on_submit). Those actions would be parametrised by the selected row, i.e. using the index or some value from the row.
Since I don't have access to on_event and there doesn't seem to be an associated callback that I can register with the TableView, I can only think about storing some "global" parameters from on_select and then register global cursive handlers ala add_global_callback. This would be a big mess very soon, so I'm hoping there's a better way.
I thought I could do the equivalent of extending TableView as one would do with inheritance in OOP, but I asked here without much success, and was instead given the smart advice in the comments to just ask for what I want to accomplish instead.