events: {
'change #show-hidden': 'toggleHidden',
- 'click #host-controls .view': 'hostEdit',
- 'click #select-all': 'selectAll'
+ 'click #select-all': 'selectAll',
+ 'click #btn-refresh': 'reloadFiles'
},
initialize: function(options) {
this.$noItems = $('#no-items');
this.$error = $('#error');
this.$showHidden = $('#show-hidden');
- this.$host = $('#host-controls');
this.$selectAll = $('#select-all');
this.host = options.host;
this.blur();
},
onBlur: function() {
- view.$host.toggleClass('editing');
-
var value = this.getValue();
if (!value) {
this.addItem(view.host, true);
render: function() {
this.updateSelectAll();
- this.$host.find('.view').text(this.host);
this.$noItems.toggle(!Boolean(this.visibleFiles().length));
this.$error.hide();
},
return this.$showHidden[0].checked;
},
- hostEdit: function() {
- this.$host.toggleClass('editing');
- this.hostSelectize.focus();
- },
-
busy: function() {
this.$el.addClass('busy');
},