You are not logged in.

> The forum rules have been updated. Please take a moment to read them.


#1 2012-07-13 18:53:26

phensta
New member
Registered: 2012-07-13
Posts: 6

Create Map Button

Hi,
I'm trying to create a button in the navigation to open and close the map. I can get a button to close the map, by using the action
'onclick="closemap
but can't get it to open again. If anyone can help, I'd be very grateful.

thanks

Offline

 

#2 2012-07-13 23:46:12

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: Create Map Button

hi.... So, I am assuming you have a second code to 'onclick="openmap"

Destiny....


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#3 2012-07-15 11:11:48

phensta
New member
Registered: 2012-07-13
Posts: 6

Re: Create Map Button

yes, I can create two buttons, one to open it and one to close it, but I'm having trouble getting it to switch from one to another.

Offline

 

#4 2012-07-15 11:41:36

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: Create Map Button

I guess you need some logic that determines the current state of the map and then invokes the appropriate action.

Are there no clues in the current coding of the Map feature?


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

#5 2012-07-15 12:18:39

phensta
New member
Registered: 2012-07-13
Posts: 6

Re: Create Map Button

yes, its in there, and I'm trying to figure it out, but I'm not the best coder. I'll post it if I sort it.

Offline

 

#6 2012-07-15 12:43:16

phensta
New member
Registered: 2012-07-13
Posts: 6

Re: Create Map Button

okay, I got it working now, thanks....


<action name="closemap">
        set(plugin[mapradar].visible,false);
        hidemapspot();
        set(plugin[map].onclick,openmap);
        tween(plugin[map].width , 28);
        tween(plugin[map].height, 40);
        set(plugin[openmapbutton].visible,false);
        set(plugin[closemapbutton].visible,true);
    </action>
    <!-- open the map -->
    <action name="openmap">
        if(plugin[mapradar].shouldbevisible == true, set(plugin[mapradar].visible,true)wink;
        set(plugin[map].onclick, closemap);
        tween(plugin[map].height, 694, 0.5, easeoutquad);
        tween(plugin[map].width , 497, 0.5, easeoutquad, showmapspot()wink;
        set(plugin[map].align, lefttop);
        set(plugin[map].x    , 10);
        set(plugin[map].y    , 10);
       
        set(plugin[openmapbutton].visible,true);
        set(plugin[closemapbutton].visible,false);
    </action>


    <plugin name="closemapbutton" align="bottom" customColor="true" height="prop" keep="true" onclick="openmap" onout="" onover="" url="virtualtourdata/graphics/menu/nav_tours.png" width="76" x="100" y="10"/>
   

<plugin name="openmapbutton" align="bottom" customColor="true" height="prop" keep="true" onclick="closemap" onout="" onover="" url="virtualtourdata/graphics/menu/nav_tours.png" width="76" x="100" y="10"/>

Offline

 

#7 2012-07-15 13:44:33

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: Create Map Button

phensta wrote:

okay, I got it working now, thanks....

Do you have an example of its use online that we can view?


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

#8 2012-07-16 12:54:46

phensta
New member
Registered: 2012-07-13
Posts: 6

Re: Create Map Button

Offline

 

#9 2012-07-16 12:59:02

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: Create Map Button

Good use of the Map and the Map button works well in the simple UI.


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson