Flash CS3 Make a symbol change alpha on mouse scroll?

So i have been trying to change the alpha by scrolling but no clue what to do. I tried this code
m2.addEventListener(MouseEvent.CHANGE, changeAlpha);
function changeAlpha(e:Event):void {
m2.alpha = m2.value/10;
and it works but it disappears fully and i cant scroll other way to bring it back. I know i need MOUSE_WHEEL but it just breaks the code

you can use the MouseEvent.MOUSE_WHEEL event.

Similar Messages

  • Change alpha on mouse enter/exit

    Hi,
    I have separate JPanels that I would like to be fully transparent until the user mouses over any one of them, at which point that one would become 50% transparent. I'm trying to achieve this with the following code:
        public void mouseEntered(MouseEvent e) {
            Color temp = e.getComponent().getBackground();
            int r = temp.getRed();
            int g = temp.getGreen();
            int b = temp.getBlue();
            e.getComponent().setBackground(new Color(r,g,b,50));
        public void mouseExited(MouseEvent e) {
            Color temp = e.getComponent().getBackground();
            int r = temp.getRed();
            int g = temp.getGreen();
            int b = temp.getBlue();
            e.getComponent().setBackground(new Color(r,g,b,0));
        }This does nothing on each mouse exit, yet increases the opacity on each mouse entrance. So if I pass the mouse over a JPanel repeatedly it will move closer and closer to 100% opacity with each mouse entrance.
    I have tried using negative numbers for the alpha, which didn't work, and I have also tried using both of the following:
    setBackground(new Color(r,g,b,0));
    this.setBackground(new Color(r,g,b,0));All of which have the same problem. So I have two questions:
    (1) Is there even a difference between the e.getComponent().setBackground(), this.setBackground(), and setBackground() approaches here?
    (2) How can I fix this so that the alpha toggles between 0 and 50?
    Thanks!

    When you don't fill the content area with opaque pixels, you are responsible for clearing the background.import java.awt.BorderLayout;
    import java.awt.Color;
    import java.awt.Graphics;
    import java.awt.event.MouseAdapter;
    import java.awt.event.MouseEvent;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    import javax.swing.JPanel;
    import javax.swing.SwingUtilities;
    public class AlphaBackground {
       JPanel panel;
       void makeUI() {
          panel = new JPanel() {
             @Override
             protected void paintComponent(Graphics g) {
                g.clearRect(0, 0, getWidth(), getHeight());
                super.paintComponent(g);
          panel.setBackground(Color.RED);
          panel.addMouseListener(new MouseAdapter() {
             @Override
             public void mouseEntered(MouseEvent e) {
                Color temp = e.getComponent().
                        getBackground();
                int r = temp.getRed();
                int g = temp.getGreen();
                int b = temp.getBlue();
                e.getComponent().
                        setBackground(new Color(r, g, b, 50));
             @Override
             public void mouseExited(MouseEvent e) {
                Color temp = e.getComponent().
                        getBackground();
                int r = temp.getRed();
                int g = temp.getGreen();
                int b = temp.getBlue();
                e.getComponent().
                        setBackground(new Color(r, g, b, 0));
          JFrame frame = new JFrame("");
          frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
          frame.setSize(400, 400);
          frame.add(panel, BorderLayout.CENTER);
          frame.add(new JLabel("Top"), BorderLayout.NORTH);
          frame.add(new JLabel("Bottom"), BorderLayout.SOUTH);
          frame.setLocationRelativeTo(null);
          frame.setVisible(true);
       public static void main(String[] args) {
          SwingUtilities.invokeLater(new Runnable() {
             @Override
             public void run() {
                new AlphaBackground().makeUI();
    }db

  • Help! Can't play online videos in Adobe Flash CS3/ CS4.

    Hi everyone,
    I am not able to play online videos in Adobe Flash CS3/ CS4. Reinstalled, changed computer, the same. But I could play just a month ago. Any idea what could have happened to my Adobe Flash CS3/ computer  or any other source please?
    Many thanks

    Thanks for the help guys.
    Clearing the cache didn't work, but removing the Youtube cookie and restarting firefox did. I can now switch to Hi-def again
    Cheers :)

  • How to change Layer Mode in Flash CS3?

    Hello,
    I would like to know how to change the layer mode to
    "multiply" with flash.
    I usually use photoshop CS2 to color my lineart. I set the
    top layer (the lines) to "multiply" to make the white transparent,
    and then apply color on layers underneath.
    I want to learn how to color my art on Flash, but I'm still a
    noob. I imported my bitmap lineart (inked by hand) and turned it
    into vectors (modify>bitmap>trace bitmap). Then I created a
    second layer underneath for the color, just like I would do in
    photoshop.
    But, the first layer's white areas are not transparent, so
    the color is not visible.
    So basically I just need to know how to change the top
    layer's mode to "multiply" so I can see through the white areas .
    Any help will be very appreciated.

    Nicochi,
    > So basically I just need to know how to change the
    > top layer's mode to "multiply" so I can see through
    > the white areas.
    Convert the top layer's artwork (raster or vector, doesn't
    matter) into
    a movie clip symbol -- select the artwork and go to Modify
    > Convert to
    Symbol -- and you'll be set. Once the symbol exists, you'll
    see mode
    choices in the Property inspector.
    David Stiller
    Co-author, Foundation Flash CS3 for Designers
    http://tinyurl.com/2k29mj
    "Luck is the residue of good design."

  • Changing Flash CS3 Interface colors

    The interface on my Windows XP install of Flash CS3 has an
    odd pink color that makes seeing the edge of the stage difficult
    for me. I can change the stage color but I prefer white. Is there
    any way to set the color behind the stage to a more reasonable gray
    or such?
    BTW, I've tried changing the Windows theme without
    luck.

    Flash used to be a designers tool but as time has progressed,
    not only are we seeing Flash become more of a RIA tool (although
    Flex still takes the cake there), there is also a clear division
    now between designers and developers in studios.
    AS3s learning curve is high, don't get me wrong but I think
    the important thing here is that Adobe is separating
    design/development as well. Let the designers do what they do and
    the developers do their part.
    In smaller studios where a designer may be responsible for
    also adding in the interaction, this can prove difficult but it
    isn't impossible.
    Remember also that just because AS3 is here doesn't mean
    that you have to use it. Adobe is still providing AS2 Fla as an
    option when creating a new file and it still supports AS2 coding. I
    know A LOT of people that are still using AS2 and aren't planning a
    change until mid-08 or later it will probably be that way for most.
    The real beauty in AS3 is the object oriented approach it
    takes to development (the gui for coding still sucks and I
    personally use FlashDevelop) and really allows for almost all
    interaction be created with code. Like I said before, this allows
    designers to remove themselves from the code and save their time
    for their primary role.

  • Tweens as Graphic Symbols in Flash CS3

    Greetings,
    I am teaching a basic Flash CS3 course at a college in Ohio.
    I am having something weird happening with some of my students'
    projects that I can't explain.
    For five of my students every time they apply a simple motion
    tween to a graphic symbol, Flash CS3 automatically saves the tween
    as a new graphic symbol in the library panel (naming it "tween 1",
    "tween 2", etc.).
    Since they are just learning the program this has
    understandably confused these five students on how tweening and the
    library panel works. Other students are doing exact or similar
    tweens and they are not having this problem. I have worked with
    Flash for years and have never had this happen to me.
    Would anyone know how I can correct this? Is this something
    that I can change in the preferences?
    Thanks for your help!

    Davis College wrote:
    > Thank you, Urami.
    >
    > I just tried to tween a raw shape on my vesion of CS3
    and I am not able to
    > get the software to convert my attempt to motion tween
    the raw shape into a
    > tween graphic symbol. I just get the dashed lines on my
    keyframes that i have
    > the tween applied.
    >
    > Why am I not able to get it to do it on my computer?
    >
    > Thanks again!
    >
    Hmm, it works for me all the time :)
    This is what I do.
    I open new document and library in the same time CTRL L, and
    immediately draw shape using
    the rectangle tool. Then I select frame 30 (sample only) and
    insert new frame using the F6 key.
    I right click the first frame and create motion tween. The
    very moment I do this, I get two
    new instances appearing in the library.
    Best Regards
    Urami
    "Never play Leap-Frog with a Unicorn."
    <urami>
    If you want to mail me - DO NOT LAUGH AT MY ADDRESS
    </urami>

  • How to make email link with a button with AC2 in flash cs3?

    How to make email link with a button with AC2 in flash cs3?
    I wrote this, but it does not work:
    btn_emailinfo.on (release) {
    getURL("mailto:"[email protected]");
    }

    I am guessing you put that on a frame?
    If so, the syntax is as follows:
    btn_emailinfo.onRelease = function(){
    getURL("mailto:[email protected]");
    Though, if you are placing it directly on the button itself,
    the syntax is:
    on(release){
    getURL("mailto:[email protected]");
    }

  • Help: symbol shifting between mac and windows, flash cs3

    I'm doing work reviewing flash files created by other users
    on mac and windows. I'm using os x 10.5.6. When I open a file
    created in windows / flash cs3 some symbols on the stage will have
    shifted upwards on the y axis. If I correct the shift and then send
    it back to the windows user they see the symbols incorrectly
    aligned, as if I had moved symbols around on a correctly aligned
    file.
    The strange thing is not everything on the stage is shifted.
    Only particular symbols will move, and it's usually symbols only
    (not text frames, drawing objects, etc).
    I believe there's a general history of bad behavior when
    saving flash files and trading them back and forth between mac and
    windows, but does anyone know what may be causing this? Or a
    remedy?
    Thank you in advance.
    Peter

    also, I tried opening the same files in vista using a mac
    mini with vista installed on a bootcamp partition. When opening
    other windows authored flash files there I had shifting issues as
    well, so I'm not convinced it's strictly a mac vs. windows issue.
    Unless it's a flash cs3 on windows xp doesn't like mac flash cs3
    and vista flash cs3...

  • Has Actionscript 3 changed since Flash CS3?

    maybe it is a strange question?
    I find that sometimes opening a Flash CS3 or Flash CS4 file in Flash CS5 causes the scripts to either fail or I get some strange results.
    I do not have specific examples to mention as it does happen on occasions.
    At the moment, I am doing a project for a University.
    They only run Flash CS3 Flash Player 9, which already leads to issues.
    I use Flash CS5 currently.
    The first time I sent in a draft example, they could not open the file and also they could not play the SWF file, as they only run Flash Player 9. They will not update the Flash Player to 10 as it will affect other ongoing projects in the University.
    I only purchase Master Suites, so I had to reinstall Flash CS4  from the CS4 Master Suite and also Flash CS3 from the Web Premium Suite.
    The Flash CS5 file had to be saved out as Flash CS4. I then had to open the Flash CS4 file and save it for Flash CS3.
    I found on occasions that opening the file in Flash CS3 cause some placement issues of Text and soemtimes, but not always some Actionscript 3 code would cause some errors.
    Has Flash CS5.5 rectified this and added the option to save to Flash CS3 perhaps, this would solve alot of issues.
    Has Actionscript 3 changed since Flash CS3?

    Actionscript 3 has changed since CS3, though what existed in CS3 has not changed.  Newer versions have newer features, so new code was created to support those features.

  • Can i make Animations with Adobe Flash CS3 Professionals?

    can i make Animations with Adobe Flash CS3 Professionals? my
    goal is to make a Animation Serie But i got no Expereience!
    Is it any place i can learn how to use Adobe Flash CS3
    Professionals? Can i get a tutorial/training thing on
    www.adobe.com?

    Ha!
    Just scratch the surface by using the search functions on
    this site or google - thousands of
    websites that showcase flash animations since version 3 back
    in the late 90's - many websites have
    dedicated themselves to flash training and tutorials over the
    years.
    Basically, anything on the web that looks animated, right
    click over it and 9 times out of ten it
    will say "Flash".
    Chris Georgenes
    Adobe Community Expert
    mudbubble.com
    keyframer.com
    http://tinyurl.com/2urlka
    Arfusman wrote:
    > can i make Animations with Adobe Flash CS3
    Professionals? my goal is to make a
    > Animation Serie But i got no Expereience!
    > Is it any place i can learn how to use Adobe Flash CS3
    Professionals? Can i
    > get a tutorial/training thing on www.adobe.com?
    >

  • Change flash cs3 language

    hye guys,
    i have some problem with my flash. yesterday i've downloaded
    france version of flash cs3, so all the language includes the
    toolbars, menu and so on is in france. is there any ways that i can
    changes the language to english?..help me please

    If you bought it legitimately, contact Adobe for a refund or
    exchange. If it's from eBay or a warez download, you're stuck with
    the Rumanian or Belorus version. Have fun!

  • Colour changes when importing Illustrator graphics into Flash CS3

    Hi there!
    I'm creating a Flash site, and all the graphics are imported
    from Illustrator.
    Also, in the Illustrator file, there are some Phtoshop
    graphics with shadow effects on it.
    The problem is, that when I import the .ai into Flash, a
    pretty strong colour change occurs: everything becomes lighter. And
    the shadow, wich is black in Photoshop, turns white in Flash!
    Is there a way to solve this problem? I searched the net, and
    some people say it's an OSX thing, wich is pretty strange, because
    Mac is an obvious choice for loads of designers.
    I've attached an image preview.
    Preview
    Thanks in advance!
    Alex

    Thanks for the anwsers!
    However, the weird thing is, when I pick one of the photoshop
    graphics, asign the profile to it, and import it into Flash, the
    colors look fairly good. BUT when I import the complete Illustrator
    file with alle the graphics in it, I still get the color shift. I
    can now put all the graphics in the flash file, one at a time, but
    I think thats not the most easy way to do it..

  • Wanting to make a Drop Down Menu in Flash CS3

    I'd like to build a drop down menu in Flash CS3. The web is awash in terrible tutorials. Would anyone have a decent tutorial they could refer me to?
    Thank you-

    I'd like to build a drop down menu in Flash CS3. The web is awash in terrible tutorials. Would anyone have a decent tutorial they could refer me to?
    Thank you-

  • Flash CS3: Help me make my movie play, please!

    URL: http:schoolsignsonline.com
    This is an electronic sign company, so I'm trying to put a Flash movie of one of their signs onto their preexisting site. No sound, no skin, no controls, just the movie, looping endlessly.
    I imported an .avi video (from a PC) from the client into Flash CS3 (on a Mac), and made sure my stage was the same size as the file parameters.
    Saved the file. Tested the movie in Flash. **The movie plays just fine**. It's a picture of brightly colored balloons ascending on a black background.
    I publish the movie.
    I copy the .fla and .swf into the flash folder at the root level of the site on my local server.
    I go into Dreamweaver CS3 to insert the movie using their Insert>Flash into the div I've created for it on the index page (which uses server side includes for the nav & footer only - no PHP involved - so each page has an .shtml extension).
    I test the movie in DW by clicking on the green arrow in the properties toolbar. Nothing but white. Movie doesn't play, or if it is playing, it's only white.
    What the heck. I save the page, letting DW generate the script.
    I upload the revised index page, the flash folder (with the .swf and .fla files in it), and the Scripts folder to the site on the remote server.
    Go to a browser. Nothing but white where the movie is supposed to be.
    I asked about this on the Adobe DW group on Yahoo Groups, and they really didn't know, thinking it was a Flash problem. One of them said the movie couldn't be found. Dang it! This is a script that DW generated when I placed the movie into the page! I don't know anything about JavaScript (yet), so I'm not going to muck about in the code to break it.
    BTW, the HTML for the page with the movie on it no longer validates - I hear this is typical of a CS3 Flash insertion by DW.
    Can anyone PLEASE help me figure out what I've done wrong? What other info do you need from me?
    Thank you in advance.
    Theresa

    For the Flash-generated html file, you basically want to copy the script tag in the head section....
    <script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
    into the same place in the head section of the real file.
    and copy the entire section of code in the body starting with and including...
    <script language="javascript">
    if (AC_FL_RunContent == 0) {
    .... all the stuff between....
    </object>
    </noscript>
    into the div you mention
    And in the case of what's shown above, you would want to have the AC_RunActiveContent.js file in a Scripts folder.

  • Quicktime movie export from Flash CS3 is skipping frame.

    When I try to export Quicktime movie from Flash CS3, the
    resulting mov file is skipping frames. i.e.: The movie is showing
    frame number 1, 2, 3, 4, 5, 6, 7, 7, 7, 10, 11, 12, 12, 12, 15
    etc...
    As you can see the frame number 7 is repeated 3 times and
    frame 8 and 9 are nowhere to be found.
    The last configuration I used is 960x540, Sorenson video 3
    medium quality, 25 fps, keyframe every 25 frames. 6400 kbits/s.
    I tried various configurations,with different codecs and even
    with keyframe all frames and I always get simillar problems.
    Anyone have an idea what is going on, and how to fix this?
    Thank you,
    Olivier.

    The QT exporter in Flash is honestly my least favorite
    feature - not the feature itself but how it
    works (or how it doesn't work in some cases). For me it is
    almost unusable unless you have a very
    short timeline, small stage, lower frame rate - like AS
    generated effects or something - otherwise,
    for true frame accuracy to video output - it is not reliable
    enough and not fast enough for any real
    world production environment.
    So typically for me - I love SWF2Video (www.flashants.com) as
    it takes any SWF and makes it into an
    AVI that is frame accurate no matter what the frame rate is -
    quite incredible - enough so that I
    always felt it should have been bundled with Flash (as well
    as Wacom tablets).
    Harmony is an incredible product - as is SOLO and TBS (Toon
    Boom mStudio) - each of those programs
    are dedicated animation programs designed for output to video
    - Flash has a lot of hats to fill and
    it was never really designed for animation to video even
    though many of us have found it suitable
    for all intents and purposes as an animation program for full
    production.
    But all in all - the quicktime exporter doesn't really
    deliver how we would expect it too I am sorry
    to say - I only hope it works as well as it does on the Mac
    (Mac users could always choose to export
    to Quicktime Video but not PC users).
    For now if I am exporting to video I keep it all on the
    timeline or nested in Graphic symbols or use
    the SWF2Video tool.
    hope this helps.
    -chris
    Chris Georgenes / mudbubble.com / keyframer.com / Adobe
    Community Expert
    OBastien wrote:
    > Thank you for your reply Chris.
    >
    > I tried different possible solutions you listed but it's
    not working.
    > Disabling sound had no effects. Changing the FPS is not
    an option, it has to be
    > 25 FPS. I lowered the resolution to 300 something, it
    seemed to be a little bit
    > better, but it still dropped some frame, and the image
    quality was horrible.
    >
    > I think it is really sad that we have to try different
    settings in the hope
    > that flash will grab all the frames. I'm really
    disapointed in Adobe. I'm
    > pretty sure it is the fault of Adobe and not Apple,
    because I don't have does
    > problems with Quicktime in ToonBoom Harmony. What is
    strange is when I do an
    > AVI export I never noticed a dropped frame. I'm not
    using AVI video right now
    > because I can not find a codec that gives me small size,
    fast encoding times,
    > the ability to seek in the movie by dragging the
    timeline progress bar, and the
    > possibility to edit in After Effects. If you know an AVI
    codec that does all
    > that it would be really great news.
    >
    > Thank you again,
    > Olivier.
    >

Maybe you are looking for

  • VPN Split Tunneling Unsuccessful

    I am working on creating a split tunnel to work with a test vpn group profile. We have an external proxy service that slows users down when they are VPN'd in because their web traffic then goes through us. My goal is to configure only private IP's to

  • The document could not be read: the document does not have a valid format.

    I created a 10MB document in Pages about a week ago. Around that time, I reopened the document and edited it with no problems. A week later, I've tried to open the document but Pages gives me the following error: The document "[Document Name].pages"

  • Status Change with Compulsory Original File Attachment

    Hi, We have created a document with 3 statuses (Created, Acknowledged, Released). DIR will be created with "Created" status. When the status will change to u201CAcknowledgedu201D system should check whether the DIR has a original file checked in. i.e

  • Bad workflow ? :-( document is still being processed in the background  :-(

    Hi guys, I have activated workflow without approval for PO's (saved & changed: WS14000075). Everything was working fine.. BUT.. For some reason, now some PO documents have the status "Waiting Approval", and if I try to edit them,I got the following m

  • Apple keyboard with Windows 7 RC

    I'm currently sharing a mac aluminum keyboard (one of the new, thin ones) between my Mini and a pc tower. The right half of the keyboard--the number pad, etc--don't work on the PC side of this arrangement, although the rest of the keyboard does. Are