[Logo] TCC discussion forum
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Top Downloads] Top Downloads   [Groups] Back to home page 
[Register] Register /  [Login] Login 


This forum is read only and new users cannot register, please ask all new questions either using GitHub discussions, or in Arduino forum tagging @davetcc.

Callback function on the root of the menu? RSS feed
Forum Index » tcMenu Arduinio library
Author Message
pruttelherrie


Joined: Oct 21, 2020
Messages: 24
Offline
Hi,

Is it possible to have a callback function on the root of the menu? When I use the example "colorTftEthernet32", the submenus have a nice back function on their title, formatted like "Title [...]". I would like to have a similar function on the main title, which would then trigger takeOverDisplay();

See also the guitar-multi-effect-thingy topics in the "built with" category, here I have a "back to PLAY" action as first item of the main menu. This could just as well be the title of the main menu. Going back with giveBackDisplay() would then go right to the first item in the main menu.
davetcc


Joined: Jan 19, 2019
Messages: 686
Offline
Something similar to that will be in version 2.0 of the library once released. You can register a handler for when the main title is clicked or touched. It is supported on all graphical renderers. You can see it used in a few of the new examples.

However 2.0 library is still a little way off while we fully test it.
pruttelherrie


Joined: Oct 21, 2020
Messages: 24
Offline
Cool. I'm happy as it is but it makes for a more logical UI if this works.
 
Forum Index » tcMenu Arduinio library
Go to:   
Mobile view
Powered by JForum 2.7.0 © 2020 JForum Team • Maintained by Andowson Chang and Ulf Dittmer

This site uses cookies to analyse traffic, serve ads by Google AdSense (non-personalized in EEA/UK), and to record consent. We also embed Twitter, Youtube and Disqus content on some pages, these companies have their own privacy policies.

Our privacy policy applies to all pages on our site

Should you need further guidance on how to proceed: External link for information about cookie management.