Show More
@@ -264,8 +264,7 var IPython = (function (IPython) { | |||
|
264 | 264 | var index = IPython.notebook.get_selected_index(); |
|
265 | 265 | if (index !== 0 && index !== null) { |
|
266 | 266 | IPython.notebook.select_prev(); |
|
267 |
|
|
|
268 | cell.focus_cell(); | |
|
267 | IPython.notebook.focus_cell(); | |
|
269 | 268 | } |
|
270 | 269 | return false; |
|
271 | 270 | } |
@@ -277,8 +276,7 var IPython = (function (IPython) { | |||
|
277 | 276 | var index = IPython.notebook.get_selected_index(); |
|
278 | 277 | if (index !== (IPython.notebook.ncells()-1) && index !== null) { |
|
279 | 278 | IPython.notebook.select_next(); |
|
280 |
|
|
|
281 | cell.focus_cell(); | |
|
279 | IPython.notebook.focus_cell(); | |
|
282 | 280 | } |
|
283 | 281 | return false; |
|
284 | 282 | } |
@@ -290,8 +288,7 var IPython = (function (IPython) { | |||
|
290 | 288 | var index = IPython.notebook.get_selected_index(); |
|
291 | 289 | if (index !== 0 && index !== null) { |
|
292 | 290 | IPython.notebook.select_prev(); |
|
293 |
|
|
|
294 | cell.focus_cell(); | |
|
291 | IPython.notebook.focus_cell(); | |
|
295 | 292 | } |
|
296 | 293 | return false; |
|
297 | 294 | } |
@@ -303,8 +300,7 var IPython = (function (IPython) { | |||
|
303 | 300 | var index = IPython.notebook.get_selected_index(); |
|
304 | 301 | if (index !== (IPython.notebook.ncells()-1) && index !== null) { |
|
305 | 302 | IPython.notebook.select_next(); |
|
306 |
|
|
|
307 | cell.focus_cell(); | |
|
303 | IPython.notebook.focus_cell(); | |
|
308 | 304 | } |
|
309 | 305 | return false; |
|
310 | 306 | } |
@@ -752,7 +748,9 var IPython = (function (IPython) { | |||
|
752 | 748 | e.on('focusin', handle_focus); |
|
753 | 749 | e.on('focusout', handle_blur); |
|
754 | 750 | // TODO: Very strange. The focusout event does not seem fire for the |
|
755 | // bootstrap textboxes on FF25&26... | |
|
751 | // bootstrap textboxes on FF25&26... This works around that by | |
|
752 | // registering focus and blur events recursively on all inputs within | |
|
753 | // registered element. | |
|
756 | 754 | e.find('input').blur(handle_blur); |
|
757 | 755 | e.on('DOMNodeInserted', function (event) { |
|
758 | 756 | var target = $(event.target); |
@@ -765,6 +763,8 var IPython = (function (IPython) { | |||
|
765 | 763 | // There are times (raw_input) where we remove the element from the DOM before |
|
766 | 764 | // focusout is called. In this case we bind to the remove event of jQueryUI, |
|
767 | 765 | // which gets triggered upon removal, iff it is focused at the time. |
|
766 | // is_focused must be used to check for the case where an element within | |
|
767 | // the element being removed is focused. | |
|
768 | 768 | e.on('remove', function () { |
|
769 | 769 | if (IPython.utils.is_focused(e[0])) { |
|
770 | 770 | that.enable(); |
General Comments 0
You need to be logged in to leave comments.
Login now