Commit a9bb28c3 authored by campaign's avatar campaign

by zhanyi

parent 1cf019b7
......@@ -4,8 +4,10 @@
<head>
<script src="jquery-2.1.0.min.js"></script>
<script src="kity.all.js"></script>
<script src="../configure.js"></script>
<script src="../dist/dev.php"></script>
<link href="import.css" />
<script src="../lang/zh-cn/zh-cn.js" charset="utf-8"></script>
<link href="../themes/default/_css/import.css" type="text/css" rel="stylesheet">
<style>
.km_receiver{
width:300px;height:300px;
......@@ -15,7 +17,7 @@
}
</style>
</head>
<body style="background:#262626; margin:0; padding:0">
<body >
<div id="kityminder" style="height:1000px;width:100%" onselectstart="return false">
<select id="StyleChange">
<option value="default">Default</option>
......@@ -24,15 +26,16 @@
</div>
</body>
<script>
var minder = KM.createMinder(kityminder);
document.getElementById("StyleChange").addEventListener("change",function(e){
var val = e.target.value;
minder.execCommand("switchlayout",val);
},false);
minder.select(minder.getRoot());
var node = new KM.MinderNode('test');
node.setData('fontcolor','red');
minder.execCommand('appendChildNode',node);
KM.getKityMinder('kityminder');
// var minder = KM.createMinder(kityminder);
// document.getElementById("StyleChange").addEventListener("change",function(e){
// var val = e.target.value;
// minder.execCommand("switchlayout",val);
// },false);
// minder.select(minder.getRoot());
// var node = new KM.MinderNode('test');
// node.setData('fontcolor','red');
// minder.execCommand('appendChildNode',node);
// var b = new kity.Bezier([new kity.BezierPoint(0,0).setVertex(100,100),new kity.BezierPoint(100,0).setVertex(100,100)]);
// minder.getRenderContainer().addShape(b.stroke("white"));
</script>
......
......@@ -14,6 +14,8 @@ $dependency = Array(
,'src/core/minder.command.js'
,'src/core/minder.node.js'
,'src/core/keymap.js'
,'src/core/minder.lang.js'
,'src/core/minder.defaultoptions.js'
,'src/module/history.js'
,'src/module/icon.js'
,'src/module/layout.js'
......@@ -29,6 +31,26 @@ $dependency = Array(
,'src/module/editor.cursor.js'
,'src/module/basestyle.js'
,'src/module/font.js'
,'src/ui/widget.js'
,'src/ui/button.js'
,'src/ui/toolbar.js'
,'src/ui/menu.js'
,'src/ui/dropmenu.js'
,'src/ui/splitbutton.js'
,'src/ui/colorsplitbutton.js'
,'src/ui/popup.js'
,'src/ui/scale.js'
,'src/ui/colorpicker.js'
,'src/ui/combobox.js'
,'src/ui/buttoncombobox.js'
,'src/ui/modal.js'
,'src/ui/tooltip.js'
,'src/ui/tab.js'
,'src/ui/separator.js'
,'src/ui/scale.js'
,'src/adapter/adapter.js'
,'src/adapter/button.js'
,'src/adapter/combobox.js'
);
......
......@@ -28,7 +28,9 @@ var KityMinder =
id = target.id || ( "KM_INSTANCE_" + instanceId++ );
}
return instanceMap[ id ] || this.createMinder(target,options);
}
},
//挂接多语言
LANG:{}
}
}();
......@@ -11,6 +11,7 @@
var Minder = KityMinder.Minder = kity.createClass( "KityMinder", {
constructor: function ( options ) {
this._options = Utils.extend( window.KITYMINDER_CONFIG || {}, options );
this.setDefaultOptions(KM.defaultOptions);
this._initEvents();
this._initMinder();
this._initSelection();
......@@ -29,7 +30,7 @@ var Minder = KityMinder.Minder = kity.createClass( "KityMinder", {
} else {
obj = key;
}
Utils.extend( this._options, obj, true );
utils.extend( this._options, obj, true );
},
_initMinder: function () {
......
......@@ -3,7 +3,7 @@ KityMinder.registerModule( "fontmodule", function () {
return {
"commands": {
"fontcolor": kity.createClass( "fontcolorCommand", {
"forecolor": kity.createClass( "fontcolorCommand", {
base: Command,
execute: function ( km,color ) {
......
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