2015-07-15 10:06:13 +00:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2015
|
|
|
|
*
|
|
|
|
* This file is licensed under the Affero General Public License version 3
|
|
|
|
* or later.
|
|
|
|
*
|
|
|
|
* See the COPYING-README file.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
(function() {
|
|
|
|
/**
|
|
|
|
* @class OCA.Files.DetailFileInfoView
|
|
|
|
* @classdesc
|
|
|
|
*
|
|
|
|
* Displays a block of details about the file info.
|
|
|
|
*
|
|
|
|
*/
|
2015-08-12 15:30:20 +00:00
|
|
|
var DetailFileInfoView = OC.Backbone.View.extend({
|
|
|
|
tagName: 'div',
|
|
|
|
className: 'detailFileInfoView',
|
2015-07-15 10:06:13 +00:00
|
|
|
|
|
|
|
_template: null,
|
|
|
|
|
2015-07-20 12:42:10 +00:00
|
|
|
/**
|
|
|
|
* returns the jQuery object for HTML output
|
|
|
|
*
|
|
|
|
* @returns {jQuery}
|
|
|
|
*/
|
|
|
|
get$: function() {
|
|
|
|
return this.$el;
|
|
|
|
},
|
|
|
|
|
2015-07-15 10:06:13 +00:00
|
|
|
/**
|
|
|
|
* Sets the file info to be displayed in the view
|
|
|
|
*
|
|
|
|
* @param {OCA.Files.FileInfo} fileInfo file info to set
|
|
|
|
*/
|
|
|
|
setFileInfo: function(fileInfo) {
|
2015-08-12 15:30:20 +00:00
|
|
|
this.model = fileInfo;
|
2015-07-15 10:06:13 +00:00
|
|
|
this.render();
|
|
|
|
},
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the file info.
|
|
|
|
*
|
|
|
|
* @return {OCA.Files.FileInfo} file info
|
|
|
|
*/
|
|
|
|
getFileInfo: function() {
|
2015-08-12 15:30:20 +00:00
|
|
|
return this.model;
|
2015-07-15 10:06:13 +00:00
|
|
|
}
|
2015-08-12 15:30:20 +00:00
|
|
|
});
|
2015-07-15 10:06:13 +00:00
|
|
|
|
|
|
|
OCA.Files.DetailFileInfoView = DetailFileInfoView;
|
|
|
|
})();
|
|
|
|
|