diff --git a/dev/js/src/hint.js b/dev/js/src/hint.js
index c93d178..519ed26 100644
--- a/dev/js/src/hint.js
+++ b/dev/js/src/hint.js
@@ -264,8 +264,9 @@
       if (menu = this.contextMenu(ifContext)) {
 	      this.active(menu);
 
-        var c = this._inputField.container();
+        var c = this._inputField.container();        
 	      c.appendChild(menu.element());
+
 	      menu.show();
 	      menu.focus();
 	      // Focus on input field
@@ -303,6 +304,8 @@
         // This does not work for alert currently!
 	      //if (act._type !== 'alert') {
         if (!this._alert.active) {
+
+          // This does not work for webkit!
           var c = this._inputField.container();
           c.removeChild(this._active.element());
 	      }
diff --git a/dev/js/src/hint/input.js b/dev/js/src/hint/input.js
index adb74b6..e61d820 100644
--- a/dev/js/src/hint/input.js
+++ b/dev/js/src/hint/input.js
@@ -146,13 +146,14 @@
     // Create mirror for searchField
     // This is important for positioning
     // if ((this._mirror = document.getElementById("searchMirror")) === null) {
-      this._mirror = document.createElement("div");
-      this._mirror.classList.add('hint', 'mirror');
-      this._mirror.appendChild(document.createElement("span"));
-      this._container = this._mirror.appendChild(document.createElement("div"));
-      this._mirror.style.height = "0px";
-      document.getElementsByTagName("body")[0].appendChild(this._mirror);
-//    };
+    this._mirror = document.createElement("div");
+    this._mirror.classList.add('hint', 'mirror');
+    this._mirror.appendChild(document.createElement("span"));
+    this._container = document.createElement("div");
+    this._mirror.appendChild(this._container);
+    this._mirror.style.height = "0px";
+    document.getElementsByTagName("body")[0].appendChild(this._mirror);
+    //    };
 
     // Update position of the mirror
     window.addEventListener('resize', this.reposition.bind(this));
diff --git a/dev/js/src/hint/menu.js b/dev/js/src/hint/menu.js
index a7bdf57..105273e 100644
--- a/dev/js/src/hint/menu.js
+++ b/dev/js/src/hint/menu.js
@@ -1,12 +1,19 @@
 /**
  * Hint menu
  */
-define(['menu',
+define([
+  'menu',
 	'hint/item',
 	'hint/prefix',
-	'hint/lengthField'], function (menuClass, itemClass, prefixClass, lengthFieldClass) {
-  return {
+	'hint/lengthField'
+], function (
+  menuClass,
+  itemClass,
+  prefixClass,
+  lengthFieldClass) {
 
+  return {
+    
     /**
      * Create new hint helper menu.
      */
@@ -25,14 +32,20 @@
       // Make the top item always active
       obj._firstActive = true;
 
-      // This is only domspecific
       obj.element().addEventListener('blur', function (e) {
         this.menu.hideWithoutDestruction();
       });
 
       // Focus on input field on hide
       obj.onHide = function () {
-	      this._hint.unshow();
+        var h = this._hint;
+        h._inputField.element().focus();
+        if (h.active() !== null) {
+          if (h._alert.active) {
+            h._unshowAlert();
+          };
+          h.active(null);
+        };
       };
 
       return obj;
diff --git a/dev/js/src/menu.js b/dev/js/src/menu.js
index 1685da5..439adbd 100644
--- a/dev/js/src/menu.js
+++ b/dev/js/src/menu.js
@@ -535,7 +535,6 @@
      */
     onHide : function () {},
 
-
     /**
      * Get the prefix for filtering,
      * e.g. &quot;ve&quot; for &quot;verb&quot;
