##// END OF EJS Templates
add disabled state to undo-delete-cell when unavailable.
MinRK -
Show More
@@ -546,6 +546,7 b' var IPython = (function (IPython) {'
546 var i = this.index_or_selected(index);
546 var i = this.index_or_selected(index);
547 var cell = this.get_selected_cell();
547 var cell = this.get_selected_cell();
548 this.undelete_backup = cell.toJSON();
548 this.undelete_backup = cell.toJSON();
549 $('#undelete_cell').removeClass('ui-state-disabled');
549 if (this.is_valid_cell_index(i)) {
550 if (this.is_valid_cell_index(i)) {
550 var ce = this.get_cell_element(i);
551 var ce = this.get_cell_element(i);
551 ce.remove();
552 ce.remove();
@@ -866,6 +867,7 b' var IPython = (function (IPython) {'
866 this.undelete_backup = null;
867 this.undelete_backup = null;
867 this.undelete_index = null;
868 this.undelete_index = null;
868 }
869 }
870 $('#undelete_cell').addClass('ui-state-disabled');
869 }
871 }
870
872
871 // Split/merge
873 // Split/merge
@@ -78,7 +78,7 b' class="notebook_app"'
78 <li id="paste_cell_below" class="ui-state-disabled"><a href="#">Paste Cell Below</a></li>
78 <li id="paste_cell_below" class="ui-state-disabled"><a href="#">Paste Cell Below</a></li>
79 <li id="paste_cell_replace" class="ui-state-disabled"><a href="#">Paste Cell &amp; Replace</a></li>
79 <li id="paste_cell_replace" class="ui-state-disabled"><a href="#">Paste Cell &amp; Replace</a></li>
80 <li id="delete_cell"><a href="#">Delete Cell</a></li>
80 <li id="delete_cell"><a href="#">Delete Cell</a></li>
81 <li id="undelete_cell"><a href="#">Undo Delete Cell</a></li>
81 <li id="undelete_cell" class="ui-state-disabled"><a href="#">Undo Delete Cell</a></li>
82 <hr/>
82 <hr/>
83 <li id="split_cell"><a href="#">Split Cell</a></li>
83 <li id="split_cell"><a href="#">Split Cell</a></li>
84 <li id="merge_cell_above"><a href="#">Merge Cell Above</a></li>
84 <li id="merge_cell_above"><a href="#">Merge Cell Above</a></li>
General Comments 0
You need to be logged in to leave comments. Login now