Actionscript 3 / Firefox / Mouse release outside stage

So I need to be able to detect when the user releases the
mouse button outside the stage/movie bounds. I am using
Actionscript 3 / Flash 9.
Since onReleaseOutside was nixed, and setCapture is no longer
there now that Flash 9 is final, I'm using an event listener for
mouse_up on the stage. This works sometimes... but specifically not
when running inside Firefox 2.0 on a Mac..or when wmode is set to
something non standard (opaque or transparent running on
Windows/Firefox).
This is quite critical actually, pretty easy to repro,
assuming you have Firefox and MAC. Just drag a slider component
onto your stage inside a test app. Publish, then run inside the
browser. If you drag the slider, mouse outside the movie bounds,
then release..then mouse back over movie, the slider continues to
animate - thinking you still have the mouse pressed.
I've also tried inspecting the buttonDown property of the
mouse move event..but once you've released outside the bounds of
the movie - it's always true.
More info at
http://www.justsuppose.com
I'm grasping for straws..anyone stumble across a
workaround???
Thanks,
Corey

UPDATE: Stumbled upon a workaround after much trial and
error. At least until they fix mouse_up.
So considering the mouseLeave event... This event is
dispatched usually as soon as your cursor leaves the bounds of the
player window. But... if you've moused down first, then dragged
outside window, the mouseLeave is not fired *until* Flash is done
tracking. In other words, until the user lets go of the mouse
button.
So now I listen for *both* mouse up and mouseLeave on the
stage object and I can reliably (cross browser), detect when the
user has released the mouse button in the case the cursor is
outside of the stage. In this scenario I only attach the mouseLeave
and mouseUp listeners on the stage after the user has first moused
down. I then remove them once I've detected the mouse up.
Still hoping for a fix, but at least this provides an
alternative (albeit sneaky) work around.

