Skip to content

Instantly share code, notes, and snippets.

@xenophy
Created October 14, 2013 15:59
Show Gist options
  • Save xenophy/6977939 to your computer and use it in GitHub Desktop.
Save xenophy/6977939 to your computer and use it in GitHub Desktop.
文字列のExt Direct関数を関数オブジェクトに変換する方法
var me = this,
p = me.getEditView(),
form = p.getForm(),
fn = p.api.remove;
if (typeof fn !== 'function') {
//<debug>
var fnName = fn;
//</debug>
p.api.remove = fn = Ext.direct.Manager.parseMethod(fn);
//<debug>
if (!Ext.isFunction(fn)) {
Ext.Error.raise('Cannot resolve Ext.Direct API method ' + fnName);
}
//</debug>
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment