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
07b304fc
Commit
07b304fc
authored
Feb 09, 2014
by
Akikonata
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
renamed style
parent
99cadfca
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
13 deletions
+24
-13
dev.php
dist/dev.php
+1
-1
layout.bottom.js
src/module/layout.bottom.js
+23
-12
No files found.
dist/dev.php
View file @
07b304fc
...
...
@@ -18,7 +18,7 @@ $dependency = Array(
,
'src/module/icon.js'
,
'src/module/layout.js'
,
'src/module/layout.default.js'
,
'src/module/layout.
green
.js'
,
'src/module/layout.
bottom
.js'
,
'src/core/minder.select.js'
,
'src/module/keyboard.js'
,
'src/module/mouse.js'
...
...
src/module/layout.
green
.js
→
src/module/layout.
bottom
.js
View file @
07b304fc
KityMinder
.
registerModule
(
"Layout
Green
"
,
function
()
{
KityMinder
.
registerModule
(
"Layout
Bottom
"
,
function
()
{
var
minder
=
this
;
var
ShIcon
=
kity
.
createClass
(
"DefaultshIcon"
,
(
function
()
{
return
{
...
...
@@ -99,18 +99,25 @@ KityMinder.registerModule( "LayoutGreen", function () {
this
.
updateShIcon
();
},
updateConnect
:
function
()
{
var
rootX
=
minder
.
getRoot
().
getData
(
"layout"
).
x
;
var
rootY
=
minder
.
getRoot
().
getData
(
"layout"
).
y
;
var
connect
=
this
.
_connect
;
var
node
=
this
.
_node
;
var
Layout
=
node
.
getData
(
"layout"
);
if
(
Layout
.
x
&&
Layout
.
y
)
{
var
connect
=
this
.
_connect
;
connect
.
circle
.
setCenter
(
Layout
.
x
+
10
,
Layout
.
y
-
3
).
fill
(
"white"
).
stroke
(
"gray"
).
setRadius
(
2
);
var
parent
=
node
.
getParent
();
var
nodeShape
=
node
.
getRenderContainer
();
var
nodeClosurePoints
=
nodeShape
.
getRenderBox
().
closurePoints
;
var
sPos
;
var
endPos
;
var
parentLayout
=
parent
.
getData
(
"layout"
);
var
sX
=
parentLayout
.
x
+
10.5
,
pY
=
parentLayout
.
y
+
parent
.
getRenderContainer
().
getHeight
()
+
0.5
,
sY
=
parentLayout
.
y
+
parent
.
getRenderContainer
().
getHeight
()
+
parentLayout
.
margin
[
2
]
+
0.5
;
connect
.
path
.
getDrawer
()
.
clear
()
.
moveTo
(
sX
,
pY
)
.
lineTo
(
sX
,
sY
)
.
lineTo
(
Layout
.
x
+
10.5
,
sY
)
.
lineTo
(
Layout
.
x
+
10.5
,
Layout
.
y
);
connect
.
path
.
stroke
(
"white"
);
}
//connect.circle.setCenter( Layout.x + 10, Layout.y - 3 ).fill( "white" ).stroke( "gray" ).setRadius( 2 );
},
updateShIcon
:
function
()
{
this
.
_shicon
.
update
();
...
...
@@ -324,7 +331,11 @@ KityMinder.registerModule( "LayoutGreen", function () {
translateNode
(
_root
);
},
updateLayout
:
function
(
node
)
{
drawNode
(
node
);
var
set
=
updateLayoutHorizon
(
node
);
for
(
var
i
=
0
;
i
<
set
.
length
;
i
++
)
{
translateNode
(
set
[
i
]
);
}
},
appendChildNode
:
function
(
parent
,
node
,
index
)
{
minder
.
handelNodeInsert
(
node
);
...
...
@@ -360,6 +371,6 @@ KityMinder.registerModule( "LayoutGreen", function () {
}
};
this
.
addLayoutStyle
(
"
green
"
,
_style
);
this
.
addLayoutStyle
(
"
bottom
"
,
_style
);
return
{};
}
);
\ No newline at end of file
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