diff --git a/ChangeLog b/ChangeLog index ddb3fad9..c6b22e7e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -72,6 +72,8 @@ getJSONfromFileTable. * fix(style) .name{width}: 37% -> 35% +* feature(view) show(pData) -> show(pData, pCallBack) + 2012.04.22, v0.2.0 diff --git a/lib/client/view.js b/lib/client/view.js index abb95ca9..d8f36d31 100644 --- a/lib/client/view.js +++ b/lib/client/view.js @@ -9,6 +9,7 @@ var CloudCmd, Util, DOM, CloudFunc, $; var Key = CloudCmd.Key, Images = DOM.Images, View = this, + Element, Config = { beforeShow : function(){ @@ -16,9 +17,7 @@ var CloudCmd, Util, DOM, CloudFunc, $; Key.unsetBind(); }, afterShow : function(){ - var lEditor = DOM.getById('View'); - if(lEditor) - lEditor.focus(); + Element.focus(); }, beforeClose : Key.setBind, @@ -53,20 +52,31 @@ var CloudCmd, Util, DOM, CloudFunc, $; /** * function shows FancyBox */ - this.show = function(pData){ - var lPath; + this.show = function(pData, pCallBack){ + var lPath, lElement, + lAfterFunc, lFunc; - if(pData) - $.fancybox(pData, Config); - else { - lPath = CloudFunc.FS + DOM.getCurrentPath(); + Element = $('