Similar Messages

  • How can flex tell if  it's a mouseup event when the user releases the mouse button outside the flex application?

    how can flex tell if it's a mouseup event when the user
    releases the mouse button outside the flex application? Say for
    instance mousedown was done within a 500x500 embedded flex app but
    mouseup is outside or relased on the HTML background. One more
    thing, when we have something draggable, Flex doesn't execute the
    stopDrag() when the user releases the mouse button outside the
    embedded swf or fles app. Pls. help me with this. Thanks!

    I don't think the flex app can tell what happens outside the
    app. But it can detect when it leaves the app, so I have found the
    following line works fine inside initApp():
    this.stage.addEventListener(Event.MOUSE_LEAVE, yourFunction);
    and you have to:
    import flash.display.Stage;
    Doug

  • Mouse release event on jtable if its pressed outside jtable

    Is there any way to to catch the mouse release event on JTABLE if the mouse has been pressed on any other window.
    If Its pressed on jtable it can catch mouse release but if if its pressed out side than no mouse event is generated like mouse move and release if I drag mouse over jtable
    I have used mouse motion as well as click listeners but to no avail.
    Thanx in advance

    >
    You could create a generic listener to add to all
    components (or possibly an event queue or something)
    to get all mouse release events and refire the event
    to the component the mouse is really over.One way to do this would be the following:
        AWTEventListener globalMouseListener = new AWTEventListener() {
            public void eventDispatched(AWTEvent event) {
                MouseEvent me = (MouseEvent)event;
                if( me.getID() == MouseEvent.MOUSE_RELEASED ) {
                    System.out.println("Mouse relased at: " + me.getPoint());
                    System.out.println("Source: " + me.getSource());
        Toolkit.getDefaultToolkit().addAWTEventListener(
                globalMouseListener, AWTEvent.MOUSE_EVENT_MASK);Now, the source of the MouseReleased event will be the component on which the mouse was pressed, but once you have the coordinates you can probably transform them and find out if the mouse was released over your table using one or more of the SwingUtilities.convertPoint methods.
    On the other hand, maybe there is a far simpler way of doing it than this...

  • How can I get mouse pressed and mouse released positions on the desktop whi

    Hello All,
    I am generating a Frame using Swing API. My requirement is I need to capture the mouse pressed and mouse released positions, whenever user drags the mouse on desktop region (i.e. outside of the Frame). I require these points to find the rectangle region user has generated starting from mouse pressed to mouse released position. I need to pass that rectangle to Robot class in order to capture that desktop region.
    Can anybody help me out how can I achieve this using java on MAC, Linux and Windows platforms?
    Thanks in advance.
    Regards,
    VPKVL

    VPKVL wrote:
    DarrylBurke wrote:
    Can't be done in Java.I don't think that there is something which can't be done using java. When searched over net, found few applications which are using java for implementing this feature but not free, asking for license fee. I checked by downloading the demo version.
    Just want to know the hint how it can be achieved so that I can move further on that lines.
    Your thoughts ?They use JNI with the OS API.

  • Firefox mouse event not behaving the same on PC and Mac computers

    I use the FCKEditor and having a very strange problem. When I click on the FCKEditor's editing area, the keyboard gets disabled untill I click the mouse somewhere outside of the editing window. The problem only happen on Firefox (3.6.10) on Mac computer (Snowleopard 10.6.4). Doing exactly the same steps on PC works without any problem.
    What I want to know:
    - Is it possible that the Firefox on Mac is different than the PC in handling mouse events? Or some other areas?

    Sounds more that Firefox is treating that editor area as read-only.
    Start Firefox in [[Safe Mode]] to check if one of your add-ons is causing your problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    See [[Troubleshooting extensions and themes]] and [[Troubleshooting plugins]]

  • We do not understand what Mozilla Firefox means by Firefox Final Release Channel

    We are a university that uses the Blackboard Vista 8 product. In order for our students to complete their courses online in Blackboard, they have to use compatible and certified browsers. The Blackboard vendor has a website detailing which browsers the students should use. The URL is http://kb.blackboard.com/pages/viewpage.action?pageId=75071574. No one understands what the vendor (Blackboard) or Mozilla Firefox means by the phrase "Firefox (Final Release Channel)." Does this mean the latest version of Firefox? If so, why not say the latest version and where did the word "channel" come from and what does it mean? It's not explained anywhere on the Firefox website.

    Mozilla has 4 channels. In order of less to more secure and stable: Nightly, Aurora, Beta, Release.
    On the page you reference, "Final Release Channel" refers to Mozilla's "Release". These are versions that have been completed and "pushed" out for download by everyone. The most current version is always available at https://www.mozilla.com/en-US/firefox/fx/ (currently, Firefox 6.0).
    There are only 2 currently supported versions: Firefox 6.0 and Firefox 3.6.20.
    *All other versions have stability and security issues that will not be corrected, but are corrected in the updated versions, as they are released.
    Other download links:
    *Current version (now version 6.0): http://www.mozilla.com/en-US/firefox/all.html
    *Older supported version (now 3.6.20): http://www.mozilla.com/en-US/firefox/all-older.html
    According to the chart on the page you referenced, your students should be using Firefox 3.6.20 (Firefox 3.5.x versions are no longer supported or updated).
    The certified/compatible classifications are Blackboard's determination.
    '''<u>Firefox Portable</u>'''<br />
    If your students wish to use the most current version of Firefox for their everyday browsing and use a Blacboard compatible version for use only with Blackboard activities, they can have both on their systems by installing Firefox Portable (not produced by Mozilla):
    *Firefox Portable installs in a separate folder on your hard drive so that it does not interfere with your current version Firefox settings or personal information (bookmarks, passwords, etc.). Add-ons are also kept separate.
    *You can also install Firefox Portable on a USB/thumb/pin/jump drive.
    *Firefox Portable general information: http://portableapps.com/apps/internet/firefox_portable
    *Firefox Portable 3.6.20 download links: http://portableapps.com/apps/internet/firefox_portable/localization#legacy36
    *Firefox Portable user forum: http://portableapps.com/forums/support/firefox_portable
    '''If this reply solves your problem, please click "Solved It" next to this reply when <u>signed-in</u> to the forum.'''
    Not related to your question, but...
    You need to update some plug-ins ('''''on the system you used to post your question'''''):
    *Plug-in check: https://www-trunk.stage.mozilla.com/en-US/plugincheck/
    *Adobe Shockwave for Director Netscape plug-in: [https://support.mozilla.com/en-US/kb/Using%20the%20Shockwave%20plugin%20with%20Firefox#w_installing-shockwave Installing ('''''or Updating''''') the Shockwave plugin with Firefox]
    *Shockwave Flash (Adobe Flash or Flash): [https://support.mozilla.com/en-US/kb/Managing%20the%20Flash%20plugin#w_updating-flash Updating Flash in Firefox]

  • Press on Button and release outside the button armed frame

    Press on Button using the Mouse and release outside the button armed frame does not generate MouseEvent.
    Or Press on the Button outside the armed frame and release inside the armed frame does not generate MouseEvent.
    Window 7
    java version "1.6.0_22"
    Java(TM) Platform, Standard Edition for Business (build 1.6.0_22-b04)
    Java HotSpot(TM) Client VM (build 17.1-b03, mixed mode, sharing)
    The question :
    Is this normal behaviour for Java Swing. Does this exist in the java specification? any idea ? or is this a bug ?
    the sample code below for you to test
    public class PanelButtonArmedFrameClick extends JPanel
       private static final long serialVersionUID = 1L;
       private JButton btn;
       public PanelButtonArmedFrameClick()
          btn = new JButton("Click on \n the button");
          this.add(btn);
          MouseListener mouseListener = new MyMouseAdapter();
          btn.addMouseListener(mouseListener);
       private static class MyMouseAdapter extends MouseAdapter
           * {@inheritDoc}
          public void mouseClicked(MouseEvent e)
             JOptionPane.showMessageDialog(new JFrame(), "Button clicked");
       public static void main(String... args)
          SwingUtilities.invokeLater(new Runnable()
             public void run()
                JFrame frame = new JFrame("Testing");
                JPanel panel = new PanelButtonArmedFrameClick();
                frame.getContentPane().add(panel);
                frame.setPreferredSize(new Dimension(500, 500));
                frame.setMinimumSize(new Dimension(500, 500));
                frame.pack();
                frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                frame.setVisible(true);
    }

    Sure this is not a bug and this is the behavior of mouseClickedEvent.
    mouse clicked = mouse pressed + mouse released.
    mouseClickedEvent is a combination of mousePressed and mouseReleased evenst which are generated at the same pixel location. So if you generate mousePressed and mouseReleased events at different locations you will not get mouseClicked event.
    Thats why you are not getting mouse clicked event when you are performing mouse pressed event on one place and mouse released event on another place.

  • Problem in Multiple PO Release [Release outside field of responsibility]

    Hi all
    I m wrking on  Multiple PO release wid release strategy on a z dev report . I m using a BAPI_PO_RELEASE . For some garment PO it given a error msg " Release outside field of responsibility" .
    I got some details of this error using sdn for authorization .so i forward it to authorise person he will also get same error .
    Plz help me .
    Regards,
    alter

    Hi Ravi,
    If you see the message "Release outside field of responsibility," it means you tried to approve a line item you are not authorized to approve. To clear the error, click to "uncheck" the incorrectly selected item and press the Enter button .
    Click the Release + Save button.
    SAP displays a message confirming the requisition has been changed (i.e., line item(s) have been released) and your inbox is redisplayed. The released requisition line items will be routed either to the Procurement Office or to a Level 2 approver, depending on the release strategy your department uses.
    Thanks,
    PrasadGVK.

  • Error:Release outside field of responsibility

    Dear All,
    Error:Release outside field of responsibility in Function module:BAPI_PO_RELEASE
    I given the Inputs:
    Purchase Order:xXXXXXXXX
    PO_REL_CODE: 01
    Exceptions: X
    it showa the Error:Error:Release outside field of responsibility
    can any one help me
    Thanks in Advance.
    Dhanush

    Hi,
    It is really an strange error. I have researched and such an error happens when using the BAPI to release requisitions. I would suggest that you open a ticket for SAP so that someone can connect to your system.
    Best Regards,
    Arminda

  • JTree select on mouse release

    How can I force a JTree to change selection on a mouse release rather than the mouse press?
    Background - I have a component that uses a JTree as a navigation device - click on a node in the tree and the right side of the GUI shows a particular panel. Some panels allow user to drag a node from the navigation tree into the panel on the right side. The drag and drop is working fine, except that when a node in the tree is clicked, it changes which panel is showing and the place that I wanted to drag to is no longer visible.
    I've temporarily worked around it by adding a "locked" checkbox to the navigation tree, so that if the checkbox is locked then I just set the tree selection back to what it was when the selection changes. This is not very user friendly. Ideally, I'd like the selection in the tree to change only when the mouse is released. Alternately, I could live with only starting a drag when the CTRL key was pressed or something similar.

    mclabo01 wrote:
    How can I force a JTree to change selection on a mouse release rather than the mouse press?This is what I might try:
    -- use getMouseListeners to save the array of MouseListener[] to an instance field
    -- iterate over the array and removeMouseListener all of them
    -- add a single MouseListener
    ---- in mouseReleased, construct a new MouseEvent from the ME received as parameter, changing the ID from MOUSE_RELEASED to MOUSE_PRESSED
    ---- iterate over the array and invoke mousePressed on each listener with the constructed event
    May work, may not. And you may have to collect the MouseListeners after the tree is made visible.
    db
    edit It appears there's no need to modify the MouseEvent. Proof of concept (may need some tuning for different treatment of each mouse button):import java.awt.event.*;
    import javax.swing.*;
    public class MouseReleaseSelectTree {
      MouseListener[] listeners;
      public static void main(String[] args) {
        SwingUtilities.invokeLater(new Runnable() {
          @Override
          public void run() {
            new MouseReleaseSelectTree().makeUI();
      public void makeUI() {
        JTree tree = new JTree();
        listeners = tree.getMouseListeners();
        for (MouseListener listener : listeners) {
          tree.removeMouseListener(listener);
        tree.addMouseListener(new MouseAdapter() {
          @Override
          public void mouseClicked(MouseEvent e) {
            for (MouseListener listener : listeners) {
              listener.mouseClicked(e);
          @Override
          public void mousePressed(MouseEvent e) {
          @Override
          public void mouseReleased(MouseEvent e) {
            for (MouseListener listener : listeners) {
              listener.mousePressed(e);//pressed);
          @Override
          public void mouseEntered(MouseEvent e) {
            for (MouseListener listener : listeners) {
              listener.mouseEntered(e);
          @Override
          public void mouseExited(MouseEvent e) {
            for (MouseListener listener : listeners) {
              listener.mouseExited(e);
        JFrame frame = new JFrame();
        frame.add(new JScrollPane(tree));
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        frame.setSize(400, 400);
        frame.setLocationRelativeTo(null);
        frame.setVisible(true);
    }Edited by: DarrylBurke

  • Looking for 64 bit version of firefox, pre-release or Beta ok

    I have Win7 Pro 64bit. Was having issues with continuous crashing of flash. I installed Adobe Flash Square version10 64bit with Firefox version4, reduced # of flash crashes.
    When firefox pushed out version 5, I installed it & the browser kept dragging/crashing all over again. looked up Adobe Flash Square to see if any info avail, Adobe had Adobe Flash Square version11 64bit, so I uninstalled version 10 prior to installing version11 per Adobe instructions. Although it has helped, it is not where it was prior to installing Firefox 5.
    I have tested Firefox 5 with the current Adobe Flash 32bit release as well, and what can I say, it's not work the effort on my 64bit system. for some reason this combo maxes out my cpu (2.8 dual core) & memory (4 gb + virtual), causing me to hard boot my system.
    I understand Firefox devs are working on a 64bit version for Windows. I would like to volunteer to test it. I have many years of SW design & QA experience so any bugs I find I will fully document.
    The 64bit version of IE works well with the 64bit Flash, lots better than 32bit version, but I prefer to use Firefox or Chrome (I often utilize both simultaneously, each on own screen).
    Please let me know if a 64bit version of Firefox is available (pre-release/beta ok) & if it is not is there an expected availability date?
    Thank you in advance,
    Verta Tannehill

    Nightly is a pre-release testing version of Firefox: bleeding edge and not necessarily stable. It is Firefox -- a rose by any other name, and all -- but it is buggy, as all testing software is (I'm using it right now). New Firefox versions are born from Nightly, so when a 64-bit version of Firefox is released, it will have come from Nightly development. Use it for general browsing and send feedback (Tools -> Options -> Advanced -> General) and you will be helping to beta test a new baby Firefox.

  • How to detect a mouse release event?

    AE SDK provides events for mouse click and mouse drag over effect plugin custom UIs, however there does not seem to be events for mouse release events.
    Are we supposed to keep ourselves an internal track of the mouse status? In that case, do we need to use OS-specific functions? Or is there a more clever way to do it?

    @shachar
    Yes, I set send_drag during the DoClick event callback, like they do in the SDK samples.
    Anyway, for the time being I found that using OS-specific functions (for example GetAsyncKeyState for Windows) does the job.

  • How to response the value change of slide bar only after mouse released

    Hi, all
    When I used the slide bar to control my device, I response the value change of slide bar and set the new value to my device. But it will generate response constantly when I use the mouse to drag the pointer, which is not my wanted. I just need to response only after the mouse released. How can I implement this function? 
    Hope your suggestion, thanks a lot.
    Solved!
    Go to Solution.

    No, not if you use the right event under "Mouse".
    “A child of five could understand this. Send someone to fetch a child of five.”
    ― Groucho Marx

  • Mouse released event for scrollbar

    Hello,
    I have a java.awt.Scrollbar component on applet.
    I need to perform actions when user releases the mouse from the
    scrollbar. For example the user presses the mouse on the scrollbars
    tracking rectangle and starts to track. Then the values of the
    scrollbar changes and finally user releases the mouse left button-
    this final event (mouse release) is in my interest. How can i get
    mouse release event from scrollbar? The AdjustmentListener does not
    suit for me because it fires AdjustmentEvents even then when the user
    hasn't released the mouse. I need to perform more actions for every
    scrollbar's change; so my applet i slow at the moment, because every
    "tracking in scrollbar" creates a lot of events before the mouse is
    finally released.
    I added a MouseListener for my scrollbar, but mouseReleased event does
    not work. Can yo help me?
    Thank you, any help would be nice.
    Here is some demo code i tried:
    import java.applet.Applet;
    import java.awt.*;
    import java.awt.event.*;
    public class Kerimisriba1 extends Applet implements
    AdjustmentListener, MouseListener{
         Scrollbar kerimisriba=new Scrollbar(Scrollbar.VERTICAL, 20, 5, 1,
    100); //algv��rtus, nupu suurus, v�him ja suurim v��rtus
         TextField tf=new TextField(10);
         public Kerimisriba1(){
              setLayout(new BorderLayout());
              add(kerimisriba, BorderLayout.WEST);
              add(tf, BorderLayout.SOUTH);
              //kerimisriba.addAdjustmentListener(this);
              kerimisriba.addMouseListener(this);
              System.out.println("AdjustmentEvent.TRACK="+AdjustmentEvent.TRACK);
         public void adjustmentValueChanged(AdjustmentEvent e){
              //System.out.println(e.getAdjustmentType());
              // tf.setText(kerimisriba.getValue()+"");
         public void mouseReleased(MouseEvent me){
              tf.setText("mouseReleased");
         public void mouseClicked(MouseEvent me){}      
         public void mouseEntered(MouseEvent me){}
         public void mouseExited(MouseEvent me){}
         public void mousePressed(MouseEvent me){}
    }

    I made a screenshot of how the applet works in my computer:
    http://charles.pri.ee/scroll.gif
    As you see in the java console,
    the statement System.out.println("mouseReleased");
    does not executes,
    in my computer.
    I tried this on co-workers comuter with Internet Explorer- there was no mouse release event either.
    I hope i'm not very annoying, but i still need help:)
    I replaced the constructor with init() method:
    import java.applet.Applet;
    import java.awt.*;
    import java.awt.event.*;
    public class Kerimisriba1 extends Applet implements AdjustmentListener, MouseListener{
         Scrollbar kerimisriba=new Scrollbar(Scrollbar.VERTICAL, 20, 5, 1, 100); //algv��rtus, nupu suurus, v�him ja suurim v��rtus
         TextField tf=new TextField(10);
         public void init(){
              kerimisriba.addAdjustmentListener(this);
              setLayout(new BorderLayout());
              kerimisriba.addMouseListener(this);
              add(kerimisriba, BorderLayout.WEST);
              add(tf, BorderLayout.SOUTH);          
              System.out.println("AdjustmentEvent.TRACK="+AdjustmentEvent.TRACK);
         public void adjustmentValueChanged(AdjustmentEvent e){
              System.out.println(e.getAdjustmentType());
              tf.setText(kerimisriba.getValue()+"");
         public void mouseReleased(MouseEvent me){
              tf.setText("mouseReleased");
              System.out.println("mouseReleased");
         public void mouseClicked(MouseEvent me){
              System.out.println("mouseClicked");
         public void mouseEntered(MouseEvent me){}
         public void mouseExited(MouseEvent me){}
         public void mousePressed(MouseEvent me){
              System.out.println("mousePressed");

  • Capture Mouse Position outside an applet

    Dear All,
    I'm working on an applet that needs to know the actual position of the mouse cursor outside its area
    (i.e.: else where on the screen), is that possible?
    Thank you in advance.

    As far as I know, no. Applets know about the mouse only when it's inside the applet area.

Maybe you are looking for

  • If i buy an iPhone 4s in the uk, and send it abroad as a gift, will it still work with any sim card or will it need unlocking?

    I basically want to buy an iphone as a gift, but i'm unsure if it will need extra unlocking in another country or will i be able to use it srtaight away if i have a sim card

  • Can anyone help me with a tagging problem?

    I have the latest version of ITunes on my Windows 7 machine. The problem I am having is as follows, I tag a song on my IPod and it shows up in the playlist as it should. When I go to buy it however, it won't purchase. Can someone please help me solve

  • Menu images appear blurry

    I am using the "Reveal" theme which has several images along the left side and each of those images is pixilating even though the image size is 740x495 150dpi and RGB. The images appear OK on a TV screen but very pixilated on both Macs and PCs. How c

  • How can I restore accidentally-deleted add-ons?

    A year ago, I wasn't fully awake and I accidentally deleted some critical add-ons that my Firefox needs to become stable. Is there a way I can restore them?

  • Require Login (Form based)

    Hi all, I want to control my website so that all pages require a logged in user, some pages are only visible for certain roles. In the web.xml description there is a remark for the <login-config> element: If this element is present, the user must be