edgetx
edgetx copied to clipboard
feat: Remove TR# mixsrc when trainer disabled
When a trainer mode is not enabled, there is no point showing the TR# mixer sources. Once you enable a trainer option, they will become visible again.
Tested on TX16S and TX12-MKII. TR# sources are only visible when Trainer mode not OFF.
Also fixes issue where validation of input availabliity was not happening on B&W radios :grin:
I have the trainer channels as source on the first line on my inputs, on combi with a switch checking for a value on tr6, trainer mode or not.
What happens with this due to this change?
Is trainer mode turned OFF in the main model settings? (this isn't connected to the state of the special function) Also, this doesn't alter existing settings - only prevents it from being selected in the UI with trainer mode settings OFF.
@pfeerick Companion?
Not there yet. Depends on the reception to this potential change ;)
I'm in favour of removing anything that is not in context especially shortening lists. If its not in a list then something else needs changing.
There is a difference between being displayed and not being available in a list to select.
Normally, you would make the list consisting of the items available based on context, or scope, with one extra element, the current selected value. This would prevent the issue that if you accidentally enter into edit mode, you can't back out without change. You would be forced to change it to something in scope or context.
If this is how it is meant to work, I fully agree.
At the same time, people in general have a hard time understanding 'scope' or 'context'. A lot of users won't understand they need to activate trainer mode before the list to select sources will contain trainer channels.
"Normally" is a dangerous word to be throwing around here - normally as defined by who? :-P
But t is normal for the radio user interface behaviour generally. You can often have otherwise "invalid" settings, up to the point at which you go in to edit them, and at that point, they will be validated and invalid entries cleared. By doing this, the radio doesn't immediagely got an clear all your settings on you when you go change another setting. Just imagine, you go in to Model -> Trainer, and turn the trainer mode off - and the radio then goes and removes all the TR# mixsrc (so input and mix sources) and maybe even TR special function from all your models!?! Whereas, in this case, it would leave all settings entirely alone, until the point you click on the choice, and the list is filtered. At that point, it will hilight the top ---
entry since the configured source is "invalid" for context (i.e. Trainer is OFF - which btw is a new option since around 2.6 IIRC - you never used to be able to turn it OFF before ;) ). And even then, you have a get-out-of-jail-free card - you can press RTN/tap outside the choice selection and the source will not be changed - you have to press ENT to confirm your selection. Admittedly B&W isn't as user friendly in that regard - pressing RTN and ENT are the same there... maybe that is something we can improve.
As we move more towards allowing stuff to be turned off at the model level, which will be a major part of 2.9, anyone who can't understand "I can can't access GV# if GV is turned off in model settings, I can't access heli tab and heli opts if heli turned off in the model settings" will have to learn that - or complain enough that we need to think about a different way to handle it.
We're at the same point here.
As long as there is the get-out-of-jail-free card. How that is implemented is less important.
Why not create a display policy for invalid items. Let them preceded by a star and print in fat.
Than you have the best of both worlds: you can ALWAYS directly spot invalid entries, but are still informed about what that invalid entry is. Very useful also in showing for instance logical switches that don't exist anymore on special functions. At least you would know which switch that you just deleted impacted which special function.
There is already such a warning on having multiply on the first mixer line I think.
IMO the goal is to reduce the size of the list, not prevent anything stupid from being done.
IMO the goal is to reduce the size of the list, not prevent anything stupid from being done.
You cannot prevent people from doing anything stupid. But at least facilitate them correcting it. :)
IMO the goal is to reduce the size of the list, not prevent anything stupid from being done.
That it is... and this PR is not going to attempt to go any further than it has (other than making Companion behave the same way)... but I do like what @lshems said, and think that is something worth trying to do... i.e. some "simple" indication that "that source/LS/whatever not exist no more"...
Nice
but I do like what @lshems said, and think that is something worth trying to do... i.e. some "simple" indication that "that source/LS/whatever not exist no more"...
It would need to work on B&W and color radios
@elecpower Just to prove I don't know what I'm doing at all 🙃 ... 6e81dc1 seems to do the necessary filtering - i.e. TR# is removed when Trainer mode is off - but I don't know what I need to push/poke so that those same source lists for Input and Mixes tabs reflect the changed state of the trainer combo without requiring the model window to be reloaded. 😆
That takes a whisperer ;-)
Let me finish the lipo conversion and I'll wave the magic wand over this one
Thank you 😍 It will be another useful reference commit, as that sort of dynamic update may start to appear more soon :)
@pfeerick The Whisperer has spoken to the Beast and can report that your wish has been granted. [insert applause sound effect here]
PS Lucky for me the refresh plumbing framework that I put in place a while back was already in this area so an easy one this time.
Damn, you are on fire! :)
PS: Just don't look too hard... https://media4.giphy.com/media/l4Hoe5Xzfh5UBahVK/giphy.gif