Added threaded background preview loading
[pandora-libraries.git] / minimenu / mmui.h
index 8beff3b..a575f48 100644 (file)
@@ -65,11 +65,17 @@ void ui_loadscreen ( void );        // show screen while loading the menu
 void ui_discoverscreen ( unsigned char clearscreen ); // screen to show while scanning for apps
 void ui_cachescreen ( unsigned char clearscreen, char *filename ); // while caching icons, categories and preview-pics-Now-mode
 
+/* internal functions follow
+ */
+
 // show a menu, return when selection made; -1 means no selection. Enter is pick.
 int ui_modal_single_menu ( char *argv[], unsigned int argc, char *title, char *footer );
 
-/* internal functions follow
- */
+// run a forked app (ie: not wait for it to return)
+unsigned char ui_forkexec ( char *argv[] ); // argv[0] is proggy to exec; argv last entry must be NULLptr
+
+// create a thread of this guy, and it'll try to load the preview pic in background and then signal the app
+unsigned char ui_threaded_defered_preview ( pnd_disco_t *p );
 
 // change the focus
 void ui_process_input ( unsigned char block_p );
@@ -83,11 +89,13 @@ void ui_push_rtrigger ( void );
 unsigned char ui_determine_row ( mm_appref_t *a );
 unsigned char ui_determine_screen_row ( mm_appref_t *a );
 unsigned char ui_determine_screen_col ( mm_appref_t *a );
+unsigned char ui_show_info ( char *pndrun, pnd_disco_t *p );
 
 // ui_render() can register tappable-areas which touchscreen code can then figure out if we made a hit
 void ui_register_reset ( void );
-void ui_register_tab ( mm_category_t *category, unsigned int x, unsigned int y, unsigned int w, unsigned int h );
-void ui_register_app ( pnd_disco_t *app, unsigned int x, unsigned int y, unsigned int w, unsigned int h );
+void ui_register_tab ( unsigned char catnum, unsigned int x, unsigned int y, unsigned int w, unsigned int h );
+void ui_register_app ( mm_appref_t *app, unsigned int x, unsigned int y, unsigned int w, unsigned int h );
+void ui_touch_act ( unsigned int x, unsigned int y );
 
 // deferred preview timer
 void ui_set_selected ( mm_appref_t *r );