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
57ba2ba0
Commit
57ba2ba0
authored
May 04, 2014
by
campaign
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
b2a4ff40
f302f98b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
2 deletions
+13
-2
dragtree.js
src/module/dragtree.js
+10
-2
layout.default.js
src/module/layout.default.js
+3
-0
No files found.
src/module/dragtree.js
View file @
57ba2ba0
...
...
@@ -21,8 +21,8 @@ var MoveToParentCommand = kity.createClass( 'MoveToParentCommand', {
for
(
var
i
=
nodes
.
length
-
1
;
i
>=
0
;
i
--
)
{
node
=
nodes
[
i
];
if
(
node
.
getParent
()
)
{
minder
.
removeNode
([
node
]
);
minder
.
appendChildNode
(
parent
,
node
)
minder
.
removeNode
(
[
node
]
);
minder
.
appendChildNode
(
parent
,
node
);
}
}
minder
.
select
(
nodes
,
true
);
...
...
@@ -127,6 +127,7 @@ var DragBox = kity.createClass( "DragBox", {
this
.
remove
();
this
.
_dragMode
=
false
;
this
.
_dropSucceedTarget
=
null
;
this
.
_removeDropHint
();
},
_drawForDragMode
:
function
()
{
this
.
_text
.
setContent
(
this
.
_dragSources
.
length
+
' items'
);
...
...
@@ -191,6 +192,13 @@ var DragBox = kity.createClass( "DragBox", {
this
.
_lastSucceedTarget
=
target
;
},
_removeDropHint
:
function
()
{
var
lastTarget
=
this
.
_lastSucceedTarget
;
if
(
lastTarget
)
{
this
.
_removeDropStyle
(
lastTarget
);
}
},
_removeDropStyle
:
function
(
node
)
{
node
.
_layout
.
bgRect
.
stroke
(
'none'
);
this
.
_rect
.
stroke
(
'#3399ff'
,
1
);
...
...
src/module/layout.default.js
View file @
57ba2ba0
...
...
@@ -573,6 +573,9 @@ KityMinder.registerModule( "LayoutDefault", function () {
_root
.
setPoint
(
_root
.
getLayout
().
x
,
_root
.
getLayout
().
y
);
},
appendChildNode
:
function
(
parent
,
node
,
focus
,
sibling
)
{
if
(
parent
.
getType
()
!==
"root"
&&
parent
.
getChildren
().
length
!==
0
&&
parent
.
getData
(
"expand"
)
===
false
)
{
minder
.
expandNode
(
parent
);
}
minder
.
handelNodeInsert
(
node
);
node
.
clearLayout
();
node
.
getContRc
().
clear
();
...
...
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