Merge change Iaf5d2cc2 into eclair-sdk
* changes:
doc change: misc doc fixes.
diff --git a/docs/html/search.jd b/docs/html/search.jd
index 8032b22..d0e7478 100644
--- a/docs/html/search.jd
+++ b/docs/html/search.jd
@@ -70,8 +70,8 @@
searchControl.setSearchStartingCallback(this, function(control, searcher, query) {
// save the tab index from the hash
tabIndex = location.hash.split("&t=")[1];
-
- $("#searchTitle").html("search results for <em>" + query + "</em>");
+
+ $("#searchTitle").html("search results for <em>" + escapeHTML(query) + "</em>");
$.history.add('q=' + query + '&t=' + tabIndex);
openTab();
});
@@ -96,7 +96,8 @@
$(window).history(function(e, hash) {
var query = decodeURI(getQuery(hash));
searchControl.execute(query);
- $("#searchTitle").html("search results for <em>" + query + "</em>");
+
+ $("#searchTitle").html("search results for <em>" + escapeHTML(query) + "</em>");
});
// forcefully regain key-up event control (previously jacked by search api)
@@ -131,6 +132,13 @@
return queryParts[1];
}
+ /* returns the given string with all HTML brackets converted to entities
+ TODO: move this to the site's JS library */
+ function escapeHTML(string) {
+ return string.replace(/</g,"<")
+ .replace(/>/g,">");
+ }
+
</script>
<div id="mainBodyFixed" style="width:auto; margin:20px">
diff --git a/docs/html/videos/index.jd b/docs/html/videos/index.jd
index ddb9f86..4e53aac 100644
--- a/docs/html/videos/index.jd
+++ b/docs/html/videos/index.jd
@@ -37,12 +37,10 @@
* Each playlist ID is paired with a custom video description.
*/
var featured = {
-// Android 1.6 Release
- 'MBRFkLKRwFw' : "The Android 1.6 release includes new features and improvements to the Android platform. Here's an introduction to what's new in Android 1.6.",
+// Android 2.0 Release
+ 'opZ69P-0Jbc' : "The Android 2.0 platform adds exciting new user features and developer APIs. Here's an introduction to what's new.",
// How to Make your Android UI Fast..
'N6YdwzAvwOA' : "Make your user interface fast, with more efficient AdapterViews, better bitmap scaling, faster redrawing, ViewStub layouts, fewer Views, and more.",
-// Coding for Life: Battery Life
-// 'OUemfrKe65c' : "Learn what kinds of operations consume the most battery and how you can reduce your usage, with tips for parsing and zipping data, using wakelocks, and running a Service.",
// How Do I Code Thee?
'GARMe7Km_gk' : "If you'd like to augment your Android applications with pieces written in JavaScript or native code, watch this video."
};