Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Amanda Ghassaei
DMDesign
Commits
068abffb
Commit
068abffb
authored
Sep 10, 2015
by
Amanda Ghassaei
Browse files
control panel
parent
52785efe
Changes
3
Hide whitespace changes
Inline
Side-by-side
css/serialMonitor.css
View file @
068abffb
...
...
@@ -18,4 +18,28 @@
#serialMonitorView
{
overflow
:
hidden
;
}
.btn
{
padding
:
5px
10px
;
margin
:
5px
10px
;
}
#controlPanel
{
background
:
#eee
;
width
:
100%
;
position
:
absolute
;
bottom
:
40px
;
}
.checkbox
input
[
type
=
"checkbox"
]
.custom-checkbox
:checked
+
.icons
.icon-checked
,
.radio
input
[
type
=
"checkbox"
]
.custom-checkbox
:checked
+
.icons
.icon-checked
,
.checkbox
input
[
type
=
"radio"
]
.custom-radio
:checked
+
.icons
.icon-checked
,
.radio
input
[
type
=
"radio"
]
.custom-radio
:checked
+
.icons
.icon-checked
{
color
:
#888
;
}
#autoscrollCheckbox
{
display
:
inline-block
;
position
:
absolute
;
margin-left
:
10px
;
margin-top
:
12px
;
}
\ No newline at end of file
js/SerialMonitor/SerialMonitorView.html
View file @
068abffb
<div
id=
"serialMonitorOutput"
></div>
<div
id=
"controlPanel"
>
<label
id=
"autoscrollCheckbox"
class=
"checkbox"
for=
"autoscroll"
>
<input
id=
"autoscroll"
data-property=
"autoscroll"
type=
"checkbox"
<%
if
(
autoscroll
){
%
>
checked="checked"
<
%
}
%
>
value="" data-toggle="checkbox" class="serialMonitor custom-checkbox">
<span
class=
"icons"
><span
class=
"icon-unchecked"
></span><span
class=
"icon-checked"
></span></span>
Autoscroll
</label>
<a
href=
"#"
id=
"clearMonitor"
class=
"pull-right btn btn-lg btn-default"
>
Clear
</a><br/>
</div>
<input
id=
"sendSerialMessage"
value=
""
placeholder=
"Send Message"
class=
"form-control"
type=
"text"
>
\ No newline at end of file
js/SerialMonitor/SerialMonitorView.js
View file @
068abffb
...
...
@@ -11,6 +11,7 @@ define(['jquery', 'underscore', 'commParentMenu', 'serialComm', 'text!SerialMoni
el
:
"
#serialMonitorView
"
,
events
:
{
"
click #clearMonitor
"
:
"
_clear
"
},
__initialize
:
function
(){
...
...
@@ -21,6 +22,11 @@ define(['jquery', 'underscore', 'commParentMenu', 'serialComm', 'text!SerialMoni
return
this
.
model
.
toJSON
();
},
_clear
:
function
(
e
){
e
.
preventDefault
();
$
(
"
#serialMonitorOutput
"
).
html
(
""
);
},
_updateIncomingMessage
:
function
(){
$
(
"
#serialMonitorOutput
"
).
append
(
serialComm
.
get
(
"
lastMessageReceived
"
)
+
"
<br/>
"
);
},
...
...
Write
Preview
Supports
Markdown
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