Native UI Web Views

Hi Metismo Experts,

I am new to the product and have been teaching myself over the last week.

One of the more interesting controls I have come across is the WebViews and the ability to load raw html into the application. This would be particularly useful for complex UI development as I am more confident using HTML / CSS design techniques. I have already created a demo app which loads a jQuery Mobile page (stored inside the resource folder) however I realised there isn’t any obvious way to submit data back to the native application. So here are my questions:

· Is it possible to interact with the native application from within a WebView, either via scripts or call backs?

· What is the different between a WebView and WebViewElement control, and under what circumstances would you decide which to use?

· The WebViewCallBack interface seems to allow URLs to be rewritten when the page is loaded, is this its only function? Could this be used to intercept and handle URL requests?

Thanks & Regards,

Jack Gibson

Hi Jack,

The WebView is something that is having its features enhanced significantly at the moment (including support for it within Phoney), sure one of the other guys on the team will be along shortly to give you a few more details on what is planned.

Regards

John

Hi Jack,

Using the CallBack mechanism is a way to make the WebView and the rest
of the app interact, yes. You’ll see an example in our NativeUIDemo
where the CallBack triggers some JavaScript that changes the background
colour of the WebView - a simple example, but you can imagine how this
could be extended to much more complex scenarios, both within the
WebView itself and outside.

As for the difference between the two components, WebView is the
equivalent of a full screen browser, whereas WebViewElement can be used
to inline a small browser subview amongst other Native UI elements in a
page. Again, see our NativeUIDemo for an example of this.

Regards,

Nick.
(Mobile Designer Development Team)