Show More
@@ -126,8 +126,7 b' define([' | |||
|
126 | 126 | $('#tree-selector .select-running-notebooks').click($.proxy(this.select_running_notebooks, this)); |
|
127 | 127 | $('#tree-selector .select-files').click($.proxy(this.select_files, this)); |
|
128 | 128 | $('#tree-selector .select-directories').click($.proxy(this.select_directories, this)); |
|
129 |
$('#tree-selector .select- |
|
|
130 | $('#tree-selector .unselect-all').click($.proxy(this.unselect_all, this)); | |
|
129 | $('#tree-selector .deselect-all').click($.proxy(this.deselect_all, this)); | |
|
131 | 130 | } |
|
132 | 131 | }; |
|
133 | 132 | |
@@ -379,7 +378,7 b' define([' | |||
|
379 | 378 | * Select all of the notebooks in the tree. |
|
380 | 379 | */ |
|
381 | 380 | NotebookList.prototype.select_notebooks = function() { |
|
382 |
this. |
|
|
381 | this.deselect_all(); | |
|
383 | 382 | $('.list_item').each(function(index, item) { |
|
384 | 383 | if ($(item).data('type') === 'notebook') { |
|
385 | 384 | $(item).find('input[type=checkbox]').prop('checked', true); |
@@ -392,7 +391,7 b' define([' | |||
|
392 | 391 | * Select all of the running notebooks in the tree. |
|
393 | 392 | */ |
|
394 | 393 | NotebookList.prototype.select_running_notebooks = function() { |
|
395 |
this. |
|
|
394 | this.deselect_all(); | |
|
396 | 395 | var that = this; |
|
397 | 396 | $('.list_item').each(function(index, item) { |
|
398 | 397 | if ($(item).data('type') === 'notebook' && that.sessions[$(item).data('path')] !== undefined) { |
@@ -406,7 +405,7 b' define([' | |||
|
406 | 405 | * Select all of the files in the tree. |
|
407 | 406 | */ |
|
408 | 407 | NotebookList.prototype.select_files = function() { |
|
409 |
this. |
|
|
408 | this.deselect_all(); | |
|
410 | 409 | $('.list_item').each(function(index, item) { |
|
411 | 410 | if ($(item).data('type') === 'file') { |
|
412 | 411 | $(item).find('input[type=checkbox]').prop('checked', true); |
@@ -419,7 +418,7 b' define([' | |||
|
419 | 418 | * Select all of the directories in the tree. |
|
420 | 419 | */ |
|
421 | 420 | NotebookList.prototype.select_directories = function() { |
|
422 |
this. |
|
|
421 | this.deselect_all(); | |
|
423 | 422 | $('.list_item').each(function(index, item) { |
|
424 | 423 | if ($(item).data('type') === 'directory') { |
|
425 | 424 | $(item).find('input[type=checkbox]').prop('checked', true); |
@@ -429,19 +428,9 b' define([' | |||
|
429 | 428 | }; |
|
430 | 429 | |
|
431 | 430 | /** |
|
432 | * Select the inverse of the current selection. | |
|
433 | */ | |
|
434 | NotebookList.prototype.select_inverse = function() { | |
|
435 | $('.list_item input[type=checkbox]').each(function(index, item) { | |
|
436 | $(item).prop('checked', !$(item).prop('checked')); | |
|
437 | }); | |
|
438 | this._selection_changed(); | |
|
439 | }; | |
|
440 | ||
|
441 | /** | |
|
442 | 431 | * Unselect everything selected in the tree. |
|
443 | 432 | */ |
|
444 |
NotebookList.prototype. |
|
|
433 | NotebookList.prototype.deselect_all = function() { | |
|
445 | 434 | $('.list_item input[type=checkbox]').each(function(index, item) { |
|
446 | 435 | $(item).prop('checked', false); |
|
447 | 436 | }); |
@@ -76,7 +76,6 b' data-terminals-available="{{terminals_available}}"' | |||
|
76 | 76 | </div> |
|
77 | 77 | <div id="notebook_list"> |
|
78 | 78 | <div id="notebook_list_header" class="row list_header"> |
|
79 | ||
|
80 | 79 | <div class="dropdown" id='tree-selector'> |
|
81 | 80 | <button class="btn btn-default btn-xs dropdown-toggle" type="button" id="tree-selector-btn" data-toggle="dropdown" aria-expanded="true"> |
|
82 | 81 | <input type='checkbox'></input> |
@@ -88,11 +87,10 b' data-terminals-available="{{terminals_available}}"' | |||
|
88 | 87 | <li role="presentation" class="select-running-notebooks"><a role="menuitem" tabindex="-1" href="#">Select running notebooks</a></li> |
|
89 | 88 | <li role="presentation" class="select-files"><a role="menuitem" tabindex="-1" href="#">Select files</a></li> |
|
90 | 89 | <li role="presentation" class="select-directories"><a role="menuitem" tabindex="-1" href="#">Select directories</a></li> |
|
91 | <li role="presentation" class="select-inverse"><a role="menuitem" tabindex="-1" href="#">Select inverse</a></li> | |
|
92 |
<li role="presentation" class=" |
|
|
90 | <li role="presentation" class="divider"></li> | |
|
91 | <li role="presentation" class="deselect-all"><a role="menuitem" tabindex="-1" href="#">Deselect all</a></li> | |
|
93 | 92 | </ul> |
|
94 | 93 | </div> |
|
95 | ||
|
96 | 94 | <div id="project_name"> |
|
97 | 95 | <ul class="breadcrumb"> |
|
98 | 96 | <li><a href="{{breadcrumbs[0][0]}}"><i class="fa fa-home"></i></a></li> |
General Comments 0
You need to be logged in to leave comments.
Login now