Sie sind nicht angemeldet.

codiant

Anfänger

  • »codiant« ist der Autor dieses Themas

Beiträge: 17

Wohnort: India

Beruf: Web Developer

  • Nachricht senden

1

Freitag, 21. Juli 2017, 09:02

Hide All Hotspot on button Click

Hello,

I have two buttons one is for hiding the hotspot and other is for showing the hotspot. My query is that if i click one button all the hotspot should get hidden and upon clicking other button all the hotspot should appear. What's the way to do it?

Thank You

jordi

Profi

Beiträge: 583

Wohnort: Barcelona

Beruf: creating ideas & coding them

  • Nachricht senden

2

Freitag, 21. Juli 2017, 10:16

You need to make an action that counts all the hotspots and make the visible/ invisble, or any other change.

the could should be something like :

Quellcode

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
	<action name="yourCallingAction">
		
		<!-- make hotspots invisible -->
		toggleHotspotVisibility(0);
		
		<!-- make hotspots visible -->
		toggleHotspotVisibility(1);

	</action>
	
	<action name="toggleHotspotVisibility">

		for(set(i,0), i LT hotspot.count, inc(i),
			set(hotspot[get(i)].visible, %1);
		);

	</action>
everpano.com step beyond 360