Topic: Home Button

I'm trying to insert a Home button in AutoViewer, but why does this not work in my StageManager.as:

mHomeBtn.doAction = Delegate.create(this,showImage(0)); 

(I also created a 'ButtonHome' in the .fla, and added the var 'mHomeBtn' in the StageManager.as)
Output: Type Mismatch

Re: Home Button

Delegate doesn't accept function parameters (i'e the zero) . So you need to create a function called showFirstImage() then have the delegate point to that. make sense?

Felix Turner
SimpleViewer Support Team.

Re: Home Button

I'll try... big_smile

//EDIT: Fixed! Thx again big_smile

Re: Home Button

Can you please tell me how to add button which redirects you to the home page?

where to add function called showFirstImage() ?

Re: Home Button

@siddhi

Rather than modify the source code using Adobe Flash, this can be achieved by using CSS and HTML in your gallery's HTML index page.

(1) In the <head> section of your gallery's HTML index page, add the following code:

<style type="text/css">
    #overlay {
        position: absolute;
        top: 10px;
        left: 10px;
    }
</style>

(2) In the <body> section of your gallery's HTML index page, add the following code:

<div id="overlay"><a href="http://www.example.com">Link</a></div>

(3) In the embedding code section of your gallery's HTML index page, add the following code immediately before the 'fo.write' line:

fo.addParam("wmode", "transparent");
Steven Speirs
SimpleViewer Support Team.

Re: Home Button

Thanks! It is working fine........... smile