From c52b70561c385df5640b63a3a3a160dd7dce6dc6 Mon Sep 17 00:00:00 2001 From: Min RK Date: Fri, 27 Mar 2015 13:13:33 -0700 Subject: [PATCH] dblclick to unconfine on images in html output --- IPython/html/static/notebook/js/outputarea.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/IPython/html/static/notebook/js/outputarea.js b/IPython/html/static/notebook/js/outputarea.js index 4cae67501..42091fa7a 100644 --- a/IPython/html/static/notebook/js/outputarea.js +++ b/IPython/html/static/notebook/js/outputarea.js @@ -588,6 +588,7 @@ define([ var toinsert = this.create_output_subarea(md, "output_html rendered_html", type); this.keyboard_manager.register_events(toinsert); toinsert.append(html); + dblclick_to_reset_size(toinsert.find('img')); element.append(toinsert); return toinsert; }; @@ -603,6 +604,7 @@ define([ html = mathjaxutils.replace_math(html, math); toinsert.append(html); }); + dblclick_to_reset_size(toinsert.find('img')); element.append(toinsert); return toinsert; }; @@ -668,7 +670,7 @@ define([ return toinsert; }; - dblclick_to_reset_size = function (img) { + function dblclick_to_reset_size (img) { /** * Double-click on an image toggles confinement to notebook width *