Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Amanda Ghassaei
DMDesign
Commits
c0f2b189
Commit
c0f2b189
authored
Aug 28, 2015
by
Amanda Ghassaei
Browse files
working on ui
parent
4428ca8a
Changes
4
Show whitespace changes
Inline
Side-by-side
js/cam/Cam.js
View file @
c0f2b189
...
@@ -215,7 +215,8 @@ define(['underscore', 'three', 'backbone', 'appState', 'latticeCAM', 'threeModel
...
@@ -215,7 +215,8 @@ define(['underscore', 'three', 'backbone', 'appState', 'latticeCAM', 'threeModel
isVisible
:
function
(){
isVisible
:
function
(){
var
currentTab
=
appState
.
get
(
"
currentTab
"
);
var
currentTab
=
appState
.
get
(
"
currentTab
"
);
return
(
currentTab
==
"
assemblerSetup
"
||
currentTab
==
"
cam
"
||
currentTab
==
"
animate
"
||
currentTab
==
"
send
"
var
currentNav
=
appState
.
get
(
"
currentNav
"
);
return
(
currentTab
==
"
assemblerSetup
"
||
currentTab
==
"
cam
"
||
currentTab
==
"
animate
"
||
currentNav
==
"
navComm
"
||
currentTab
==
"
editComponent
"
);
||
currentTab
==
"
editComponent
"
);
},
},
...
...
js/menus/SendMenuView.js
View file @
c0f2b189
...
@@ -9,6 +9,11 @@ define(['jquery', 'underscore', 'commParentMenu', 'serialComm', 'commPlist', 'te
...
@@ -9,6 +9,11 @@ define(['jquery', 'underscore', 'commParentMenu', 'serialComm', 'commPlist', 'te
events
:
{
events
:
{
"
click #streamCommands
"
:
"
_startStream
"
,
"
click #pauseStream
"
:
"
_pauseStream
"
,
"
click #stopMachine
"
:
"
_stopMachine
"
,
"
click #previousLineButton
"
:
"
_decrementLineNum
"
,
"
click #nextLineButton
"
:
"
_incrementLineNum
"
},
},
...
@@ -16,6 +21,35 @@ define(['jquery', 'underscore', 'commParentMenu', 'serialComm', 'commPlist', 'te
...
@@ -16,6 +21,35 @@ define(['jquery', 'underscore', 'commParentMenu', 'serialComm', 'commPlist', 'te
this
.
isStreaming
=
false
;
this
.
isStreaming
=
false
;
},
},
_startStream
:
function
(
e
){
e
.
preventDefault
();
this
.
isStreaming
=
true
;
this
.
render
();
},
_pauseStream
:
function
(
e
){
e
.
preventDefault
();
this
.
isStreaming
=
false
;
this
.
render
();
},
_stopMachine
:
function
(
e
){
e
.
preventDefault
();
this
.
isStreaming
=
false
;
serialComm
.
send
(
"
!
"
);
this
.
render
();
},
_decrementLineNum
:
function
(
e
){
e
.
preventDefault
();
console
.
log
(
"
prev
"
);
},
_incrementLineNum
:
function
(
e
){
e
.
preventDefault
();
console
.
log
(
"
next
"
);
},
_makeTemplateJSON
:
function
(){
_makeTemplateJSON
:
function
(){
console
.
log
(
"
render
"
);
console
.
log
(
"
render
"
);
return
_
.
extend
(
serialComm
.
toJSON
(),
commPlist
,
cam
.
toJSON
(),
camPlist
,
{
streaming
:
this
.
isStreaming
});
return
_
.
extend
(
serialComm
.
toJSON
(),
commPlist
,
cam
.
toJSON
(),
camPlist
,
{
streaming
:
this
.
isStreaming
});
...
...
js/menus/templates/SendMenuView.html
View file @
c0f2b189
...
@@ -10,7 +10,9 @@
...
@@ -10,7 +10,9 @@
<a
href=
"#"
id=
"stopMachine"
class=
"btn pull-right btn-halfWidth btn-lg btn-danger"
>
Stop
</a><br/><br/>
<a
href=
"#"
id=
"stopMachine"
class=
"btn pull-right btn-halfWidth btn-lg btn-danger"
>
Stop
</a><br/><br/>
Incoming:
<pre
id=
"incomingSerialMessage"
></pre><br/><br/>
Incoming:
<pre
id=
"incomingSerialMessage"
></pre><br/><br/>
Out:
<input
id=
"sendSerialMessage"
value=
""
placeholder=
"Send Message"
class=
"seventyFiveWidth form-control unresponsiveInput"
type=
"text"
><br/><br/>
Out:
<input
id=
"sendSerialMessage"
value=
""
placeholder=
"Send Message"
class=
"seventyFiveWidth form-control unresponsiveInput"
type=
"text"
><br/><br/>
Next Line:
<input
id=
"nextLine"
value=
""
placeholder=
"##"
class=
"intInput form-control unresponsiveInput"
type=
"text"
>
Up/down
<br/><br/>
Next Line:
<input
id=
"nextLine"
value=
""
placeholder=
"##"
class=
"intInput form-control unresponsiveInput"
type=
"text"
>
<a
href=
"#"
id=
"previousLineButton"
class=
"btn btn-lg btn-default"
>
Prev
</a>
<a
href=
"#"
id=
"nextLineButton"
class=
"btn btn-lg btn-default"
>
Next
</a><br/><br/>
<div
id=
"gcodeEditor"
><
%=
dataOut
%
></div><br/>
<div
id=
"gcodeEditor"
><
%=
dataOut
%
></div><br/>
<
%
}
%
>
<
%
}
%
>
<
%
}
else
{
%
>
<
%
}
else
{
%
>
...
...
js/models/AppState.js
View file @
c0f2b189
...
@@ -117,6 +117,9 @@ define(['underscore', 'backbone', 'threeModel', 'three', 'plist', 'globals'], fu
...
@@ -117,6 +117,9 @@ define(['underscore', 'backbone', 'threeModel', 'three', 'plist', 'globals'], fu
this
.
set
(
"
highlighterIsVisible
"
,
false
);
this
.
set
(
"
highlighterIsVisible
"
,
false
);
}
else
if
(
navSelection
==
"
navAssemble
"
){
}
else
if
(
navSelection
==
"
navAssemble
"
){
this
.
set
(
"
highlighterIsVisible
"
,
false
);
this
.
set
(
"
highlighterIsVisible
"
,
false
);
}
else
if
(
navSelection
==
"
navComm
"
){
this
.
set
(
"
basePlaneIsVisible
"
,
false
);
this
.
set
(
"
highlighterIsVisible
"
,
false
);
}
}
},
},
...
...
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