On 10/12/06, BrianPeiris <[EMAIL PROTECTED]> wrote:

I think you mean you want to Fade and BlindUp in *Parallel*, because it
wouldn't really make sense to do them one after the other (i.e. Queue
them).
Try this:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns=" http://www.w3.org/1999/xhtml">
        <head>
                <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
                <title>Untitled Document</title>

                <script language="_javascript_"
src="">                <script src="" type="text/_javascript_">
                </script>

                <style>
                        #testContainer{
                                background-color:lightblue;
                                color:black;
                                text-align:center;
                                width:100px;
                                height:100px;
                        }
                </style>
        </head>
        <body>
                <div id="testContainer">This is a test container, click me!</div>
                <script>
                        $('testContainer').
                        {
                                new Effect.Parallel
                                (
                                        [
                                                new Effect.Fade('testContainer',{duration:5}),
                                                new Effect.BlindUp('testContainer')
                                        ]
                                )
                        };
                </script>
        </body>
</html>

I'm aware that I can do them in parallel, as I'm using this elsewhere, but the benefit of toggle is that I don't need to worry about state myself; it just knows what to do as far as showing/hiding is concerned. If I have to implement the toggle manually then I'm losing one of the benefits of using scriptaculous. Maybe this is a rare case and it's not actually supported, and I'm just asking for a lot. But then I'm sure if it was supported it'd be used...



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs
-~----------~----~----~----~------~----~------~--~---

Reply via email to