[Phpfreechat-svn] SF.net SVN: phpfreechat: [603] trunk/themes/default/templates/pfcclient.js.tpl.ph
Status: Beta
Brought to you by:
kerphi
From: <ke...@us...> - 2006-06-16 16:54:45
|
Revision: 603 Author: kerphi Date: 2006-06-16 09:12:08 -0700 (Fri, 16 Jun 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=603&view=rev Log Message: ----------- Bug fix: the button position index was wrong on IE, so the autofocus feature was broken Modified Paths: -------------- trunk/themes/default/templates/pfcclient.js.tpl.php Modified: trunk/themes/default/templates/pfcclient.js.tpl.php =================================================================== --- trunk/themes/default/templates/pfcclient.js.tpl.php 2006-06-16 15:12:59 UTC (rev 602) +++ trunk/themes/default/templates/pfcclient.js.tpl.php 2006-06-16 16:12:08 UTC (rev 603) @@ -1,3 +1,7 @@ +var is_ie = navigator.appName.match("Explorer"); +var is_khtml = navigator.appName.match("Konqueror") || navigator.appVersion.match("KHTML"); +var is_ff = navigator.appName.match("Netscape"); + /** * This class is the client part of phpFreeChat * (depends on prototype library) @@ -545,12 +549,12 @@ }, callbackContainer_OnMousedown: function(evt) { - if (evt.button == 0) + if ( (is_ie && evt.button == 1) || (is_ff && evt.button == 0) ) this.isdraging = false; }, callbackContainer_OnMouseup: function(evt) { - if (evt.button == 0) + if ( (is_ie && evt.button == 1) || (is_ff && evt.button == 0) ) if (!this.isdraging) if (this.el_words && !this.minmax_status) this.el_words.focus(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |