]> jfr.im git - irc/quakenet/qwebirc.git/commitdiff
Don't steal focus if we're inside an iframe.
authorChris Porter <redacted>
Sat, 24 Apr 2010 15:47:06 +0000 (16:47 +0100)
committerChris Porter <redacted>
Sat, 24 Apr 2010 15:47:06 +0000 (16:47 +0100)
js/ui/panes/connect.js

index 3c5fc3ace4a3e1ea86a187b4a07ea609e25b593a..9f8b539cc9e69b73968779d1a681535f6ec68414 100644 (file)
@@ -84,6 +84,9 @@ qwebirc.ui.ConfirmBox = function(parentElement, callback, initialNickname, initi
     td.appendChild(auth);
     auth.addEvent("click", qwebirc.ui.AuthLogin);
   }
+  
+  if(!window != window.top) 
+    yes.focus();
 }
 
 qwebirc.ui.LoginBox = function(parentElement, callback, initialNickname, initialChannels, networkName) {
@@ -233,7 +236,8 @@ qwebirc.ui.LoginBox = function(parentElement, callback, initialNickname, initial
   nick.set("value", initialNickname);
   chan.set("value", initialChannels);
 
-  nick.focus();
+  if(!window != window.top) 
+    nick.focus();
 }
 
 qwebirc.ui.authShowHide = function(checkbox, authRow, usernameBox, usernameRow, passwordRow) {