Button management core/modules

Started by Marsu42, September 28, 2013, 10:17:56 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Marsu42

Well, I'm not much of a C coder, but I can offer some ideas - "Those who can't do, teach", you know :-p ...

Problem: With more features and modules, assignment of buttons to functions gets confusing. I'm currently writing a hotkey module for use outside lv, but keeping up do date in which situations another functions for example does something with SET is a pita.

Currently: Currently modules have CBR_KEYPRESS, and then, nobody knows what keys they intercept or what they do with them - in the core it's even worse, you can hook into the shoot task everywhere and use keys.

Suggestion: Modules (and also the core itsself, for that matter) should explicitly register keys with the core as either blocking (only they want to tie a function to it) or non-blocking (everybody else also can afterwards). For blocking functions, the core could then issue an "ok, nobody else is using it" return code or fail with a hint which other function was quicker - so if the user cannot use function 1 which wants to use SET, he/she knows what to disable. Also the "register" function should have a "override Canon" switch for taking away buttons from Canon like SET. The core could also then easily print a list of keys that do something with ml in a help menu.

What do you think - is this useful or overengineering (and anybody else wondering what his SET currently does - Canon function, ettr, af, ...)? Anybody with good C coding ability volunteering :-p ?


Marsu42