A bit of formatting + spaces -> tabs.
This commit is contained in:
parent
e6593def87
commit
6b3585dcc6
@ -595,9 +595,9 @@ var documentsMain = {
|
|||||||
async: false // Should be sync to complete before the page is closed
|
async: false // Should be sync to complete before the page is closed
|
||||||
});
|
});
|
||||||
|
|
||||||
if (documentsMain.isGuest){
|
if (documentsMain.isGuest){
|
||||||
$('footer,nav').show();
|
$('footer,nav').show();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
show: function(){
|
show: function(){
|
||||||
@ -642,36 +642,36 @@ FileList.highlightFiles = function(files, highlightFunction) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
FileList.findFile = function(filename) {
|
FileList.findFile = function(filename) {
|
||||||
var documents = documentsMain.docs.documentGrid('option').documents;
|
var documents = documentsMain.docs.documentGrid('option').documents;
|
||||||
return _.find(documents, function(aFile) {
|
return _.find(documents, function(aFile) {
|
||||||
return (aFile.name === filename);
|
return (aFile.name === filename);
|
||||||
}) || false;
|
}) || false;
|
||||||
};
|
};
|
||||||
|
|
||||||
FileList.generatePreviewUrl = function(urlSpec) {
|
FileList.generatePreviewUrl = function(urlSpec) {
|
||||||
urlSpec = urlSpec || {};
|
urlSpec = urlSpec || {};
|
||||||
if (!urlSpec.x) {
|
if (!urlSpec.x) {
|
||||||
urlSpec.x = 32;
|
urlSpec.x = 32;
|
||||||
}
|
}
|
||||||
if (!urlSpec.y) {
|
if (!urlSpec.y) {
|
||||||
urlSpec.y = 32;
|
urlSpec.y = 32;
|
||||||
}
|
}
|
||||||
urlSpec.x *= window.devicePixelRatio;
|
urlSpec.x *= window.devicePixelRatio;
|
||||||
urlSpec.y *= window.devicePixelRatio;
|
urlSpec.y *= window.devicePixelRatio;
|
||||||
urlSpec.x = Math.ceil(urlSpec.x);
|
urlSpec.x = Math.ceil(urlSpec.x);
|
||||||
urlSpec.y = Math.ceil(urlSpec.y);
|
urlSpec.y = Math.ceil(urlSpec.y);
|
||||||
urlSpec.forceIcon = 0;
|
urlSpec.forceIcon = 0;
|
||||||
return OC.generateUrl('/core/preview.png?') + $.param(urlSpec);
|
return OC.generateUrl('/core/preview.png?') + $.param(urlSpec);
|
||||||
}
|
}
|
||||||
|
|
||||||
FileList.isFileNameValid = function (name) {
|
FileList.isFileNameValid = function (name) {
|
||||||
var trimmedName = name.trim();
|
var trimmedName = name.trim();
|
||||||
if (trimmedName === '.' || trimmedName === '..') {
|
if (trimmedName === '.' || trimmedName === '..') {
|
||||||
throw t('files', '"{name}" is an invalid file name.', {name: name});
|
throw t('files', '"{name}" is an invalid file name.', {name: name});
|
||||||
} else if (trimmedName.length === 0) {
|
} else if (trimmedName.length === 0) {
|
||||||
throw t('files', 'File name cannot be empty.');
|
throw t('files', 'File name cannot be empty.');
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user