Adapted nesting of functions to Mobile_HTML5Function.