You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ag...@apache.org on 2014/07/07 20:08:16 UTC

[12/19] Move mobilespec into www/ so as to not include non-app files in the app

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/battery/index.js
----------------------------------------------------------------------
diff --git a/battery/index.js b/battery/index.js
deleted file mode 100644
index 1a0d488..0000000
--- a/battery/index.js
+++ /dev/null
@@ -1,72 +0,0 @@
-var deviceReady = false;
-
-/**
- * Function called when page has finished loading.
- */
-function init() {
-    document.addEventListener("deviceready", function() {
-            deviceReady = true;
-            console.log("Device="+device.platform+" "+device.version);
-        }, false);
-    window.setTimeout(function() {
-        if (!deviceReady) {
-            alert("Error: Apache Cordova did not initialize.  Demo will not run correctly.");
-        }
-    },1000);
-}
-
-/* Battery */
-function updateInfo(info) {
-    document.getElementById('level').innerText = info.level;
-    document.getElementById('isPlugged').innerText = info.isPlugged;
-    if (info.level > 5) {
-        document.getElementById('crit').innerText = "false";
-    }
-    if (info.level > 20) {
-        document.getElementById('low').innerText = "false";
-    }
-}
-
-function batteryLow(info) {
-    document.getElementById('low').innerText = "true";
-}
-
-function batteryCritical(info) {
-    document.getElementById('crit').innerText = "true";
-}
-
-function addBattery() {
-    window.addEventListener("batterystatus", updateInfo, false);
-}
-
-function removeBattery() {
-    window.removeEventListener("batterystatus", updateInfo, false);
-}
-
-function addLow() {
-    window.addEventListener("batterylow", batteryLow, false);
-}
-
-function removeLow() {
-    window.removeEventListener("batterylow", batteryLow, false);
-}
-
-function addCritical() {
-    window.addEventListener("batterycritical", batteryCritical, false);
-}
-
-function removeCritical() {
-    window.removeEventListener("batterycritical", batteryCritical, false);
-}
-
-window.onload = function() {
-  addListenerToClass('addBattery', addBattery);
-  addListenerToClass('removeBattery', removeBattery);
-  addListenerToClass('addLow', addLow);
-  addListenerToClass('removeLow', removeLow);
-  addListenerToClass('addCritical', addCritical);
-  addListenerToClass('removeCritical', removeCritical);
-  
-  addListenerToClass('backBtn', backHome);
-  init();
-}

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/beep.wav
----------------------------------------------------------------------
diff --git a/beep.wav b/beep.wav
deleted file mode 100644
index 05f5997..0000000
Binary files a/beep.wav and /dev/null differ

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/benchmarks/arraybuffer.html
----------------------------------------------------------------------
diff --git a/benchmarks/arraybuffer.html b/benchmarks/arraybuffer.html
deleted file mode 100644
index 5686f75..0000000
--- a/benchmarks/arraybuffer.html
+++ /dev/null
@@ -1,132 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>
-
-<script>
-    var exec = cordova.require('cordova/exec'),
-        deviceReady = false;
-
-    function appLog(message) {
-        if (window.console) {
-            console.log(message);
-        }
-        if (typeof message != 'string') {
-            message = JSON.stringify(message);
-        }
-        document.getElementById('app-logs').innerText += message + '\n';
-    }
-
-    function benchExec() {
-        var echo = cordova.echo,
-            startTime = +new Date,
-            callCount = 0,
-            durationMs = parseInt(document.getElementById('test-duration').value, 10) * 1000,
-            payloadSize = (+document.getElementById('payload-size').value),
-            payload = new ArrayBuffer(payloadSize);
-
-        var payloadView = new Uint8Array(payload);
-        for (var i=0; i<payloadView.length; i++) {
-            payloadView[i] = i;
-        }
-
-        function compareArrayBuffers(arr1, arr2) {
-            arr1 = new Uint8Array(arr1);
-            arr2 = new Uint8Array(arr2);
-            if (arr1.length != arr2.length)
-                return false;
-            for (var i = 0; i < arr1.length; ++i) {
-                if (arr1[i] != arr2[i]) {
-                    return false;
-                }
-            }
-            return true;
-        }
-
-        function win(result) {
-            callCount++;
-            if (!compareArrayBuffers(result, payload)) {
-                appLog('Wrong echo data!');
-                return;
-            }
-            var elapsedMs = new Date - startTime;
-            if (elapsedMs >= durationMs) {
-                var callsPerSecond = callCount * 1000 / elapsedMs;
-                appLog('Calls per second: ' + callsPerSecond);
-                return;
-            }
-            echoMessage();
-        }
-        function fail() {
-            appLog('Call failed!');
-        }
-        function echoMessage() {
-            setTimeout(function() {
-                echo(win, fail, payload);
-            });
-        }
-
-        appLog('Started exec benchmark with payload length: ' + payloadView.length);
-        echoMessage();
-        setTimeout(function() {
-            if (!callCount) {
-                alert('Echo plugin did not respond');
-            }
-        }, 500);
-    }
-
-    document.addEventListener("deviceready", function() {
-        deviceReady = true;
-        appLog("Device = " + device.platform + " " + device.version);
-    }, false);
-
-    window.onload = function() {
-        window.setTimeout(function() {
-            if (!deviceReady) {
-                alert("Error: Cordova did not initialize.  Demo will not run correctly.");
-            }
-        }, 1000);
-    };
-
-</script>
-
-  </head>
-  <body id="stage" class="theme">
-    <h1>ArrayBuffer Benchmark</h1>
-    <fieldset>
-        <legend>Settings</legend>
-        <label>Test Duration: <select id="test-duration"><option>1 Second</option><option>5 Seconds</option></select><br></label>
-        <label>Payload size (in bytes) <input id="payload-size" value="1024" style="width:100px"></label><br>
-        <button onclick="benchExec()">Benchmark exec</button><br>
-    </fieldset>
-    <h2>&nbsp</h2><a href="javascript:" class="backBtn" onclick="backHome();">Back</a><br>
-    <div>Results:</div>
-    <pre id="app-logs" style="white-space:pre-wrap;line-height:initial"></pre>
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/benchmarks/autobench.html
----------------------------------------------------------------------
diff --git a/benchmarks/autobench.html b/benchmarks/autobench.html
deleted file mode 100644
index 1a909fb..0000000
--- a/benchmarks/autobench.html
+++ /dev/null
@@ -1,194 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>      
-    <script type="text/javascript" charset="utf-8" src="uubench.js"></script>
-<script>
-    var exec = cordova.require('cordova/exec');
-    var temp, pers, LICENSE_CONTENTS;
-    function $(id) { return document.getElementById(id); }
-
-    function copy_license(filesystem, callback) {
-        filesystem.root.getFile("LICENSE", {create: true, exclusive: false}, function(entry) {
-            entry.createWriter(function(writer) {
-                writer.onwriteend = function(evt) {
-                    callback();
-                };
-                writer.write(LICENSE_CONTENTS);
-            }, function(err) {
-                alert('Error creating LICENSE FileWriter');
-            });
-        }, function(err) {
-            alert('Error copying LICENSE to a file system');
-        });
-    }
-
-    var suite = new uubench.Suite({
-        start:function() {
-            $('loading').innerHTML = "BENCHMARKING IN PROGRESS...";
-        },
-        result: function(name, stats) {
-            var secs = stats.elapsed/1000;
-            var itspersec = stats.iterations / secs;
-            $('table-results').innerHTML += '<tr><td>' + name + '</td><td>' + itspersec + ' per second.</td></tr>';
-            console.log(name + ' bench complete.');
-            results[name] = stats;
-        },
-        min: 2000, // each benchmark should run for at least 2000ms
-        done:function() { 
-            $('loading').innerHTML = "Benchmarks complete.";
-            $('backBtn').style.display="block";
-        }
-    });
-    var results = {};
-
-    document.addEventListener("deviceready", function() {
-        deviceReady = true;
-        var xhr = new XMLHttpRequest();
-        xhr.open("GET", "../LICENSE", true);
-        xhr.onreadystatechange = function() {
-            if (xhr.readyState == 4) {
-                if (xhr.responseText.length > 0) {
-                    LICENSE_CONTENTS = xhr.responseText;
-                } else {
-                    alert('Some prereq XHR stuff to get license content failed mang.');
-                }
-                window.requestFileSystem(LocalFileSystem.PERSISTENT, 0, function(p_fs) {
-                    pers = p_fs;
-                    copy_license(pers, function() {
-                        window.requestFileSystem(LocalFileSystem.TEMPORARY, 0, function(t_fs) {
-                            temp = t_fs;
-                            copy_license(temp, function() {
-                                setTimeout(bench, 250);
-                            });
-                        }, function(t_e) {
-                            alert('Failed to get TEMPORARY File System');
-                        });
-                    });
-                }, function(p_e) {
-                    alert('Failed to get PERSISTENT File System');
-                });
-            }
-        };
-        xhr.send(null);
-    });
-
-    window.onload = function() {
-        window.setTimeout(function() {
-            if (!deviceReady) {
-                alert("Error: Cordova did not initialize.  Demo will not run correctly.");
-            }
-        }, 1000);
-    };
-function bench() {
-    suite.bench("Echo exec callbacks", function(next) {
-        exec(function() {
-            // win
-            next();
-        }, function() {
-            // fail
-            next();
-        }, "Echo", "echo", ["test"]);
-    });
-    suite.bench("Echo exec invocations", function(next) {
-        exec(function() {
-            // win
-        }, function() {
-            // fail
-        }, "Echo", "echo", ["test"]);
-        next();
-    });
-    suite.bench("XHR to within-package 11kb asset.", function(next) {
-        var xhr = new XMLHttpRequest();
-        xhr.open("GET", "../LICENSE", true);
-        xhr.onreadystatechange = function() {
-            if (xhr.readyState == 4) {
-                // The result status is being compared to 0 for success instead of 200. This is because the file and ftp schemes do not use HTTP result codes.
-                if (xhr.status == 0 && xhr.responseText.length > 0) {
-                    next();
-                } else {
-                    alert('There was a problem during XHR file read!');
-                }
-            }
-        };
-        xhr.send(null);
-    });
-    if (temp) {
-        suite.bench("Get contents of 11kb asset located on TEMPORARY File System using FileReader's readAsText method.", function(next) {
-            temp.root.getFile("LICENSE", null, function(entry) {
-                entry.file(function(file) {
-                    var reader = new FileReader();
-                    reader.onloadend = function(evt) {
-                        next();
-                    };
-                    reader.readAsText(file);
-                }, function(err) {
-                    alert('Error getting File object from LICENSE file in TEMP FS.');
-                });
-            }, function(err) {
-                alert('Error getting LICENSE file from root of TEMP FS.');
-            });
-        });
-    }
-    if (pers) {
-        suite.bench("Get contents of 11kb asset located on PERSISTENT File System using FileReader's readAsText method.", function(next) {
-            pers.root.getFile("LICENSE", null, function(entry) {
-                entry.file(function(file) {
-                    var reader = new FileReader();
-                    reader.onloadend = function(evt) {
-                        next();
-                    };
-                    reader.readAsText(file);
-                }, function(err) {
-                    alert('Error getting File object from LICENSE file in PERSISTENT FS.');
-                });
-            }, function(err) {
-                alert('Error getting LICENSE file from root of PERSISTENT FS.');
-            });
-        });
-    }
-    suite.run();
-}
-</script>
-
-  </head>
-  <body id="stage" class="theme">
-    <h1>Auto-Benchmarks</h1>
-    <h2 id="loading"></h2>
-    <table>
-        <thead style="font-weight:bold;text-align:center;">
-            <tr>
-                <td>Name</td>
-                <td>Results</td>
-            </tr>
-        </thead>
-        <tbody id="table-results">
-        </tbody>
-    </table>
-    <h2>&nbsp</h2><a href="javascript:" class="backBtn" style="display:none" id='backBtn' onclick="backHome();">Back</a><br>
-  </body>
-</html>      

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/benchmarks/exec.html
----------------------------------------------------------------------
diff --git a/benchmarks/exec.html b/benchmarks/exec.html
deleted file mode 100644
index cd51ca4..0000000
--- a/benchmarks/exec.html
+++ /dev/null
@@ -1,239 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script src="../cordova-incl.js"></script>
-    <script src="setImmediate.js"></script>
-<script>
-    var exec = cordova.require('cordova/exec'),
-        appLogElem = null,
-        deviceReady = false,
-        inProgress = false;
-
-    function appLog(message) {
-        if (!appLogElem) {
-            appLogElem = document.getElementById('app-logs');
-        }
-        appLogElem.innerText += message + '\n';
-        if (window.console) {
-            console.log(message);
-        }
-    }
-
-    function clearLogs() {
-        appLogElem.innerHTML = '';
-    }
-
-    function updateUi(val) {
-        inProgress = val;
-        var goBtn = document.getElementById('go-btn');
-        goBtn.textContent = inProgress ? 'Stop' : 'Start';
-        cordova.echo.stopBulkEcho();
-    }
-
-    function createPayload(size, binary) {
-        if (!binary) {
-            return new Array(size * 10 + 1).join('012\n\n 6789');
-        }
-        size = size * 100;
-        var bufView = new Uint8Array(size);
-        for (var i = 0; i < size; ++i) {
-          bufView[i] = i % 20;
-        }
-        return bufView.buffer;
-    }
-
-    function benchExec() {
-        updateUi(!inProgress);
-        if (!inProgress) {
-            return;
-        }
-
-        var echo = cordova.echo,
-            startTime = +new Date,
-            callCount = 0,
-            elapsedMs,
-            lastReportMs = 0,
-            durationMs = parseInt(document.getElementById('test-duration').value, 10) * 1000,
-            asyncEcho = document.getElementById('async-echo').checked,
-            useSetTimeout = document.getElementById('use-setTimeout').checked,
-            bulkEcho = document.getElementById('bulk-echo').checked,
-            jsToNativeMode = document.getElementById('js-native-modes').value,
-            nativeToJsMode = document.getElementById('native-js-modes').value,
-            payloadSize = +document.getElementById('payload-size').value,
-            binaryPayload = document.getElementById('binary-payload').checked,
-            binaryAsyncEncode = document.getElementById('binary-async-encode').checked,
-            binaryAsyncDecode = document.getElementById('binary-async-decode').checked,
-            soFarEl = document.getElementById('so-far'),
-            payload = createPayload(payloadSize, binaryPayload);
-
-        cordova.ASYNC_AB_ENCODE = binaryAsyncEncode;
-        cordova.ASYNC_AB_DECODE = binaryAsyncDecode;
-
-        function reportProgress() {
-            var callsPerSecond = String(callCount * 1000 / elapsedMs).slice(0, 6);
-            soFarEl.textContent = callsPerSecond + ' ops';
-            appLog('Calls per second: ' + callsPerSecond);
-        }
-        function win(result) {
-            if (!inProgress) {
-                console.log('got an excess echo');
-                return;
-            }
-            callCount++;
-            if (result.length !== payload.length || result.byteLength !== payload.byteLength) {
-                appLog('Wrong echo data!');
-                updateUi(false);
-            }
-            elapsedMs = new Date - startTime;
-            if (inProgress && elapsedMs < durationMs) {
-                if (elapsedMs - lastReportMs > 1000) {
-                    reportProgress();
-                    lastReportMs = elapsedMs;
-                }
-                if (bulkEcho) {
-                    // automatically keeps coming.
-                } else if (useSetTimeout) {
-                    setImmediate(echoMessage);
-                } else {
-                    echoMessage();
-                }
-            } else {
-                reportProgress();
-                updateUi(false);
-            }
-        }
-        function fail() {
-            appLog('Call failed!');
-        }
-        function echoMessage() {
-            echo(win, fail, payload, asyncEcho);
-        }
-
-        var logMsg = 'Started exec benchmark with setImmediate: ' + useSetTimeout + ' asyncEcho: ' + asyncEcho + ' payload length: ' + payloadSize;
-        if (jsToNativeMode) {
-            exec.setJsToNativeBridgeMode(+jsToNativeMode);
-            logMsg += ' jsToNativeMode: ' + jsToNativeMode;
-        }
-        if (nativeToJsMode) {
-            exec.setNativeToJsBridgeMode(+nativeToJsMode);
-            logMsg += ' nativeToJsMode: ' + nativeToJsMode;
-        }
-        appLog(logMsg);
-        if (bulkEcho) {
-          echo.bulkEcho(payload, 50, win);
-        } else {
-          echoMessage();
-        }
-        setTimeout(function() {
-            if (!callCount) {
-                alert('Echo plugin did not respond');
-            }
-        }, 500);
-    }
-
-    function configureDragMe() {
-        var dragMeEl = document.getElementById('drag-me');
-        dragMeEl.ontouchmove = function(e) {
-            e.preventDefault();
-            var touch = e.touches[0];
-            dragMeEl.style.left = touch.pageX - 50 + 'px';
-            dragMeEl.style.top = touch.pageY - 50 + 'px';
-        }
-    }
-    function configure() {
-        function configureModes(elemId, modes) {
-            var selectElem = document.getElementById(elemId);
-            for (var modeName in modes) {
-                var optionElem = document.createElement('option');
-                optionElem.value = modes[modeName];
-                optionElem.innerText = modeName;
-                selectElem.appendChild(optionElem);
-            }
-            selectElem.parentNode.style.display = 'block';
-        }
-        if (exec.jsToNativeModes) {
-            configureModes('js-native-modes', exec.jsToNativeModes);
-        }
-        if (exec.nativeToJsModes) {
-            configureModes('native-js-modes', exec.nativeToJsModes);
-        }
-        configureDragMe();
-    }
-
-
-    document.addEventListener("deviceready", function() {
-        deviceReady = true;
-        appLog("Device="+device.platform+" "+device.version);
-        configure();
-    }, false);
-
-    window.onload = function() {
-        window.setTimeout(function() {
-            if (!deviceReady) {
-                alert("Error: Cordova did not initialize.  Demo will not run correctly.");
-            }
-        }, 1000);
-    };
-
-</script>
-
-  </head>
-  <body id="stage" class="theme">
-    <h1>exec() Benchmark</h1>
-    Before running on Android, set the following constants in NativeToJsMessagingBridge:
-    <ul>
-      <li>ENABLE_LOCATION_CHANGE_EXEC_MODE = true
-      <li>DISABLE_EXEC_CHAINING = true
-    </ul>
-    As of iOS 7.0.2, Andrew found that the iframe bridge is still the fastest on iOS.
-    <fieldset>
-        <legend>Settings</legend>
-        <label>Test Duration: <select id="test-duration"><option>1 Second</option><option>3 Seconds</option><option>10 seconds</option></select><br></label>
-        <label style="display:none">JS-&gt;Native Bridge Mode: <select id="js-native-modes"></select><br></label>
-        <label style="display:none">Native-&gt;JS Bridge Mode: <select id="native-js-modes"></select><br></label>
-        <label><input type="checkbox" id="use-setTimeout"> Force async JS-&gt;Native (avoids evalAndFetch optimization on iOS)</label><br>
-        <label><input type="checkbox" id="async-echo"> Force async Native-&gt;JS</label><br>
-        <label><input type="checkbox" id="bulk-echo"> Bulk Echo Mode (test only native-&gt;JS)</label><br>
-        <label><input type="checkbox" id="binary-payload"> Binary Payload</label><br>
-        These two require async_base64_android branch of cordova-js<br>
-        <label><input type="checkbox" id="binary-async-encode"> Use FileReader to encode binary</label><br>
-        <label><input type="checkbox" id="binary-async-decode"> Use XHR to decode binary</label><br>
-        <label>Payload size (in 100s of bytes) <input id="payload-size" value="5" style="width:100px"></label><br>
-        <button id="go-btn" onclick="benchExec()">Start</button><br>
-    </fieldset>
-    <div>some text.<br>
-        <div style="position:absolute;height:100px;background:red;width:100px;left:250px;top:50px;z-index:5" id="drag-me">Drag Me<div id="so-far"></div></div>
-        <input value="dummy input"> text box to see if focus is lost by bridge or if there is typing lag.
-    </div>
-    <h2>&nbsp</h2><a href="javascript:" class="backBtn" onclick="backHome();">Back</a><br>
-    <div>Results: <a href="javascript:clearLogs();">Clear</a></div>
-    <pre id="app-logs" style="white-space:pre-wrap;line-height:initial; margin-bottom:500px"></pre>
-    You've reached the bottom.
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/benchmarks/index.html
----------------------------------------------------------------------
diff --git a/benchmarks/index.html b/benchmarks/index.html
deleted file mode 100644
index a4d7419..0000000
--- a/benchmarks/index.html
+++ /dev/null
@@ -1,39 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script src="../cordova-incl.js"></script>
-  </head>
-  <body id="stage" class="theme">
-    <h1>Benchmarks</h1>
-    <a href="autobench.html" class="btn large">AutoBench</a>
-    <a href="arraybuffer.html" class="btn large">ArrayBuffer</a>
-    <a href="exec.html" class="btn large">Exec Bridge</a>
-    <h2> </h2><div class="backBtn" onclick="backHome();">Back</div>
-  </body>
-</html>      

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/benchmarks/setImmediate.js
----------------------------------------------------------------------
diff --git a/benchmarks/setImmediate.js b/benchmarks/setImmediate.js
deleted file mode 100644
index a36b814..0000000
--- a/benchmarks/setImmediate.js
+++ /dev/null
@@ -1,239 +0,0 @@
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-(function (global, undefined) {
-    "use strict";
-
-    var tasks = (function () {
-        function Task(handler, args) {
-            this.handler = handler;
-            this.args = args;
-        }
-        Task.prototype.run = function () {
-            // See steps in section 5 of the spec.
-            if (typeof this.handler === "function") {
-                // Choice of `thisArg` is not in the setImmediate spec; `undefined` is in the setTimeout spec though:
-                // http://www.whatwg.org/specs/web-apps/current-work/multipage/timers.html
-                this.handler.apply(undefined, this.args);
-            } else {
-                var scriptSource = "" + this.handler;
-                /*jshint evil: true */
-                eval(scriptSource);
-            }
-        };
-
-        var nextHandle = 1; // Spec says greater than zero
-        var tasksByHandle = {};
-        var currentlyRunningATask = false;
-
-        return {
-            addFromSetImmediateArguments: function (args) {
-                var handler = args[0];
-                var argsToHandle = Array.prototype.slice.call(args, 1);
-                var task = new Task(handler, argsToHandle);
-
-                var thisHandle = nextHandle++;
-                tasksByHandle[thisHandle] = task;
-                return thisHandle;
-            },
-            runIfPresent: function (handle) {
-                // From the spec: "Wait until any invocations of this algorithm started before this one have completed."
-                // So if we're currently running a task, we'll need to delay this invocation.
-                if (!currentlyRunningATask) {
-                    var task = tasksByHandle[handle];
-                    if (task) {
-                        currentlyRunningATask = true;
-                        try {
-                            task.run();
-                        } finally {
-                            delete tasksByHandle[handle];
-                            currentlyRunningATask = false;
-                        }
-                    }
-                } else {
-                    // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a
-                    // "too much recursion" error.
-                    global.setTimeout(function () {
-                        tasks.runIfPresent(handle);
-                    }, 0);
-                }
-            },
-            remove: function (handle) {
-                delete tasksByHandle[handle];
-            }
-        };
-    }());
-
-    function canUseNextTick() {
-        // Don't get fooled by e.g. browserify environments.
-        return typeof process === "object" &&
-               Object.prototype.toString.call(process) === "[object process]";
-    }
-
-    function canUseMessageChannel() {
-        return !!global.MessageChannel;
-    }
-
-    function canUsePostMessage() {
-        // The test against `importScripts` prevents this implementation from being installed inside a web worker,
-        // where `global.postMessage` means something completely different and can't be used for this purpose.
-
-        if (!global.postMessage || global.importScripts) {
-            return false;
-        }
-
-        var postMessageIsAsynchronous = true;
-        var oldOnMessage = global.onmessage;
-        global.onmessage = function () {
-            postMessageIsAsynchronous = false;
-        };
-        global.postMessage("", "*");
-        global.onmessage = oldOnMessage;
-
-        return postMessageIsAsynchronous;
-    }
-
-    function canUseReadyStateChange() {
-        return "document" in global && "onreadystatechange" in global.document.createElement("script");
-    }
-
-    function installNextTickImplementation(attachTo) {
-        attachTo.setImmediate = function () {
-            var handle = tasks.addFromSetImmediateArguments(arguments);
-
-            process.nextTick(function () {
-                tasks.runIfPresent(handle);
-            });
-
-            return handle;
-        };
-    }
-
-    function installMessageChannelImplementation(attachTo) {
-        var channel = new global.MessageChannel();
-        channel.port1.onmessage = function (event) {
-            var handle = event.data;
-            tasks.runIfPresent(handle);
-        };
-        attachTo.setImmediate = function () {
-            var handle = tasks.addFromSetImmediateArguments(arguments);
-
-            channel.port2.postMessage(handle);
-
-            return handle;
-        };
-    }
-
-    function installPostMessageImplementation(attachTo) {
-        // Installs an event handler on `global` for the `message` event: see
-        // * https://developer.mozilla.org/en/DOM/window.postMessage
-        // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages
-
-        var MESSAGE_PREFIX = "com.bn.NobleJS.setImmediate" + Math.random();
-
-        function isStringAndStartsWith(string, putativeStart) {
-            return typeof string === "string" && string.substring(0, putativeStart.length) === putativeStart;
-        }
-
-        function onGlobalMessage(event) {
-            // This will catch all incoming messages (even from other windows!), so we need to try reasonably hard to
-            // avoid letting anyone else trick us into firing off. We test the origin is still this window, and that a
-            // (randomly generated) unpredictable identifying prefix is present.
-            if (event.source === global && isStringAndStartsWith(event.data, MESSAGE_PREFIX)) {
-                var handle = event.data.substring(MESSAGE_PREFIX.length);
-                tasks.runIfPresent(handle);
-            }
-        }
-        if (global.addEventListener) {
-            global.addEventListener("message", onGlobalMessage, false);
-        } else {
-            global.attachEvent("onmessage", onGlobalMessage);
-        }
-
-        attachTo.setImmediate = function () {
-            var handle = tasks.addFromSetImmediateArguments(arguments);
-
-            // Make `global` post a message to itself with the handle and identifying prefix, thus asynchronously
-            // invoking our onGlobalMessage listener above.
-            global.postMessage(MESSAGE_PREFIX + handle, "*");
-
-            return handle;
-        };
-    }
-
-    function installReadyStateChangeImplementation(attachTo) {
-        attachTo.setImmediate = function () {
-            var handle = tasks.addFromSetImmediateArguments(arguments);
-
-            // Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted
-            // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called.
-            var scriptEl = global.document.createElement("script");
-            scriptEl.onreadystatechange = function () {
-                tasks.runIfPresent(handle);
-
-                scriptEl.onreadystatechange = null;
-                scriptEl.parentNode.removeChild(scriptEl);
-                scriptEl = null;
-            };
-            global.document.documentElement.appendChild(scriptEl);
-
-            return handle;
-        };
-    }
-
-    function installSetTimeoutImplementation(attachTo) {
-        attachTo.setImmediate = function () {
-            var handle = tasks.addFromSetImmediateArguments(arguments);
-
-            global.setTimeout(function () {
-                tasks.runIfPresent(handle);
-            }, 0);
-
-            return handle;
-        };
-    }
-
-    if (!global.setImmediate) {
-        // If supported, we should attach to the prototype of global, since that is where setTimeout et al. live.
-        var attachTo = typeof Object.getPrototypeOf === "function" && "setTimeout" in Object.getPrototypeOf(global) ?
-                          Object.getPrototypeOf(global)
-                        : global;
-
-        if (canUseNextTick()) {
-            // For Node.js before 0.9
-            installNextTickImplementation(attachTo);
-        } else if (canUsePostMessage()) {
-            // For non-IE10 modern browsers
-            installPostMessageImplementation(attachTo);
-        } else if (canUseMessageChannel()) {
-            // For web workers, where supported
-            installMessageChannelImplementation(attachTo);
-        } else if (canUseReadyStateChange()) {
-            // For IE 6–8
-            installReadyStateChangeImplementation(attachTo);
-        } else {
-            // For older browsers
-            installSetTimeoutImplementation(attachTo);
-        }
-
-        attachTo.clearImmediate = tasks.remove;
-    }
-}(typeof global === "object" && global ? global : this));

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/benchmarks/uubench.js
----------------------------------------------------------------------
diff --git a/benchmarks/uubench.js b/benchmarks/uubench.js
deleted file mode 100644
index 17c0c4d..0000000
--- a/benchmarks/uubench.js
+++ /dev/null
@@ -1,115 +0,0 @@
-//
-// uubench - Async Benchmarking v0.0.1
-// http://github.com/akdubya/uubench
-//
-// Copyright (c) 2010, Aleksander Williams
-// Released under the MIT License.
-//
-
-(function(uubench){
-
-function Bench(id, test, options, callback) {
-  this.id = id;
-  this.options = options;
-  this.test = test;
-  this.loop = test.length > 1;
-  this.callback = callback;
-}
-
-Bench.prototype.run = function(iter) {
-  var self = this, fn = self.test,
-      checkfn = self.options.type === "adaptive" ? adaptive : fixed,
-      i = iter, pend = i,
-      min = self.options.min, start;
-
-  if (self.loop) {
-    pend = 1;
-    start = new Date();
-    fn(checkfn, i);
-  } else {
-    start = new Date();
-    while (i--) {
-      fn(checkfn);
-    }
-  }
-
-  function fixed() {
-    if (--pend === 0) {
-      var elapsed = new Date() - start;
-      self.callback({iterations: iter, elapsed: elapsed});
-    }
-  }
-
-  function adaptive() {
-    if (--pend === 0) {
-      var elapsed = new Date() - start;
-      if (elapsed < min) {
-        self.run(iter*2);
-      } else {
-        self.callback({iterations: iter, elapsed: elapsed});
-      }
-    }
-  }
-}
-
-uubench.Bench = Bench;
-
-uubench.defaults = {
-  type:       "adaptive", // adaptive or fixed
-  iterations: 10,         // starting iterations
-  min:        100,        // minimum run time (ms) - adaptive only
-  delay:      100         // delay between tests (ms)
-}
-
-function Suite(opts) {
-  for (var key in uubench.defaults) {
-    if (opts[key] === undefined) {
-      opts[key] = uubench.defaults[key];
-    }
-  }
-  this.options = opts;
-  this.tests = [];
-}
-
-Suite.prototype.bench = function(name, fn) {
-  var self = this;
-  self.tests.push(new Bench(name, fn, this.options, function(stats) {
-    self.emit("result", name, stats);
-    self.pending--;
-    self.check();
-  }));
-}
-
-Suite.prototype.run = function() {
-  if (this.pending) return;
-  var self = this, len = self.tests.length;
-  self.emit("start", self.tests);
-  self.start = new Date().getTime();
-  self.pending = len;
-  for (var i=0; i<len; i++) {
-    self.runOne(i);
-  }
-}
-
-Suite.prototype.runOne = function(idx) {
-  var self = this;
-  setTimeout(function() {
-    self.tests[idx].run(self.options.iterations);
-  }, self.options.delay);
-}
-
-Suite.prototype.check = function() {
-  if (this.pending) return;
-  this.emit("done", new Date().getTime() - this.start);
-}
-
-Suite.prototype.emit = function(type) {
-  var event = this.options[type];
-  if (event) {
-    event.apply(this, Array.prototype.slice.call(arguments, 1));
-  }
-}
-
-uubench.Suite = Suite;
-
-})(typeof exports !== 'undefined' ? exports : window.uubench = {});

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/camera/index.html
----------------------------------------------------------------------
diff --git a/camera/index.html b/camera/index.html
deleted file mode 100644
index 4f48190..0000000
--- a/camera/index.html
+++ /dev/null
@@ -1,60 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>
-    <script type="text/javascript" charset="utf-8" src="./index.js"></script>      
-
-  </head>
-  <body id="stage" class="theme">
-
-    <h1>Camera</h1>
-    <div id="info" style="white-space: pre-wrap">
-        <b>Status:</b> <div id="camera_status"></div>
-        img: <img width="100" id="camera_image">
-        canvas: <canvas id="canvas" width="1" height="1"></canvas>
-    </div>
-    <h2>Cordova Camera API</h2>
-    <div id="image-options"></div>
-    <div class="btn large getPicture">camera.getPicture()</div>
-    <h2>Native File Inputs</h2>
-    <div>input type=file <input type="file" class="testInputTag"></div>
-    <div>capture=camera <input type="file" accept="image/*;capture=camera" class="testInputTag"></div>
-    <div>capture=camcorder <input type="file" accept="video/*;capture=camcorder" class="testInputTag"></div>
-    <div>capture=microphone <input type="file" accept="audio/*;capture=microphone" class="testInputTag"></div>
-    <h2>Actions</h2>
-    <div class="btn large getFileInfo">Get File Metadata</div>
-    <div class="btn large readFile">Read with FileReader</div>
-    <div class="btn large copyImage">Copy Image</div>
-    <div class="btn large writeImage">Write Image</div>
-    <div class="btn large uploadImage">Upload Image</div>
-    <div class="btn large displayImageUsingCanvas">Draw Using Canvas</div>
-    <div class="btn large removeImage">Remove Image</div>
-    <h2> </h2><div class="backBtn">Back</div>
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/camera/index.js
----------------------------------------------------------------------
diff --git a/camera/index.js b/camera/index.js
deleted file mode 100644
index f9435d0..0000000
--- a/camera/index.js
+++ /dev/null
@@ -1,344 +0,0 @@
-var deviceReady = false;
-var platformId = cordova.require('cordova/platform').id;
-var pictureUrl = null;
-var fileObj = null;
-var fileEntry = null;
-var pageStartTime = +new Date();
-
-//default camera options
-var camQualityDefault = ['quality value', 50];
-var camDestinationTypeDefault = ['FILE_URI', 1];
-var camPictureSourceTypeDefault = ['CAMERA', 1];
-var camAllowEditDefault = ['allowEdit', false];
-var camEncodingTypeDefault = ['JPEG', 0];
-var camMediaTypeDefault = ['mediaType', 0];
-var camCorrectOrientationDefault = ['correctOrientation', false];
-var camSaveToPhotoAlbumDefault = ['saveToPhotoAlbum', true];
-
-
-//-------------------------------------------------------------------------
-// Camera
-//-------------------------------------------------------------------------
-
-function log(value) {
-    console.log(value);
-    document.getElementById('camera_status').textContent += (new Date() - pageStartTime) / 1000 + ': ' + value + '\n';
-}
-
-function clearStatus() {
-    document.getElementById('camera_status').innerHTML = '';
-    document.getElementById('camera_image').src = 'about:blank';
-    var canvas = document.getElementById('canvas');
-    canvas.width = canvas.height = 1;
-    pictureUrl = null;
-    fileObj = null;
-    fileEntry = null;
-}
-
-function setPicture(url, callback) {
-try {
-  window.atob(url);
-  // if we got here it is a base64 string (DATA_URL)
-  url = "data:image/jpeg;base64," + url;
-} catch (e) {
-  // not DATA_URL
-    log('URL: ' + url.slice(0, 100));
-}    
-
-    pictureUrl = url;
-    var img = document.getElementById('camera_image');
-    var startTime = new Date();
-    img.src = url;
-    img.onloadend = function() {
-        log('Image tag load time: ' + (new Date() - startTime));
-        callback && callback();
-    };
-}
-
-function onGetPictureError(e) {
-    log('Error getting picture: ' + e.code);
-}
-
-function getPictureWin(data) {
-    setPicture(data);
-    // TODO: Fix resolveLocalFileSystemURI to work with native-uri.
-    if (pictureUrl.indexOf('file:') == 0 || pictureUrl.indexOf('content:') == 0) {
-        resolveLocalFileSystemURI(data, function(e) {
-            fileEntry = e;
-            logCallback('resolveLocalFileSystemURI()', true)(e.toURL());
-        }, logCallback('resolveLocalFileSystemURI()', false));
-    } else if (pictureUrl.indexOf('data:image/jpeg;base64' == 0)) {
-      // do nothing
-    } else {
-        var path = pictureUrl.replace(/^file:\/\/(localhost)?/, '').replace(/%20/g, ' ');
-        fileEntry = new FileEntry('image_name.png', path);
-    }
-}
-
-function getPicture() {
-    clearStatus();
-    var options = extractOptions();
-    log('Getting picture with options: ' + JSON.stringify(options));
-    var popoverHandle = navigator.camera.getPicture(getPictureWin, onGetPictureError, options);
-
-    // Reposition the popover if the orientation changes.
-    window.onorientationchange = function() {
-        var newPopoverOptions = new CameraPopoverOptions(0, 0, 100, 100, 0);
-        popoverHandle.setPosition(newPopoverOptions);
-    }
-}
-
-function uploadImage() {
-    var ft = new FileTransfer(),
-        uploadcomplete=0,
-        progress = 0,
-        options = new FileUploadOptions();
-    options.fileKey="photo";
-    options.fileName='test.jpg';
-    options.mimeType="image/jpeg";
-    ft.onprogress = function(progressEvent) {
-        log('progress: ' + progressEvent.loaded + ' of ' + progressEvent.total);
-    };
-    var server = "http://cordova-filetransfer.jitsu.com";
-
-    ft.upload(pictureUrl, server + '/upload', win, fail, options);
-    function win(information_back){
-        log('upload complete');
-    }
-    function fail(message) {
-        log('upload failed: ' + JSON.stringify(message));
-    }
-}
-
-function logCallback(apiName, success) {
-    return function() {
-        log('Call to ' + apiName + (success ? ' success: ' : ' failed: ') + JSON.stringify([].slice.call(arguments)));
-    };
-}
-
-/**
- * Select image from library using a NATIVE_URI destination type
- * This calls FileEntry.getMetadata, FileEntry.setMetadata, FileEntry.getParent, FileEntry.file, and FileReader.readAsDataURL.
- */
-function readFile() {
-    function onFileReadAsDataURL(evt) {
-        var img = document.getElementById('camera_image');
-        img.style.visibility = "visible";
-        img.style.display = "block";
-        img.src = evt.target.result;
-        log("FileReader.readAsDataURL success");
-    };
-
-    function onFileReceived(file) {
-        log('Got file: ' + JSON.stringify(file));
-        fileObj = file;
-
-        var reader = new FileReader();
-        reader.onload = function() {
-            log('FileReader.readAsDataURL() - length = ' + reader.result.length);
-        };
-        reader.onerror = logCallback('FileReader.readAsDataURL', false);
-        reader.readAsDataURL(file);
-    };
-    // Test out onFileReceived when the file object was set via a native <input> elements.
-    if (fileObj) {
-        onFileReceived(fileObj);
-    } else {
-        fileEntry.file(onFileReceived, logCallback('FileEntry.file', false));
-    }
-}
-function getFileInfo() {
-    // Test FileEntry API here.
-    fileEntry.getMetadata(logCallback('FileEntry.getMetadata', true), logCallback('FileEntry.getMetadata', false));
-    fileEntry.setMetadata(logCallback('FileEntry.setMetadata', true), logCallback('FileEntry.setMetadata', false), { "com.apple.MobileBackup": 1 });
-    fileEntry.getParent(logCallback('FileEntry.getParent', true), logCallback('FileEntry.getParent', false));
-    fileEntry.getParent(logCallback('FileEntry.getParent', true), logCallback('FileEntry.getParent', false));
-};
-
-/**
- * Copy image from library using a NATIVE_URI destination type
- * This calls FileEntry.copyTo and FileEntry.moveTo.
- */
-function copyImage() {
-    var onFileSystemReceived = function(fileSystem) {
-        var destDirEntry = fileSystem.root;
-
-        // Test FileEntry API here.
-        fileEntry.copyTo(destDirEntry, 'copied_file.png', logCallback('FileEntry.copyTo', true), logCallback('FileEntry.copyTo', false));
-        fileEntry.moveTo(destDirEntry, 'moved_file.png', logCallback('FileEntry.moveTo', true), logCallback('FileEntry.moveTo', false));
-    };
-
-    window.requestFileSystem(LocalFileSystem.TEMPORARY, 0, onFileSystemReceived, null);
-};
-
-/**
- * Write image to library using a NATIVE_URI destination type
- * This calls FileEntry.createWriter, FileWriter.write, and FileWriter.truncate.
- */
-function writeImage() {
-    var onFileWriterReceived = function(fileWriter) {
-        fileWriter.onwrite = logCallback('FileWriter.write', true);
-        fileWriter.onerror = logCallback('FileWriter.write', false);
-        fileWriter.write("some text!");
-    };
-
-    var onFileTruncateWriterReceived = function(fileWriter) {
-        fileWriter.onwrite = logCallback('FileWriter.truncate', true);
-        fileWriter.onerror = logCallback('FileWriter.truncate', false);
-        fileWriter.truncate(10);
-    };
-
-    fileEntry.createWriter(onFileWriterReceived, logCallback('FileEntry.createWriter', false));
-    fileEntry.createWriter(onFileTruncateWriterReceived, null);
-};
-
-function displayImageUsingCanvas() {
-    var canvas = document.getElementById('canvas');
-    var img = document.getElementById('camera_image');
-    var w = img.width;
-    var h = img.height;
-    h = 100 / w * h;
-    w = 100;
-    canvas.width = w;
-    canvas.height= h;
-    var context = canvas.getContext('2d');
-    context.drawImage(img, 0, 0, w, h);
-};
-
-/**
- * Remove image from library using a NATIVE_URI destination type
- * This calls FileEntry.remove.
- */
-function removeImage() {
-    fileEntry.remove(logCallback('FileEntry.remove', true), logCallback('FileEntry.remove', false));
-};
-
-function testInputTag(inputEl) {
-    clearStatus();
-    // iOS 6 likes to dead-lock in the onchange context if you
-    // do any alerts or try to remote-debug.
-    window.setTimeout(function() {
-        testNativeFile2(inputEl);
-    }, 0);
-};
-
-function testNativeFile2(inputEl) {
-    if (!inputEl.value) {
-        alert('No file selected.');
-        return;
-    }
-    fileObj = inputEl.files[0];
-    if (!fileObj) {
-        alert('Got value but no file.');
-        return;
-    }
-    var URLApi = window.URL || window.webkitURL;
-    if (URLApi) {
-        var blobURL = URLApi.createObjectURL(fileObj);
-        if (blobURL) {
-            setPicture(blobURL, function() {
-                URLApi.revokeObjectURL(blobURL);
-            });
-        } else {
-            log('URL.createObjectURL returned null');
-        }
-    } else {
-        log('URL.createObjectURL() not supported.');
-    }
-}
-
-function extractOptions() {
-    var els = document.querySelectorAll('#image-options select');
-    var ret = {};
-    for (var i = 0, el; el = els[i]; ++i) {
-        var value = el.value;
-        if (value === '') continue;
-        if (el.isBool) {
-            ret[el.keyName] = !!+value;
-        } else {
-            ret[el.keyName] = +value;
-        }
-    }
-    return ret;
-}
-
-function createOptionsEl(name, values, selectionDefault) {
-    var container = document.createElement('div');
-    container.style.display = 'inline-block';
-    container.appendChild(document.createTextNode(name + ': '));
-    var select = document.createElement('select');
-    select.keyName = name;
-    container.appendChild(select);
-    
-    // if we didn't get a default value, insert the blank <default> entry
-    if (selectionDefault == undefined) {
-        var opt = document.createElement('option');
-        opt.value = '';
-        opt.text = '<default>';
-        select.appendChild(opt);
-    }
-    
-    select.isBool = typeof values == 'boolean';
-    if (select.isBool) {
-        values = {'true': 1, 'false': 0};
-    }
-    
-    for (var k in values) {
-        var opt = document.createElement('option');
-        opt.value = values[k];
-        opt.textContent = k;
-        if (selectionDefault) {
-            if (selectionDefault[0] == k) {
-                opt.selected = true;
-            }
-        }
-        select.appendChild(opt);
-    }
-    var optionsDiv = document.getElementById('image-options');
-    optionsDiv.appendChild(container);
-}
-
-/**
- * Function called when page has finished loading.
- */
-function init() {
-    document.addEventListener("deviceready", function() {
-        deviceReady = true;
-        console.log("Device="+device.platform+" "+device.version);
-        createOptionsEl('sourceType', Camera.PictureSourceType, camPictureSourceTypeDefault);
-        createOptionsEl('destinationType', Camera.DestinationType, camDestinationTypeDefault);
-        createOptionsEl('encodingType', Camera.EncodingType, camEncodingTypeDefault);
-        createOptionsEl('mediaType', Camera.MediaType, camMediaTypeDefault);
-        createOptionsEl('quality', {'0': 0, '50': 50, '80': 80, '100': 100}, camQualityDefault);
-        createOptionsEl('targetWidth', {'50': 50, '200': 200, '800': 800, '2048': 2048});
-        createOptionsEl('targetHeight', {'50': 50, '200': 200, '800': 800, '2048': 2048});
-        createOptionsEl('allowEdit', true, camAllowEditDefault);
-        createOptionsEl('correctOrientation', true, camCorrectOrientationDefault);
-        createOptionsEl('saveToPhotoAlbum', true, camSaveToPhotoAlbumDefault);
-        createOptionsEl('cameraDirection', Camera.Direction);
-                      
-    }, false);
-    window.setTimeout(function() {
-        if (!deviceReady) {
-            alert("Error: Apache Cordova did not initialize.  Demo will not run correctly.");
-        }
-    },1000);
-};
-
-window.onload = function() {
-  addListenerToClass('getPicture', getPicture);
-  addListenerToClass('testInputTag', function(e) {
-    testInputTag(e.target);
-  }, null, 'change', true);
-  addListenerToClass('getFileInfo', getFileInfo);
-  addListenerToClass('readFile', readFile);
-  addListenerToClass('copyImage', copyImage);
-  addListenerToClass('writeImage', writeImage);
-  addListenerToClass('uploadImage', uploadImage);
-  addListenerToClass('displayImageUsingCanvas', displayImageUsingCanvas);
-  addListenerToClass('removeImage', removeImage);
-
-  addListenerToClass('backBtn', backHome);
-  init();
-}
-

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/capture/index.html
----------------------------------------------------------------------
diff --git a/capture/index.html b/capture/index.html
deleted file mode 100644
index 9543341..0000000
--- a/capture/index.html
+++ /dev/null
@@ -1,52 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>
-    <script type="text/javascript" charset="utf-8" src="./index.js"></script>      
-  </head>
-  <body id="stage" class="theme">
-
-    <h1>Capture</h1>
-    <div id="info" style="white-space: pre-wrap">
-        <b>Status:</b> <div id="camera_status"></div>
-        img: <img width="100" id="camera_image">
-        video: <div id="video_container"></div>
-    </div>
-    
-    <h2>Cordova Capture API</h2>
-    <div id="image-options"></div>
-
-    <h2>Actions</h2>
-    <div class="btn large getAudio">Capture 10 secs of audio and play</div>
-    <div class="btn large getImage">Capture 1 image</div>
-    <div class="btn large getVideo">Capture 10 secs of video</div>
-    <div class="btn large resolveVideo">Capture 5 secs of video and resolve</div>
-    <h2> </h2><div class="backBtn">Back</div>
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/capture/index.js
----------------------------------------------------------------------
diff --git a/capture/index.js b/capture/index.js
deleted file mode 100644
index 0f98549..0000000
--- a/capture/index.js
+++ /dev/null
@@ -1,137 +0,0 @@
-var deviceReady = false;
-var platformId = cordova.require('cordova/platform').id;
-var pageStartTime = +new Date();
-
-//-------------------------------------------------------------------------
-// Camera
-//-------------------------------------------------------------------------
-
-function log(value) {
-    console.log(value);
-    document.getElementById('camera_status').textContent += (new Date() - pageStartTime) / 1000 + ': ' + value + '\n';
-}
-
-function captureAudioWin(mediaFiles){
-    var path = mediaFiles[0].fullPath;
-    log('Audio captured: ' + path);
-    var m = new Media(path);
-    m.play(); 
-}
-
-function captureAudioFail(e){
-    log('Error getting audio: ' + e.code);
-}
-
-function getAudio(){
-    clearStatus();
-    var options = { limit: 1, duration: 10};
-    navigator.device.capture.captureAudio(captureAudioWin, captureAudioFail, options);
-}
-
-function captureImageWin(mediaFiles){
-    var path = mediaFiles[0].fullPath;
-    log('Image captured: ' + path);    
-    document.getElementById('camera_image').src = path;    
-}
-
-function captureImageFail(e){
-    log('Error getting image: ' + e.code);
-}
-
-function getImage(){
-    clearStatus();
-    var options = { limit: 1 };
-    navigator.device.capture.captureImage(captureImageWin, captureImageFail, options);    
-}    
-
-function captureVideoWin(mediaFiles){
-    var path = mediaFiles[0].fullPath;
-    log('Video captured: ' + path);
-    
-    // need to inject the video element into the html
-    // doesn't seem to work if you have a pre-existing video element and
-    // add in a source tag
-    var vid = document.createElement('video');
-    vid.id="theVideo";
-    vid.width = "320";
-    vid.height= "240";
-    vid.controls = "true";
-    var source_vid = document.createElement('source');
-    source_vid.id = "theSource";
-    source_vid.src = path;
-    vid.appendChild(source_vid);
-    document.getElementById('video_container').appendChild(vid);    
-}
-
-function captureVideoFail(e){
-    log('Error getting video: ' + e.code);
-}
-
-function getVideo(){
-    clearStatus();
-    var options = { limit: 1, duration: 10 };
-    navigator.device.capture.captureVideo(captureVideoWin, captureVideoFail, options);      
-}
-
-function resolveMediaFileURL(mediaFile, callback) {
-    resolveLocalFileSystemURL(mediaFile.localURL, function(entry) {
-        log("Resolved by URL: " + mediaFile.localURL);
-        if (callback) callback();
-    }, function(err) {
-        log("Failed to resolve by URL: " + mediaFile.localURL);
-        log("Error: " + JSON.stringify(err));
-        if (callback) callback();
-    });
-}
-
-function resolveMediaFile(mediaFile, callback) {
-    resolveLocalFileSystemURL(mediaFile.fullPath, function(entry) {
-        log("Resolved by path: " + mediaFile.fullPath);
-        if (callback) callback();
-    }, function(err) {
-        log("Failed to resolve by path: " + mediaFile.fullPath);
-        log("Error: " + JSON.stringify(err));
-        if (callback) callback();
-    });
-}
-    
-function resolveVideo() {
-    clearStatus();
-    var options = { limit: 1, duration: 5 };
-    navigator.device.capture.captureVideo(function(mediaFiles) {
-        captureVideoWin(mediaFiles);
-        resolveMediaFile(mediaFiles[0], function() {
-            resolveMediaFileURL(mediaFiles[0]);
-        });
-    }, captureVideoFail, options);      
-}
-
-function clearStatus() {
-    document.getElementById('camera_status').innerHTML = '';
-    document.getElementById('camera_image').src = 'about:blank';
-}
-
-/**
- * Function called when page has finished loading.
- */
-function init() {
-    document.addEventListener("deviceready", function() {
-        deviceReady = true;
-        console.log("Device="+device.platform+" "+device.version);
-    }, false);
-    window.setTimeout(function() {
-        if (!deviceReady) {
-            alert("Error: Apache Cordova did not initialize.  Demo will not run correctly.");
-        }
-    },1000);
-};
-
-
-window.onload = function() {
-  addListenerToClass('getAudio', getAudio);
-  addListenerToClass('getImage', getImage);
-  addListenerToClass('getVideo', getVideo);
-  addListenerToClass('resolveVideo', resolveVideo);
-  addListenerToClass('backBtn', backHome);
-  init();
-}

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/compass/index.html
----------------------------------------------------------------------
diff --git a/compass/index.html b/compass/index.html
deleted file mode 100644
index 1734caa..0000000
--- a/compass/index.html
+++ /dev/null
@@ -1,48 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>      
-    <script type="text/javascript" charset="utf-8" src="./index.js"></script>      
-  </head>
-  <body id="stage" class="theme">
-  
-    <h1>Compass</h1>
-    <div id="info">
-        <b>Status:</b> <span id="compass_status">Stopped</span>
-        <table width="100%"><tr>
-            <td width="33%">Heading: <span id="compassHeading"> </span></td>
-        </tr></table>
-    </div>
-    <h2>Action</h2>
-    <div class="btn large getCompass">Get Compass</div>
-    <div class="btn large watchCompass">Start Watching Compass</div>
-    <div class="btn large stopCompass">Stop Watching Compass</div>
-    <h2> </h2><div class="backBtn">Back</div>
-  </body>
-</html>      

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/compass/index.js
----------------------------------------------------------------------
diff --git a/compass/index.js b/compass/index.js
deleted file mode 100644
index 0735ab2..0000000
--- a/compass/index.js
+++ /dev/null
@@ -1,104 +0,0 @@
-var deviceReady = false;
-
-function roundNumber(num) {
-    var dec = 3;
-    var result = Math.round(num*Math.pow(10,dec))/Math.pow(10,dec);
-    return result;
-}
-
-//-------------------------------------------------------------------------
-// Compass
-//-------------------------------------------------------------------------
-var watchCompassId = null;
-
-/**
- * Start watching compass
- */
-var watchCompass = function() {
-    console.log("watchCompass()");
-
-    // Success callback
-    var success = function(a){
-        document.getElementById('compassHeading').innerHTML = roundNumber(a.magneticHeading);
-    };
-
-    // Fail callback
-    var fail = function(e){
-        console.log("watchCompass fail callback with error code "+e);
-        stopCompass();
-        setCompassStatus(e);
-    };
-
-    // Update heading every 1 sec
-    var opt = {};
-    opt.frequency = 1000;
-    watchCompassId = navigator.compass.watchHeading(success, fail, opt);
-
-    setCompassStatus("Running");
-};
-
-/**
- * Stop watching the acceleration
- */
-var stopCompass = function() {
-    setCompassStatus("Stopped");
-    if (watchCompassId) {
-        navigator.compass.clearWatch(watchCompassId);
-        watchCompassId = null;
-    }
-};
-
-/**
- * Get current compass
- */
-var getCompass = function() {
-    console.log("getCompass()");
-
-    // Stop compass if running
-    stopCompass();
-
-    // Success callback
-    var success = function(a){
-        document.getElementById('compassHeading').innerHTML = roundNumber(a.magneticHeading);
-    };
-
-    // Fail callback
-    var fail = function(e){
-        console.log("getCompass fail callback with error code "+e);
-        setCompassStatus(e);
-    };
-
-    // Make call
-    var opt = {};
-    navigator.compass.getCurrentHeading(success, fail, opt);
-};
-
-/**
- * Set compass status
- */
-var setCompassStatus = function(status) {
-    document.getElementById('compass_status').innerHTML = status;
-};
-
-/**
- * Function called when page has finished loading.
- */
-function init() {
-    document.addEventListener("deviceready", function() {
-            deviceReady = true;
-            console.log("Device="+device.platform+" "+device.version);
-        }, false);
-    window.setTimeout(function() {
-      if (!deviceReady) {
-        alert("Error: Apache Cordova did not initialize.  Demo will not run correctly.");
-      }
-    },1000);
-}
-
-window.onload = function() {
-  addListenerToClass('getCompass', getCompass);
-  addListenerToClass('watchCompass', watchCompass);
-  addListenerToClass('stopCompass', stopCompass);
-  addListenerToClass('backBtn', backHome);
-  init();
-}

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/contacts/index.html
----------------------------------------------------------------------
diff --git a/contacts/index.html b/contacts/index.html
deleted file mode 100644
index 5782713..0000000
--- a/contacts/index.html
+++ /dev/null
@@ -1,47 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>      
-    <script type="text/javascript" charset="utf-8" src="./index.js"></script>      
-
-  </head>
-  <body id="stage" class="theme">
-  
-    <h1>Contacts</h1>    
-    <div id="info">
-        <b>Results:</b><br>
-        <span id="contacts_results"> </span>
-    </div>
-    <h2>Action</h2>
-
-    <div class="btn large getContacts">Get phone's contacts</div>
-    <div class="btn large addContact">Add a new contact 'Dooney Evans'</div>
-    <h2> </h2><div class="backBtn">Back</div>
-  </body>
-</html>      

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/contacts/index.js
----------------------------------------------------------------------
diff --git a/contacts/index.js b/contacts/index.js
deleted file mode 100644
index d3f3312..0000000
--- a/contacts/index.js
+++ /dev/null
@@ -1,90 +0,0 @@
-var deviceReady = false;
-
-//-------------------------------------------------------------------------
-// Contacts
-//-------------------------------------------------------------------------
-function getContacts() {
-    obj = new ContactFindOptions();
-    // show all contacts, so don't filter
-    obj.multiple = true;
-    navigator.contacts.find(
-        ["displayName", "name", "phoneNumbers", "emails", "urls", "note"],
-        function(contacts) {
-            var s = "";
-            if (contacts.length == 0) {
-                s = "No contacts found";
-            }
-            else {
-                s = "Number of contacts: "+contacts.length+"<br><table width='100%'><tr><th>Name</th><td>Phone</td><td>Email</td></tr>";
-                for (var i=0; i<contacts.length; i++) {
-                    var contact = contacts[i];
-                    s = s + "<tr><td>" + contact.name.formatted + "</td><td>";
-                    if (contact.phoneNumbers && contact.phoneNumbers.length > 0) {
-                        s = s + contact.phoneNumbers[0].value;
-                    }
-                    s = s + "</td><td>"
-                    if (contact.emails && contact.emails.length > 0) {
-                        s = s + contact.emails[0].value;
-                    }
-                    s = s + "</td></tr>";
-                }
-                s = s + "</table>";
-            }
-            document.getElementById('contacts_results').innerHTML = s;
-        },
-        function(e) {
-            document.getElementById('contacts_results').innerHTML = "Error: "+e.code;
-        },
-        obj);
-};
-
-function addContact(){
-    try{
-        var contact = navigator.contacts.create({"displayName": "Dooney Evans"});
-        var contactName = {
-            formatted: "Dooney Evans",
-            familyName: "Evans",
-            givenName: "Dooney",
-            middleName: ""
-        };
-
-        contact.name = contactName;
-
-        var phoneNumbers = [1];
-        phoneNumbers[0] = new ContactField('work', '512-555-1234', true);
-        contact.phoneNumbers = phoneNumbers;
-
-        contact.save(
-            function() { alert("Contact saved.");},
-            function(e) { alert("Contact save failed: " + e.code); }
-        );
-        console.log("you have saved the contact");
-    }
-    catch (e){
-        alert(e);
-    }
-
-};
-
-/**
- * Function called when page has finished loading.
- */
-function init() {
-    document.addEventListener("deviceready", function() {
-            deviceReady = true;
-            console.log("Device="+device.platform+" "+device.version);
-        }, false);
-    window.setTimeout(function() {
-      if (!deviceReady) {
-        alert("Error: Apache Cordova did not initialize.  Demo will not run correctly.");
-      }
-    },1000);
-}
-
-
-window.onload = function() {
-  addListenerToClass('getContacts', getContacts);
-  addListenerToClass('addContact', addContact);
-  addListenerToClass('backBtn', backHome);
-  init();
-}

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/cordova-incl.js
----------------------------------------------------------------------
diff --git a/cordova-incl.js b/cordova-incl.js
deleted file mode 100644
index 713dc1b..0000000
--- a/cordova-incl.js
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- *
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- *
-*/
-
-var PLAT;
-(function getPlatform() {
-    var platforms = {
-        amazon_fireos: /cordova-amazon-fireos/,
-        android: /Android/,
-        ios: /(iPad)|(iPhone)|(iPod)/,
-        blackberry10: /(BB10)/,
-        blackberry: /(PlayBook)|(BlackBerry)/,
-        windows8: /MSAppHost/,
-        windowsphone: /Windows Phone/,
-        firefoxos: /Firefox/
-    };
-    for (var key in platforms) {
-        if (platforms[key].exec(navigator.userAgent)) {
-            PLAT = key;
-            break;
-        }
-    }
-})();
-
-var scripts = document.getElementsByTagName('script');
-var currentPath = scripts[scripts.length - 1].src;
-if (PLAT !== "blackberry10" && PLAT !== "firefoxos" && PLAT !== 'windowsphone') {
-    currentPath += '?paramShouldBeIgnored';
-}
-var cordovaPath = currentPath.replace("cordova-incl.js", "cordova.js");
-
-if (!window._doNotWriteCordovaScript) {
-    if (PLAT != "windows8") {
-        document.write('<script type="text/javascript" charset="utf-8" src="' + cordovaPath + '"></script>');
-    } else {
-        var s = document.createElement('script');
-        s.src = cordovaPath;
-        document.head.appendChild(s);
-    }
-}
-
-function addListenerToClass(className, listener, argsArray, action, doNotWrap) {
-    if (!action) {
-      action='click';
-    }
-    var elements = document.getElementsByClassName(className);
-    // choose Event target as a scope (like inline scripts)
-    if (!doNotWrap) {
-      if (argsArray && !Array.isArray(argsArray)) {
-        argsArray = [argsArray];
-      }
-      function callListener(e) {
-        listener.apply(null, argsArray);
-      }
-    } else {
-      callListener = listener;
-    }
-    for (var i = 0; i < elements.length; ++i) {
-      var item = elements[i];  
-      item.addEventListener(action, callListener, false);
-    }
-};
-
-function backHome() {
-    if (window.device && device.platform && (device.platform.toLowerCase() == 'android' || device.platform.toLowerCase() == 'amazon-fireos')) {
-        navigator.app.backHistory();
-    }
-    else {
-        window.history.go(-1);
-    }
-}

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/createmobilespec/createmobilespec.js
----------------------------------------------------------------------
diff --git a/createmobilespec/createmobilespec.js b/createmobilespec/createmobilespec.js
index 7572852..244c300 100755
--- a/createmobilespec/createmobilespec.js
+++ b/createmobilespec/createmobilespec.js
@@ -43,12 +43,14 @@ var top_dir =             process.cwd() + path.sep,
     cordova_js_git_dir =  path.join(top_dir, "cordova-js"),
     platforms =           [],
     // where to find the /bin/create command and www dir in a non-CLI project
