Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(color): New inputs disappear until restart. #4317

Merged
merged 1 commit into from
Nov 17, 2023

Conversation

philmoz
Copy link
Collaborator

@philmoz philmoz commented Nov 13, 2023

Fixes #4315

Adding a new input with a gap before it to the last input would add the new to the wrong slot in the 'expos' data array.
Restarting the radio would rebuild the 'expos' array correctly.

This PR fixes ensures new inputs are added at the right spot (and cleans up the source file formatting).

@pfeerick pfeerick added bug 🪲 Something isn't working color Related generally to color LCD radios labels Nov 14, 2023
@pfeerick pfeerick added this to the 2.9.x milestone Nov 14, 2023
@pfeerick
Copy link
Member

Another issue I realised that doesn't stem from the same bug, but is semi-related, is that if you say

  1. start with a blank model (so only four inputs)
  2. add input 10

then when you go back to the add menu, it will let you add 5,11-32. If you add 5, it'll then let you add 6, and so on, and so on.

2.9.1 doesn't exhibit this bug, so 2.10 only I think.

@pfeerick pfeerick merged commit 774383b into EdgeTX:main Nov 17, 2023
37 checks passed
@philmoz
Copy link
Collaborator Author

philmoz commented Nov 17, 2023

I think there is a bigger problem with the PR - please don't add it to 2.9 just yet.

@pfeerick
Copy link
Member

pfeerick commented Nov 17, 2023

I actually had (and should have been paying more attention, as this introduced that odd behaviour on the 2.9 build also), but have rolled it back. For some reason, I thought the aforementioned behaviour was present in 2.10 prior to now 🤷

I blame the heatwave 😆 ... I'm in the severe area ...
image

pfeerick added a commit that referenced this pull request Nov 17, 2023
Cherrypick of #4317 and #4330

Co-authored-by: philmoz <philmoz@users.noreply.github.com>
MRC3742 pushed a commit to MRC3742/edgetx that referenced this pull request Dec 22, 2023
Cherrypick of EdgeTX#4317 and EdgeTX#4330

Co-authored-by: philmoz <philmoz@users.noreply.github.com>
@philmoz philmoz deleted the fix-new-input-ordering branch February 17, 2024 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🪲 Something isn't working color Related generally to color LCD radios
Projects
None yet
2 participants