]> source.dussan.org Git - redmine.git/commitdiff
Fixes a JS error on context_menu with IE (#2390).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Wed, 24 Dec 2008 13:29:43 +0000 (13:29 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Wed, 24 Dec 2008 13:29:43 +0000 (13:29 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2178 e93f8b46-1217-0410-a6f0-8f06a7374b81

public/javascripts/context_menu.js

index 20f0fc5a7c171235db3c88d1f9209b8b7b7c17de..955650d6a503747d5358a7efd1868290efe04703 100644 (file)
@@ -48,7 +48,7 @@ ContextMenu.prototype = {
     if (window.opera && e.altKey) {    return; }
     if (Event.isLeftClick(e) || (navigator.appVersion.match(/\bMSIE\b/))) {      
       var tr = Event.findElement(e, 'tr');
-      if (tr!=document && tr.hasClassName('hascontextmenu')) {
+      if (tr!=null && tr!=document && tr.hasClassName('hascontextmenu')) {
         // a row was clicked, check if the click was on checkbox
         var box = Event.findElement(e, 'input');
         if (box!=document && box!=undefined) {