Do not try to replace window.navigator (#215)

window.navigator is a read-only property. Thus the current code for
replacing it cannot succeed in a [spec][1] compliant browser. In strict
mode the attempt will throw an error. In sloppy mode, the one Cordova is
currently running in, the attempt is silently ignored.

Since apps seem to have been doing OK with the original navigator object
we should just remove the code trying to replace it.

[1]: https://html.spec.whatwg.org/multipage/window-object.html#the-window-object
diff --git a/src/common/init.js b/src/common/init.js
index 031ca9b..31a4900 100644
--- a/src/common/init.js
+++ b/src/common/init.js
@@ -24,7 +24,6 @@
 var modulemapper = require('cordova/modulemapper');
 var platform = require('cordova/platform');
 var pluginloader = require('cordova/pluginloader');
-var utils = require('cordova/utils');
 
 var platformInitChannelsArray = [channel.onNativeReady, channel.onPluginsReady];
 
@@ -44,34 +43,6 @@
     }
 }, 5000);
 
-// Replace navigator before any modules are required(), to ensure it happens as soon as possible.
-// We replace it so that properties that can't be clobbered can instead be overridden.
-function replaceNavigator (origNavigator) {
-    var CordovaNavigator = function () {};
-    CordovaNavigator.prototype = origNavigator;
-    var newNavigator = new CordovaNavigator();
-    // This work-around really only applies to new APIs that are newer than Function.bind.
-    // Without it, APIs such as getGamepads() break.
-    if (CordovaNavigator.bind) {
-        for (var key in origNavigator) {
-            if (typeof origNavigator[key] === 'function') {
-                newNavigator[key] = origNavigator[key].bind(origNavigator);
-            } else {
-                (function (k) {
-                    utils.defineGetterSetter(newNavigator, key, function () {
-                        return origNavigator[k];
-                    });
-                })(key);
-            }
-        }
-    }
-    return newNavigator;
-}
-
-if (window.navigator) {
-    window.navigator = replaceNavigator(window.navigator);
-}
-
 if (!window.console) {
     window.console = {
         log: function () {}