aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/js
diff options
context:
space:
mode:
authorThomas Tanghus <thomas@tanghus.net>2012-11-13 12:10:49 +0100
committerThomas Tanghus <thomas@tanghus.net>2012-11-13 12:10:49 +0100
commit34a7e81ffbd97191a82ddf838d53a826217ede38 (patch)
tree25dfdb7c5c1ae4285573c315d60eada924c8fa16 /apps/files/js
parent268a48479dd8cc14eaf3484043cf4857526ccab2 (diff)
parentac22cd4ab06f5858fb01cbe5844975f0975ed070 (diff)
downloadnextcloud-server-34a7e81ffbd97191a82ddf838d53a826217ede38.tar.gz
nextcloud-server-34a7e81ffbd97191a82ddf838d53a826217ede38.zip
Merge branch 'master' of github.com:owncloud/core into vcategories_db
Diffstat (limited to 'apps/files/js')
-rw-r--r--apps/files/js/filelist.js16
1 files changed, 10 insertions, 6 deletions
diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js
index ae92a3f1ee1..ac2e0d63588 100644
--- a/apps/files/js/filelist.js
+++ b/apps/files/js/filelist.js
@@ -32,14 +32,16 @@ var FileList={
html+='<td class="date"><span class="modified" title="'+formatDate(lastModified)+'" style="color:rgb('+modifiedColor+','+modifiedColor+','+modifiedColor+')">'+relative_modified_date(lastModified.getTime() / 1000)+'</span></td>';
html+='</tr>';
FileList.insertElement(name,'file',$(html).attr('data-file',name));
+ var row = $('tr').filterAttr('data-file',name);
if(loading){
- $('tr').filterAttr('data-file',name).data('loading',true);
+ row.data('loading',true);
}else{
- $('tr').filterAttr('data-file',name).find('td.filename').draggable(dragOptions);
+ row.find('td.filename').draggable(dragOptions);
}
if (hidden) {
- $('tr').filterAttr('data-file', name).hide();
+ row.hide();
}
+ FileActions.display(row.find('td.filename'));
},
addDir:function(name,size,lastModified,hidden){
var html, td, link_elem, sizeColor, lastModifiedTime, modifiedColor;
@@ -66,11 +68,13 @@ var FileList={
td.append($('<span></span>').attr({ "class": "modified", "title": formatDate(lastModified), "style": 'color:rgb('+modifiedColor+','+modifiedColor+','+modifiedColor+')' }).text( relative_modified_date(lastModified.getTime() / 1000) ));
html.append(td);
FileList.insertElement(name,'dir',html);
- $('tr').filterAttr('data-file',name).find('td.filename').draggable(dragOptions);
- $('tr').filterAttr('data-file',name).find('td.filename').droppable(folderDropOptions);
+ var row = $('tr').filterAttr('data-file',name);
+ row.find('td.filename').draggable(dragOptions);
+ row.find('td.filename').droppable(folderDropOptions);
if (hidden) {
- $('tr').filterAttr('data-file', name).hide();
+ row.hide();
}
+ FileActions.display(row.find('td.filename'));
},
refresh:function(data) {
var result = jQuery.parseJSON(data.responseText);