My app is featured in the “SuccessfullyTHUNK’d” section, with two screen capture to illustrate:
(It is a big app: 5 screens, totals 7105 obsessively optimized blocks, relies on 7 HTML files, 4 of which having JavaScript code, and still managed to keep the apk at 4.55 M)
If you look at it, the white center section is a ‘canvas’ object. The user is ment to touch the white area where they want to insert or edit a dimensional unit, which is specified using various pull down menus or function keys. Which means that this area has to be interactive, continuously receiving new specifications from the application logic (“write ‘min’ for minute in blue at position X Y”), and sending information back to the code (“user tapped screen at location X Y”).
Additionally, there are several discrete functions that are working behind the scene, relying on web-viewer to load an HTML file that runs a JavaScript. One for those, for instance, is a heap sort utility that organizes all the units in order of recent use. With about 400 different units, the heap sort function was tested to take between 3.1 and 3.5 seconds to return an ordered list that could then be sub-sampled (retaining only the 20 most used units) and presented to the user in a list picker when the algorithm is written in ‘thunkable’ blocks; clearly 3 seconds is uncomfortably long to be practical as “short cut”, and the whole sorting process is handled by a JavaScript code that runs approximately 700 times faster.
But in order for this to work, I need the application front end to be able to pass the information to the HTML as a Webview string (the unsorted list), and for the front end to be able to receive the sorted list back once processed.
Both the canvas, and the ability to communicate bidirectionally with a Web_Viewer object exist in ‘thunkable classic’; my requirements is simply to have them work in a similar fashion with “x”.
Or, if you want it in more general terms, I would need an interactive component where I could write and draw at a specified X and Y location, and which would return the X and Y coordinate of the location touched in the form of a triggered event; and the ability to communicate and interface with another component like Web_Viewer, through a string (or list, number, object), the latter being the more desirable since I can emulate the former using HTML/JavaScript using a Web_Viewer as long as the from end can send and receive messages.