You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by de...@apache.org on 2012/05/11 20:56:12 UTC
js commit: [CB-757] Add Media API for BlackBerry smartphones.
Updated Branches:
refs/heads/master 55e46cecd -> 1638f5213
[CB-757] Add Media API for BlackBerry smartphones.
Add custom override of MediaError since OS 6+ defines the object.
Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/commit/1638f521
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/tree/1638f521
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/diff/1638f521
Branch: refs/heads/master
Commit: 1638f5213bc9080abc80a1d0f081caf291639a86
Parents: 55e46ce
Author: Drew Walters <de...@gmail.com>
Authored: Fri May 11 13:55:06 2012 -0500
Committer: Drew Walters <de...@gmail.com>
Committed: Fri May 11 13:55:06 2012 -0500
----------------------------------------------------------------------
lib/blackberry/platform.js | 5 ++++-
lib/blackberry/plugin/blackberry/MediaError.js | 8 ++++++++
2 files changed, 12 insertions(+), 1 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/blob/1638f521/lib/blackberry/platform.js
----------------------------------------------------------------------
diff --git a/lib/blackberry/platform.js b/lib/blackberry/platform.js
index 895dc6f..4263f8f 100644
--- a/lib/blackberry/platform.js
+++ b/lib/blackberry/platform.js
@@ -174,6 +174,9 @@ module.exports = {
},
Entry: {
path: 'cordova/plugin/blackberry/Entry'
+ },
+ MediaError: { // Exists natively on BB OS 6+, merge in Cordova specifics
+ path: 'cordova/plugin/blackberry/MediaError'
}
}
-};
\ No newline at end of file
+};
http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/blob/1638f521/lib/blackberry/plugin/blackberry/MediaError.js
----------------------------------------------------------------------
diff --git a/lib/blackberry/plugin/blackberry/MediaError.js b/lib/blackberry/plugin/blackberry/MediaError.js
new file mode 100644
index 0000000..88d544e
--- /dev/null
+++ b/lib/blackberry/plugin/blackberry/MediaError.js
@@ -0,0 +1,8 @@
+
+// The MediaError object exists on BB OS 6+ which prevents the Cordova version
+// being defined. This object is used to merge in differences between the BB
+// MediaError object and the Cordova version.
+module.exports = {
+ MEDIA_ERR_NONE_ACTIVE : 0,
+ MEDIA_ERR_NONE_SUPPORTED : 4
+};
\ No newline at end of file