Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6041627
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T06:41:19+00:00 2026-05-23T06:41:19+00:00

I have a component that extends UIComponent of Flex, I want to add it

  • 0

I have a component that extends UIComponent of Flex, I want to add it a FlexMouseEvent.MOUSE_DOWN_OUTSIDE listener but it does not works. that means I can not capture the event. But when I use PopUpManager to add this component, and then add a FlexMouseEvent.MOUSE_DOWN_OUTSIDE listener, it works fine.

Is FlexMouseEvent.MOUSE_DOWN_OUTSIDE only works for pop-up components?

Thanks for helping

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T06:41:20+00:00Added an answer on May 23, 2026 at 6:41 am

    That event only fires through popups. If you want to check a mouse event you need to add the regular mouse down to the parent container and check if the target is NOT the child.

    Another way you can do this is by catching the event on the stage and on the component… Since bubbling goes upwards, the component click gets caught first.

    public var bCompClicked=false;
    
    stage.addEventListener(MouseEvent.CLICK,onStageClick);
    myComponent.addEventListener(MouseEvent.CLICK,onComponentClick);
    
    private function onComponentClick(event:MouseEvent):void{
         bCompClicked = true;
    }
    
    private function onStageClick(event:MouseEvent):void{
         if(!bCompClicked){   //we didn't click the component, so we clicked outside it..
           clickedOutSide();
         }else{
            bCompClicked=false; //we did click the component, set to false for the next time.
         }
    }
    
    private function clickedOutSide():void{
        //do what you want when someone clicks outside...
    }
    

    Disclaimer I haven’t tested this or thought about it very hard… so it may not work.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created a Hexagon component that extends JPanel . It draws a hexagon
I have a component that i want to store to an SQLite database. public
I have a seperate class that extends SwingWorker, I want it to open a
I have an NumericTextBox component that extends an TextBox in my WinForms application. To
I have a DataGridColumn with an ItemRenderer that extends the Box component. The default
I have a component I created that extends Ext.window.Window, I've given it an alias
I have some component code that I'd like to in a CakePHP Task, but
I have a custom component that extends a panel. The panel has a top
I have a custom component that extends a JComponent. When you click it, it
I have a MyCanvas class that extends JComponent. On this canvas I have drawn

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.