Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kityminder-core
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
吴志俊
kityminder-core
Commits
bab1929d
Commit
bab1929d
authored
May 07, 2014
by
Akikonata
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed expand icon
parent
06fe1634
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
12 deletions
+13
-12
kityminder.config.js
kityminder.config.js
+5
-5
expand.js
src/module/expand.js
+4
-4
layout.default.js
src/module/layout.default.js
+3
-2
layout.js
src/module/layout.js
+1
-1
No files found.
kityminder.config.js
View file @
bab1929d
...
...
@@ -82,10 +82,10 @@
//,zIndex : 1000
//设置初始加载时展开的层数和子节点数目阈值
//默认是全部展开,0表示全部展开
//
,
//
defaultExpand: {
//
defaultLayer: 1,
//
defaultSubShow: 5
//
}
,
defaultExpand
:
{
defaultLayer
:
1
,
defaultSubShow
:
5
}
};
}
)();
\ No newline at end of file
src/module/expand.js
View file @
bab1929d
...
...
@@ -100,10 +100,10 @@ KityMinder.registerModule( "Expand", function () {
return
{
'events'
:
{
'importData'
:
function
(
e
)
{
//
var data = e.data;
//
console.log( data );
//
var options = this.getOptions();
//
console.log( options );
var
data
=
e
.
data
;
console
.
log
(
data
);
var
options
=
this
.
getOptions
();
console
.
log
(
options
);
}
},
'commands'
:
{}
...
...
src/module/layout.default.js
View file @
bab1929d
...
...
@@ -545,7 +545,6 @@ KityMinder.registerModule( "LayoutDefault", function () {
var
mains
=
_root
.
getChildren
();
for
(
var
i
=
0
;
i
<
mains
.
length
;
i
++
)
{
this
.
appendChildNode
(
_root
,
mains
[
i
]
);
console
.
log
(
mains
[
i
].
isExpanded
()
);
if
(
mains
[
i
].
isExpanded
()
&&
mains
[
i
].
getChildren
().
length
>
0
)
{
minder
.
expandNode
(
mains
[
i
]
);
}
...
...
@@ -569,7 +568,7 @@ KityMinder.registerModule( "LayoutDefault", function () {
while
(
_buffer
.
length
!==
0
)
{
var
c
=
_buffer
[
0
].
getChildren
();
if
(
_buffer
[
0
].
isExpanded
()
&&
c
.
length
!==
0
)
{
_buffer
[
0
].
getLayout
().
shicon
.
switchState
(
true
);
//
_buffer[ 0 ].getLayout().shicon.switchState( true );
for
(
var
x
=
0
;
x
<
c
.
length
;
x
++
)
{
minder
.
appendChildNode
(
_buffer
[
0
],
c
[
x
]
);
}
...
...
@@ -705,6 +704,8 @@ KityMinder.registerModule( "LayoutDefault", function () {
if
(
focus
)
{
showNodeInView
(
node
);
}
var
shicon
=
parent
.
getLayout
().
shicon
;
if
(
shicon
)
shicon
.
switchState
(
true
);
},
appendSiblingNode
:
function
(
sibling
,
node
,
focus
)
{
var
parent
=
sibling
.
getParent
();
...
...
src/module/layout.js
View file @
bab1929d
...
...
@@ -129,7 +129,7 @@ KityMinder.registerModule( "LayoutModule", function () {
if
(
parent
.
getType
()
!==
"root"
&&
parent
.
getChildren
().
length
!==
0
&&
!
parent
.
isExpanded
()
)
{
km
.
expandNode
(
parent
);
}
parent
.
expand
();
km
.
appendChildNode
(
parent
,
node
,
focus
,
silbling
);
km
.
select
(
node
,
true
);
return
node
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment