mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-20 18:18:56 +00:00
refactor(view) add showImage
This commit is contained in:
parent
11d9e1fef2
commit
70c6d2b970
1 changed files with 15 additions and 6 deletions
|
|
@ -145,12 +145,7 @@ var CloudCmd, Util, DOM, CloudFunc, $;
|
|||
break;
|
||||
|
||||
case 'image':
|
||||
config = Util.copyObj({
|
||||
autoSize : true,
|
||||
type : 'image'
|
||||
}, Config);
|
||||
|
||||
$.fancybox.open(path, config);
|
||||
showImage(path);
|
||||
break;
|
||||
|
||||
case 'media':
|
||||
|
|
@ -189,6 +184,20 @@ var CloudCmd, Util, DOM, CloudFunc, $;
|
|||
$.fancybox.close();
|
||||
}
|
||||
|
||||
function showImage(path) {
|
||||
var config;
|
||||
|
||||
config = Util.copyObj({
|
||||
}, Config);
|
||||
|
||||
config = Util.copyObj(config, {
|
||||
autoSize : true,
|
||||
type : 'image'
|
||||
});
|
||||
|
||||
$.fancybox.open(path, config);
|
||||
}
|
||||
|
||||
function isImage(name) {
|
||||
var isMatch;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue