Content Controls


Illustrates simple and advanced usage of the following content controls: Web View, Map View, Search Controller, Navigation Bar, and Tab Bar Controller.

Web View - Contains a simple web browser built around the Web View control. Illustrates how to load URLs, hook into events, perform browsing functions, etc. Also has a web view view that loads HTML content from a local directory. Additionally, shows how to interact with content in the web view by executing JavaScript and listening for specially formed URLs, in order to execute code outside of the browser.

Maps - Illustrates how to display a map using the map view. Includes traditional map, satellite, and hybrid layers. Also shows how to add annotations and overlays to the map, as well as calculate the distance to particular locations from the map center.

Search - Illustrates how to use the search bar and listen for events to provide real-time search results as the search text changes.

Navigation Bar - Illustrates how to customize the navigation bar by adding buttons, changing the color, making it transparent, and event adding a toolbar at the bottom of the view.

Tab Bar Controller - Illustrates adding items to the tab bar controller as well as allowing it to be edited/customized by rearranging tab items and adding/removing them.


This sample demonstrates Android's content controls.

Browsers - WebView, WebView Browser, Local Content, Generated Content, Javascript Interop

Maps ^^ - Basic MapView, MapView with Annotation, MapView with Overlay

Search - AutoCompleteTextView

Nav - Activity Fade, Activity Zoom, Light Theme

^^ NOTE: the Map examples require the PrivateStrings.xml "GoogleMapAPIKey" key to be uncommented and a valid key added. See (you should also have installed the Google APIs Add-on via the Android SDK Manager).


Bryan Costanich, Craig Dunn