From 83f6e6f250e2e5f98ef3164f83d45c4066ea2b6a 2015-02-09 17:21:22
From: Jonathan Frederic <jdfreder@calpoly.edu>
Date: 2015-02-09 17:21:22
Subject: [PATCH] Merge pull request #7700 from mathieu1/avoid-stopPropagation

Don't stop propagation in dashboard
---

diff --git a/IPython/html/static/tree/js/notebooklist.js b/IPython/html/static/tree/js/notebooklist.js
index fc56bdb..b4b191b 100644
--- a/IPython/html/static/tree/js/notebooklist.js
+++ b/IPython/html/static/tree/js/notebooklist.js
@@ -336,16 +336,11 @@ define([
             checkbox.css('visibility', 'hidden');
         } else if (selectable === true) {
             var that = this;
-            link.click(function(e) {
-                e.stopPropagation();
-            });
-            checkbox.click(function(e) {
-                e.stopPropagation();
-                that._selection_changed();
-            });
             row.click(function(e) {
-                e.stopPropagation();
-                checkbox.prop('checked', !checkbox.prop('checked'));
+                // toggle checkbox only if the click doesn't come from the checkbox or the link
+                if (!$(e.target).is('span[class=item_name]') && !$(e.target).is('input[type=checkbox]')) {
+                    checkbox.prop('checked', !checkbox.prop('checked'));
+                }
                 that._selection_changed();
             });
         }