Commit f7937942 authored by techird's avatar techird

支持重载

parent 3d8f0323
...@@ -12,8 +12,11 @@ ...@@ -12,8 +12,11 @@
var MinderDefaultOptions = {}; var MinderDefaultOptions = {};
var Minder = KityMinder.Minder = kity.createClass( "KityMinder", { var Minder = KityMinder.Minder = kity.createClass( "KityMinder", {
constructor: function ( options ) { constructor: function ( arg0, arg1 ) {
this._options = Utils.extend( window.KITYMINDER_CONFIG || {}, MinderDefaultOptions, options || {} ); var options = typeof ( arg0 ) === 'string' ? Utils.extend( arg1 || {}, {
renderTo: arg0
} ) : ( arg0 || {} );
this._options = Utils.extend( window.KITYMINDER_CONFIG || {}, MinderDefaultOptions, options );
this._initEvents(); this._initEvents();
this._initMinder(); this._initMinder();
this._initModules(); this._initModules();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment