Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
N
nodenogg-duplicate
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Adam Procter
nodenogg-duplicate
Commits
3757e215
Commit
3757e215
authored
4 years ago
by
Adam Procter
Browse files
Options
Downloads
Patches
Plain Diff
working on connections view and tool mode
parent
74e47150
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/src/components/ConnectionsLayer.vue
+25
-3
25 additions, 3 deletions
app/src/components/ConnectionsLayer.vue
with
25 additions
and
3 deletions
app/src/components/ConnectionsLayer.vue
+
25
−
3
View file @
3757e215
...
...
@@ -8,9 +8,16 @@
import
{
mapState
}
from
'
vuex
'
import
*
as
PIXI
from
'
pixi.js
'
//var initialMoveTo
let
buttons
=
new
PIXI
.
Graphics
()
export
default
{
name
:
'
ConnectionsLayer
'
,
data
()
{
return
{
localtoolstate
:
this
.
toolmode
,
}
},
computed
:
mapState
({
configConnections
:
(
state
)
=>
state
.
configConnections
,
configPositions
:
(
state
)
=>
state
.
configPositions
,
...
...
@@ -26,18 +33,31 @@ export default {
handler
()
{
this
.
connectionsDraw
()
this
.
buttonsDraw
()
},
},
},
methods
:
{
toolState
()
{
//console.log(this.toolmode)
if
(
this
.
localtoolstate
==
'
connect
'
)
{
console
.
log
(
'
tools
'
)
//this.buttonsDraw()
}
else
{
// this.clearButtons()
}
//
<
div
v
-
if
=
"
toolmode == 'move'
"
>
},
clearButtons
()
{
const
stage
=
this
.
PIXIApp
.
stage
stage
.
removeChild
(
buttons
)
},
buttonsDraw
()
{
// stage.removeChild(buttons)
var
i
var
j
this
.
canvas
=
this
.
$refs
.
pixi
const
stage
=
this
.
PIXIApp
.
stage
let
buttons
=
new
PIXI
.
Graphics
()
for
(
i
=
0
;
i
<
Object
.
keys
(
this
.
myNodes
).
length
;
i
++
)
{
for
(
j
=
0
;
j
<
Object
.
keys
(
this
.
configPositions
).
length
;
j
++
)
{
...
...
@@ -119,6 +139,7 @@ export default {
lines
[
0
].
lineTo
(
mouseX
,
mouseY
)
}
}
stage
.
addChild
(
buttons
)
},
connectionsDraw
()
{
...
...
@@ -164,7 +185,8 @@ export default {
view
:
canvas
,
})
this
.
connectionsDraw
()
this
.
buttonsDraw
()
this
.
toolState
()
// FIXME: code OLD
// this.connectingDraw()
},
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment