Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
SimStadt
3DClient4SimStadtAPI
Commits
58011595
Commit
58011595
authored
3 years ago
by
BujarMuharemi
Browse files
Options
Download
Email Patches
Plain Diff
roof shadow color get reset, when changing modes
parent
0468704c
master
dev
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
public/js/globe.js
+15
-1
public/js/globe.js
with
15 additions
and
1 deletion
+15
-1
public/js/globe.js
+
15
-
1
View file @
58011595
...
...
@@ -273,7 +273,7 @@ viewer.screenSpaceEventHandler.setInputAction(function onLeftClick(movement) {
//Surface View
if
(
document
.
getElementById
(
"
surface
"
).
checked
)
{
resetRoofColors
();
//save the selected feature's original color
if
(
pickedhigh
)
{
highlightedFeatures
.
forEach
(
h
=>
{
...
...
@@ -339,6 +339,7 @@ viewer.screenSpaceEventHandler.setInputAction(function onLeftClick(movement) {
//Building View
else
if
(
document
.
getElementById
(
"
building
"
).
checked
){
resetRoofColors
();
//save the selected feature's original color
if
(
pickedhigh
)
{
highlightedFeatures
.
forEach
(
h
=>
{
...
...
@@ -480,3 +481,16 @@ function fillTableProperties(gID, sID) {
}
}
function
resetRoofColors
(){
tileContent
.
forEach
(
t
=>
{
if
(
t
.
getProperty
(
"
description
"
).
includes
(
"
Roof
"
)){
for
(
const
[
key
,
value
]
of
Object
.
entries
(
shadowdata
))
{
if
(
key
===
t
.
getProperty
(
"
gml_id
"
)){
t
.
color
=
Cesium
.
Color
.
WHITE
;
}
}
}
});
}
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets