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
Add selected to runOnce #107
Comments
Good suggestion, @benhul; it would be helpful to be able to set the menu selection.
Would it work for you if it were implemented this way? |
Good name int current_row = 1;
//...
menu.setPick(current_row);
runOnce();
current_row = menu.pick();
.... Have fun. |
You can write color managers functions like this and call them as advanced function from main menu at menu item's selection press. You can also add callingMenu->pick(); to find the color selected.
|
You're right, missed that one... |
I could use the setPick() idea as well. Any idea when this will be impemented? |
Hey, I added these in my fork because I am building something similar: |
I don't think your code is completely correct. |
Your library works great. I use it to set the options for my program.
Maybe you can add an optional selected field to the .runOnce function.
I use a menu to set preferences and I use a \t to show the current value to the right on the same line. After clicking +, 5 is added to the current value. I would like to renew the menu with the new value (which I can) but the same (second) row selected (which I can't).
I made the change for myself (it's only 4 lines of code::smile: ) but others could benefit.
Or put it in a more generic menu.setSelected(int selected) function.
The text was updated successfully, but these errors were encountered: