Bug 2822 - phonegap example : telephony preview support
authorEugene Ostroukhov <eugeneo@symbian.org>
Thu, 10 Jun 2010 17:58:18 -0700
changeset 371 8c790948988d
parent 370 fc90176b0859
child 372 1e408ee32d8a
Bug 2822 - phonegap example : telephony preview support
org.symbian.tools.wrttools.previewer/preview/script/lib/sapi/Messaging.js
org.symbian.tools.wrttools.previewer/preview/script/lib/widget.js
--- a/org.symbian.tools.wrttools.previewer/preview/script/lib/sapi/Messaging.js	Thu Jun 10 17:29:22 2010 -0700
+++ b/org.symbian.tools.wrttools.previewer/preview/script/lib/sapi/Messaging.js	Thu Jun 10 17:58:18 2010 -0700
@@ -121,7 +121,7 @@
 		if (typeof callback == 'function') {
 			return context.callAsync(this, arguments.callee, criteria, callback);
 		}
-		var message = _t('Sent %s message \"%s\" to %s').arg(criteria.MessageType, criteria.BodyText, criteria.To)
+		var message = _t('Sent %s message \"%s\" to %s').arg(criteria.MessageType, criteria.BodyText, criteria.To);
 		context.notify(message);
 		window.alert(message);
 
--- a/org.symbian.tools.wrttools.previewer/preview/script/lib/widget.js	Thu Jun 10 17:29:22 2010 -0700
+++ b/org.symbian.tools.wrttools.previewer/preview/script/lib/widget.js	Thu Jun 10 17:58:18 2010 -0700
@@ -51,6 +51,11 @@
 	 */
 	widget.openURL = function(url){
 		if (url) {
+			if (url.substring(0, 4) == "tel:") {
+				var sz = "Number " + url.substring(4) + " was dialed";
+				window.alert(sz);
+			}
+
 			window.open(url, "New Widget Window", 'height=200 width=250');
 		}
 	};