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
vidjil
vidjil
Commits
f6ae4c6d
Commit
f6ae4c6d
authored
May 19, 2014
by
Marc Duez
Browse files
builder.js : improve normalization button + check value
parent
8671da93
Changes
2
Hide whitespace changes
Inline
Side-by-side
browser/css/vidjil.less
View file @
f6ae4c6d
...
...
@@ -502,6 +502,10 @@ max-height: calc(~"100%" - @margin)
margin-top: 2px;
}
#normalized_size {
width: 80px;
}
/*menu*/
.menu{
...
...
browser/js/builder.js
View file @
f6ae4c6d
...
...
@@ -168,18 +168,24 @@ Builder.prototype = {
span2
.
appendChild
(
input
)
var
span3
=
document
.
createElement
(
'
spa
n
'
);
span3
.
appendChild
(
document
.
createTextNode
(
"
normalize
"
))
var
span3
=
document
.
createElement
(
'
butto
n
'
);
span3
.
appendChild
(
document
.
createTextNode
(
"
ok
"
))
span3
.
onclick
=
function
()
{
var
cloneID
=
parseInt
(
document
.
getElementById
(
'
tag_id
'
)
.
innerHTML
);
var
size
=
parseFloat
(
document
.
getElementById
(
'
normalized_size
'
).
value
);
document
.
getElementById
(
'
normalized_size
'
).
value
=
""
self
.
m
.
norm
=
true
self
.
m
.
compute_normalization
(
cloneID
,
size
)
self
.
m
.
update
()
$
(
'
#tagSelector
'
)
.
hide
(
'
fast
'
)
if
(
size
>
0
&&
size
<
1
){
document
.
getElementById
(
'
normalized_size
'
).
value
=
""
self
.
m
.
norm
=
true
self
.
m
.
compute_normalization
(
cloneID
,
size
)
self
.
m
.
update
()
$
(
'
#tagSelector
'
)
.
hide
(
'
fast
'
)
}
else
{
popupMsg
(
"
expected input between 0.0001 and 1
"
)
}
}
var
div
=
document
.
createElement
(
'
div
'
);
...
...
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