You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

1

Friday, October 25th 2019, 6:50pm

maskchildren on plugin map and spot

hello,
I have a plugin map container with osm map:

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<plugin name="map"  devices="html5"
		    	type="container"
				keep="true"
		    	url="my_map_plugin.js" 
				align="lefttop" 
				width="270" height="370"
				scalechildren="true"
				maskchildren="true"
				>
				  <layer name="activespot" parent="map" x="" y=""  keep="true" url="img.png"
	           	align="lefttop" edge="center" zorder="1" scale.mobile="2" />
				 				   
	 	 	
				
</plugin>
			 	


The activespot changes x, y when dragging/moving the map according to a function of lat/lng of the point on the map. But when x, y are outside the plugin width and height the activespot is still visible, despite maskchildren="true" attribute on map plugin.
On my_map_plugin.js I set:

plugin.sprite.style = "align-items:center";

If that line is omitted the activespot is masked out as expected per maskchildren="true" attribute.
But in this case the map is shown in the topleft of the map container (the rest of the map container is void).

Any idea about this behaviour?
Thank you for any suggestions and help.

Giuseppe