You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by an...@apache.org on 2012/12/10 23:55:58 UTC

git commit: updating JS and VERSION file

Updated Branches:
  refs/heads/master b987d4956 -> 4b1535565


updating JS and VERSION file


Project: http://git-wip-us.apache.org/repos/asf/cordova-tizen/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-tizen/commit/4b153556
Tree: http://git-wip-us.apache.org/repos/asf/cordova-tizen/tree/4b153556
Diff: http://git-wip-us.apache.org/repos/asf/cordova-tizen/diff/4b153556

Branch: refs/heads/master
Commit: 4b1535565227aa6823db279c267f0fa5f246e4c9
Parents: b987d49
Author: Anis Kadri <an...@gmail.com>
Authored: Mon Dec 10 14:55:47 2012 -0800
Committer: Anis Kadri <an...@gmail.com>
Committed: Mon Dec 10 14:55:47 2012 -0800

----------------------------------------------------------------------
 VERSION             |    2 +-
 js/cordova.tizen.js |   59 +++++++++++++++++++++++++++++++++++++--------
 2 files changed, 49 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-tizen/blob/4b153556/VERSION
----------------------------------------------------------------------
diff --git a/VERSION b/VERSION
index d2a7ed1..bcf7441 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.3.0rc1
+2.3.0rc2

http://git-wip-us.apache.org/repos/asf/cordova-tizen/blob/4b153556/js/cordova.tizen.js
----------------------------------------------------------------------
diff --git a/js/cordova.tizen.js b/js/cordova.tizen.js
index cae6c5d..f5ff389 100644
--- a/js/cordova.tizen.js
+++ b/js/cordova.tizen.js
@@ -1,6 +1,6 @@
-// commit 05bd1a469fd7964a7eb8363e55a949594afe9353
+// commit 861ff3d507fd5c64ed789d8abe360690e588252e
 
-// File generated at :: Mon Nov 26 2012 11:26:59 GMT-0800 (PST)
+// File generated at :: Mon Dec 10 2012 14:51:17 GMT-0800 (PST)
 
 /*
  Licensed to the Apache Software Foundation (ASF) under one
@@ -3105,18 +3105,55 @@ define("cordova/plugin/InAppBrowser", function(require, exports, module) {
 
 var exec = require('cordova/exec');
 
-var InAppBrowser = {
-    open : function(strUrl, strWindowName, strWindowFeatures) {
-        exec(null, null, "InAppBrowser", "open", [strUrl, strWindowName, strWindowFeatures]);
-        return InAppBrowser;
-    },
-    close : function() {
-        exec(null, null, "InAppBrowser", "close", []);
+function InAppBrowser()
+{
+   var _channel = require('cordova/channel');
+   this.channels = {
+        'loadstart': _channel.create('loadstart'),
+        'loadstop' : _channel.create('loadstop'),
+        'exit' : _channel.create('exit')
+   };
+}
+
+InAppBrowser.prototype._eventHandler = function(event)
+{
+    if (event.type in this.channels) {
+        this.channels[event.type].fire(event);
     }
-};
+}
+
+InAppBrowser.open = function(strUrl, strWindowName, strWindowFeatures)
+{
+    var iab = new InAppBrowser();
+    var cb = function(eventname) {
+       iab._eventHandler(eventname);
+    }
+    exec(cb, null, "InAppBrowser", "open", [strUrl, strWindowName, strWindowFeatures]);
+    return iab;
+}
+
+InAppBrowser.prototype.close = function(eventname, f)
+{
+    exec(null, null, "InAppBrowser", "close", []);
+}
+
+InAppBrowser.prototype.addEventListener = function(eventname, f)
+{
+    if (eventname in this.channels) {
+        this.channels[eventname].subscribe(f);
+    }
+}
+
+InAppBrowser.prototype.removeEventListener = function(eventname, f)
+{
+    if (eventname in this.channels) {
+        this.channels[eventname].unsubscribe(f);
+    }
+}
 
 module.exports = InAppBrowser.open;
 
+
 });
 
 // file: lib/common/plugin/LocalFileSystem.js
@@ -6442,7 +6479,7 @@ function Device() {
     this.version = null;
     this.uuid = null;
     this.name = null;
-    this.cordova = "2.3.0rc1";
+    this.cordova = "2.3.0rc2";
     this.platform = "Tizen";
 
     var me = this;