-    platform_layout =     { "android":      { "bin": "cordova-android", 
-                                              "www": "assets" + path.sep + "www" },
+    platform_layout =     { "android":      { "bin": "cordova-android",
+                                              "www": "assets" + path.sep + "www",
+                                              "config": "res" + path.sep + "xml" },
                             "blackberry10": { "bin": "cordova-blackberry" + path.sep + "blackberry10",
                                               "www": "www" },
                             "ios":          { "bin": "cordova-ios",
-                                              "www": "www" },
+                                              "www": "www",
+                                              "config": "CUSTOM" },
                             "windows8":     { "bin": "cordova-windows" + path.sep + "windows8",
                                               "www": "www" },
                             "wp8":          { "bin": "cordova-wp8" + path.sep + "wp8",
@@ -178,13 +180,20 @@ if (argv.plugman) {
         console.log("Creating project " + projName + "...");
         shelljs.exec(platform_layout[platform].bin + path.sep + "bin" + path.sep + "create " + projName + " org.apache.cordova.mobilespecplugman " + projName);
         shelljs.rm("-r", path.join(top_dir, projName, platform_layout[platform].www));
-        shelljs.cp("-r", path.join(mobile_spec_git_dir, "*"), path.join(top_dir, projName, platform_layout[platform].www));
+        shelljs.cp("-r", path.join(mobile_spec_git_dir, "www"), path.join(top_dir, projName, platform_layout[platform].www));
+        var configPath = platform == 'ios' ? getProjName(platform) : platform[platform].config;
+        if (configPath) {
+          shelljs.cp("-f", path.join(mobile_spec_git_dir, "config.xml"), path.join(top_dir, projName, configPath));
+        } else {
+          console.warn('createmobilespec doesn\'t know where config.xml goes for platform ' + platform);
+        }
     });
 } else {
     // Create the project using "cordova create"
     myDelete(cli_project_dir);
     console.log("Creating project mobilespec...");
-    shelljs.exec(cli + " create " + projectDirName + " org.apache.cordova.mobilespec MobileSpec_Tests --link-to cordova-mobile-spec");
+    shelljs.exec(cli + " create " + projectDirName + " org.apache.cordova.mobilespec MobileSpec_Tests --link-to cordova-mobile-spec/www");
+    shelljs.cp("-f", path.join(mobile_spec_git_dir, 'config.xml'), path.join(projectDirName, 'config.xml'));
 
     // Config.json file ---> linked to local libraries
     shelljs.pushd(cli_project_dir);

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/events/index.html
----------------------------------------------------------------------
diff --git a/events/index.html b/events/index.html
deleted file mode 100644
index 3f45021..0000000
--- a/events/index.html
+++ /dev/null
@@ -1,60 +0,0 @@
-<!DOCTYPE html>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements.  See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership.  The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License.  You may obtain a copy of the License at
-
-   http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied.  See the License for the
- specific language governing permissions and limitations
- under the License.
-
--->
-
-
-<html>
-  <head>
-    <meta name="viewport" content="width=device-width,height=device-height,user-scalable=no,maximum-scale=1.0,initial-scale=1.0" />
-    <meta http-equiv="Content-type" content="text/html; charset=utf-8"> <!-- ISO-8859-1 -->
-    <title>Cordova Mobile Spec</title>
-    <link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
-    <script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>      
-    <script type="text/javascript" charset="utf-8" src="./index.js"></script>      
-
-  </head>
-  <body id="stage" class="theme">
-  
-    <h1>Events</h1>
-    <div id="info">
-        <b>Results:</b><br>
-        <span id="results"></span>
-    </div>
-    <input type="text" value="Type here to test events when fields are focused" />
-    <h2>Action</h2>
-    <div class="btn large interceptBackButton">Intercept backbutton</div>
-    <div class="btn large stopInterceptOfBackButton">Stop intercept of backbutton</div>
-    <div class="btn large interceptMenuButton">Intercept menubutton</div>
-    <div class="btn large stopInterceptOfMenuButton">Stop intercept of menubutton</div>
-    <div class="btn large interceptSearchButton">Intercept searchbutton</div>
-    <div class="btn large stopInterceptOfSearchButton">Stop intercept of searchbutton</div>
-    <div class="btn large interceptResume">Intercept resume</div>
-    <div class="btn large stopInterceptOfResume">Stop intercept of resume</div>
-    <div class="btn large interceptPause">Intercept pause</div>
-    <div class="btn large stopInterceptOfPause">Stop intercept of pause</div>
-    <div class="btn large interceptOnline">Intercept online</div>
-    <div class="btn large stopInterceptOfOnline">Stop intercept of online</div>
-    <div class="btn large interceptOffline">Intercept offline</div>
-    <div class="btn large stopInterceptOfOffline">Stop intercept of offline</div>
-
-    <h2> </h2><div class="backBtn">Back</div>
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/77ff9a37/events/index.js
----------------------------------------------------------------------
diff --git a/events/index.js b/events/index.js
deleted file mode 100644
index e1bb922..0000000
--- a/events/index.js
+++ /dev/null
@@ -1,94 +0,0 @@
-var deviceReady = false;
-
-function interceptBackbutton() {
-  eventOutput("Back button intercepted");
-}
-function interceptMenubutton() {
-  eventOutput("Menu button intercepted");
-}
-function interceptSearchbutton() {
-  eventOutput("Search button intercepted");
-}
-function interceptResume() {
-  eventOutput("Resume event intercepted");
-}
-function interceptPause() {
-  eventOutput("Pause event intercepted");
-}
-function interceptOnline() {
-  eventOutput("Online event intercepted");
-}
-function interceptOffline() {
-  eventOutput("Offline event intercepted");
-}
-
-var eventOutput = function(s) {
-    var el = document.getElementById("results");
-    el.innerHTML = el.innerHTML + s + "<br>";
-};
-
-
-/**
- * Function called when page has finished loading.
- */
-function init() {
-    document.addEventListener("deviceready", function() {
-            deviceReady = true;
-            console.log("Device="+device.platform+" "+device.version);
-            eventOutput("deviceready event: "+device.platform+" "+device.version);
-        }, false);
-    window.setTimeout(function() {
-      if (!deviceReady) {
-        alert("Error: Apache Cordova did not initialize.  Demo will not run correctly.");
-      }
-    },1000);
-}
-
-
-window.onload = function() {
-  addListenerToClass('interceptBackButton', function() {
-    document.addEventListener('backbutton', interceptBackbutton, false);
-  });
-  addListenerToClass('stopInterceptOfBackButton', function() {
-    document.removeEventListener('backbutton', interceptBackbutton, false);
-  });
-  addListenerToClass('interceptMenuButton', function() {
-    document.addEventListener('menubutton', interceptMenubutton, false);
-  });
-  addListenerToClass('stopInterceptOfMenuButton', function() {
-    document.removeEventListener('menubutton', interceptMenubutton, false);
-  });
-  addListenerToClass('interceptSearchButton', function() {
-    document.addEventListener('searchbutton', interceptSearchbutton, false);
-  });
-  addListenerToClass('stopInterceptOfSearchButton', function() {
-    document.removeEventListener('searchbutton', interceptSearchbutton, false);
-  });
-  addListenerToClass('interceptResume', function() {
-    document.addEventListener('resume', interceptResume, false);
-  });
-  addListenerToClass('stopInterceptOfResume', function() {
-    document.removeEventListener('resume', interceptResume, false);
-  });
-  addListenerToClass('interceptPause', function() {
-    document.addEventListener('pause', interceptPause, false);
-  });
-  addListenerToClass('stopInterceptOfPause', function() {
-    document.removeEventListener('pause', interceptPause, false);
-  });
-  addListenerToClass('interceptOnline', function() {
-    document.addEventListener('online', interceptOnline, false);
-  });
-  addListenerToClass('stopInterceptOfOnline', function() {
-    document.removeEventListener('online', interceptOnline, false);
-  });
-  addListenerToClass('interceptOffline', function() {
-    document.addEventListener('offline', interceptOffline, false);
-  });
-  addListenerToClass('stopInterceptOfOffline', function() {
-    document.removeEventListener('offline', interceptOffline, false);
-  });
-
-  addListenerToClass('backBtn', backHome);
-  init();
-}