Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
freecad_x3d
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
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Elphel
freecad_x3d
Commits
f1386d1a
Commit
f1386d1a
authored
Dec 25, 2015
by
Oleg Dzhimiev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed event calls firefox
parent
7ee5af44
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
7 deletions
+24
-7
viewmodel.js
x3d_web_viewer/viewmodel.js
+24
-7
No files found.
x3d_web_viewer/viewmodel.js
View file @
f1386d1a
...
...
@@ -69,7 +69,7 @@ function prerun(){
//stop_animation();
});
var
x3d_cnv_ni
=
$
(
"<navigationinfo>"
,{
id
:
"navi"
,
type
:
"'examine' 'any'"
,
speed
:
"1"
});
var
x3d_cnv_ni
=
$
(
"<navigationinfo>"
,{
id
:
"navi"
,
type
:
"'examine' 'any'"
,
speed
:
"1"
,
headlight
:
"true"
});
var
x3d_cnv_vp
=
$
(
"<Viewpoint>"
).
attr
(
"fieldOfView"
,
"0.200"
);
...
...
@@ -446,7 +446,13 @@ function showBOM(){
//set default transparency?
parts_unique
.
find
(
"Material"
).
attr
(
"transparency"
,
0.1
);
parts_unique
.
find
(
"Material"
).
prop
(
"transparency"
,
0.1
);
parts_unique
.
find
(
"Material"
).
attr
(
"shininess"
,
0.5
);
parts_unique
.
find
(
"Material"
).
prop
(
"shininess"
,
0.5
);
parts_unique
.
find
(
"Material"
).
attr
(
"specularColor"
,
"0.2 0.2 0.2"
);
parts_unique
.
find
(
"Material"
).
prop
(
"specularColor"
,
"0.2 0.2 0.2"
);
var
prev_nsn_group
=
""
;
var
odd_group_en
=
false
;
...
...
@@ -513,7 +519,7 @@ function showBOM(){
window
.
location
.
href
=
$
(
this
).
attr
(
'href'
);
});
btn_link_to_wiki
=
$
(
"<a>"
,{
href
:
elphel_wiki_prefix
+
tmp_nsn
,
class
:
"btn btn-default btn-sm"
,
title
:
"Elphel Wiki docs"
}).
html
(
"<span class=
\"
glyphicon glyphicon-book
\"
aria-hidden=
\"
true
\"
></span>"
).
css
({
padding
:
"7px 13px 7px 13px"
,
margin
:
"6px"
});
btn_link_to_wiki
=
$
(
"<a>"
,{
href
:
elphel_wiki_prefix
+
"
\"
"
+
tmp_nsn
+
"
\"
&fulltext=Search"
,
class
:
"btn btn-default btn-sm"
,
title
:
"Elphel Wiki docs"
}).
html
(
"<span class=
\"
glyphicon glyphicon-book
\"
aria-hidden=
\"
true
\"
></span>"
).
css
({
padding
:
"7px 13px 7px 13px"
,
margin
:
"6px"
});
btn_link_to_wiki
.
click
(
function
(
e
){
window
.
location
.
href
=
$
(
this
).
attr
(
'href'
);
...
...
@@ -666,7 +672,7 @@ function touchstarted(){
move_history
=
[];
}
function
touchmoved
(){
function
touchmoved
(
event
){
//blockclick = true;
if
((
getTimeStamp
()
-
moveTimeStamp
)
>
100
){
blockclick
=
true
;
...
...
@@ -704,13 +710,13 @@ function mousestarted(event){
move_history
.
push
(
getMoveState
(
event
));
}
function
mousemoved
(){
function
mousemoved
(
event
){
if
(
dragging
)
{
move_history
.
push
(
getMoveState
(
event
));
}
}
function
mouseended
(){
function
mouseended
(
event
){
dragging
=
false
;
var
last_state
=
getMoveState
(
event
);
console
.
log
(
"mouse ended, history length="
+
move_history
.
length
);
...
...
@@ -951,6 +957,17 @@ function update_info(name,state,cmd){
open_btn
.
attr
(
"href"
,
"?"
+
inherited_parameters
+
"model="
+
path
+
"/"
+
name
+
".x3d"
);
var
wiki_btn
=
$
(
"<a>"
,{
id
:
"info_wiki"
,
title
:
"look for part in Elphel wiki"
,
class
:
"btn btn-default btn-sm nooutline"
}).
attr
(
"nsn"
,
name
).
html
(
"<span class=
\"
glyphicon glyphicon-book
\"
aria-hidden=
\"
true
\"
></span>"
).
css
({
padding
:
"8px 11px 7px 11px"
,
margin
:
"0px 0px 0px 10px"
});
wiki_btn
.
attr
(
"href"
,
elphel_wiki_prefix
+
"
\"
"
+
name
+
"
\"
&fulltext=Search"
);
var
hide_btn
=
$
(
"<button>"
,{
id
:
"info_hide"
,
title
:
"hide parts"
,
...
...
@@ -964,7 +981,7 @@ function update_info(name,state,cmd){
model_run_cmd
(
name
,
"info-hide-click"
);
});
$
(
"#info"
).
append
(
pn
).
append
(
$
(
"<span>"
).
append
(
open_btn
)).
append
(
$
(
"<span>"
).
append
(
hide_btn
)).
css
({
display
:
""
});
$
(
"#info"
).
append
(
pn
).
append
(
$
(
"<span>"
).
append
(
open_btn
)).
append
(
$
(
"<span>"
).
append
(
wiki_btn
)).
append
(
$
(
"<span>"
).
append
(
hide_btn
)).
css
({
display
:
""
});
}
break
;
case
"click-ext"
:
...
...
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