How to measure a menu before it is displayed?

Hello

Probably a stupid question... but... I create a menu like this: Menu.createMenu ().  I will then menu.show(x,y).  My x & there will depend on the size of the menu that should be displayed because I have to make sure that it is not flowing down or the right side of the screen.  But the width and height of the menu object 0 before it is displayed.  Is there a good way to get the actual height and width of the menu before it is displayed so I can position it correctly?

Thank you!

3.4 has improvements in this area.  You call PopUpManager.addPopUp (in the menu), and then its measuredWidth/measuredHeight must be valid, you can call show() with the correct coordinates.  I think that if you do not use 3.4 you can get an error.

Alex Harui

Flex SDK Developer

Adobe Systems Inc..

Blog: http://blogs.adobe.com/aharui

Tags: Flex

Similar Questions

  • How to restore the menu bar (file-editing-display) PDF?

    How to restore the menu bar (file-editing-display) PDF? I use version Adobe Acrobat 8.1.3. Any help would be appreciated. Thank you!

    Kolja

    I had a similar problem with Adobe Acrobat Pro X, where the menu bar would not appear.  I was able to get menu bar to appear if I resized the document by placing the pointer on the right, left, top or bottom of the document (you see a double arrow), and then by clicking and dragging.

    The problem was definitely solved for all documents by opening Adobe Acrobat without having to open a document.  Then click on Edit in the menu bar.  Then click on Preferences.  In the preferences of the box click on full screen at the top left.  Then find the section Navigation screen complete.  Check the box show the Navigation bar.  Finally click on OK at the bottom right.

    I hope this helps someone and saves a lot of frustration.

  • How to turn off ButtonBarButtons before ButtonBar is displayed?

    Hello - firstly, post it here...

    I am trying to disable (show, but do not allow selection) one or more sparks ButtonBarButtons in a spark ButtonBar, FRONT the ButtonBar is displayed to the customer. The idea here is that some customers will be able to access the component associated with a given ButtonBarButton, and others don't. Information about the client that allows such a decision are available at the time the ButtonBar is being created.

    The application looks like this (extract only the relevant parts, hopefully):

    < s:Panel id = "menuPanel.

    backgroundAlpha = "0.5".

    backgroundColor = "#47177 d".

    cornerRadius = "5".

    Height = "100%".

    skinClass = "com.fedex.refdata.skins.MainMenuSkin"

    title = "{resourceManager.getString (Constants.RESOURCES,"Menu")} '.

    Width = "100%" >

    < s:ButtonBar id = "btnBar".

    dataProvider = "{rdViewStack}".

    fontWeight = "bold".

    Height = "100%".

    horizontalCenter = "0".

    Red = '0 '.

    width = "20%" >

    < s:layout >

    < s:TileLayout columnAlign = "justifyUsingWidth."

    columnWidth = "250".

    horizontalGap = "-1".

    requestedColumnCount = '1 '.

    rowHeight = "25".

    verticalGap = "-1" / >

    < / s:layout >

    < / s:ButtonBar >

    < mx:ViewStack id = "rdViewStack".

    borderStyle = "none".

    Height = "100%".

    Width = "80%" >

    < s:NavigatorContent id = «first»

    Height = "100%".

    label = "{resourceManager.getString (Constants.RESOURCES, 'First')}".

    Width = "100%" >

    < height of component: NavigatorContentComponent1 = "100%" width = "100%" / >

    < / s:NavigatorContent >

    < component id: NavigatorContentComponent2 = 'second '.

    Height = "100%".

    label = "{resourceManager.getString (Constants.RESOURCES, 'Second')}".

    Width = "100%" / >

    < component id: NavigatorContentComponent3 = "third".

    Height = "100%".

    label = "{resourceManager.getString (Constants.RESOURCES, 'Third')}".

    Width = "100%" / >

    < / mx:ViewStack >

    < / s:Panel >

    I was able to disable the components once they were clicked, but I would like to disable the option to still click a ButtonBarButton associated with the component. I could not find the ButtonBarButtons which are created automatically by the ButtonBar to disable them.

    Any help would be greatly appreciated. Thank you.

    Well, I found the answer on my own and thought I'd share. This same issue has already been resolved earlier. See http://blog.flexexamples.com/2009/08/01/disabling-specific-buttons-in-a-spark-buttonbar-co command-flex-4 /. I've implemented the suggestions as written, and I can now 'disable' my ButtonBarButtons before the ButtonBar is displayed. Thanks go to Peter deHaan, the author of this article, for his friendly addition to the community.

  • How to import a menu of first elements 7 (menu Popcorn) in Encore CS4?

    How to import a menu of first elements 7 (menu Popcorn) in Encore CS4?

    If yes how to perform this Act?

    Their additional menus are available for Encore CS4?

    Pre Menus are in the games Menu. Each set is a main Menu and a Menu selection of scenes. As before the semi-automatic creation, there are many 'extras' in the Photoshop PSD, in button layer sets. All you have to do is to make a copy of your two Menus in a separate folder, so that you don't worry everything ruin your Menu sets in pre. I could do this in a new subfolder in the library folder hierarchy yet. Then, each of these two Menus open in PS. Go and clean up all the other languages for the text and the text of the button. Correspond to the names of Layer button Set/Layer Set such naming conventions in the library of the Menus again, because you won't get any semi automation. Where you do not, say a next button, just to eliminate layers of this button. Don't forget, before it will be semi-automatiquement, will give you the number of scene selection Menus, that your project includes - will not be still. You must count the scenes, divide by the number of buttons on this scene selection Menu and make copies of this Menu, to account for what you need.

    For what is still, it comes with a compliment full Menus, buttons and other assets, such as EM files (models), of movement and Audio assets. Everything can be completely customized in PS. Note: in PSElements, I don't believe you can create layer sets, so it will be a limitation. The full PS has no limitation, with the sole exception that to change colors button subpicture highlight, this must be done in the editor Menu in Encore, unless it has been added to the PS CS5.

    Good luck

    Hunt

    PS - don't forget, work on Copies of the two Menus in the set Menu forwards and NOT on the originals, or you do a repair installation to get back them.

  • How can I access menu Firefox 10.0 helps when I am offline?

    How can I access menu Firefox 10.0 help without being connected to the Internet? Is it possible to download the help on my computer menu?

    Firefox had no off-line 'Help' or 'user manual' integrated since 2007 or 2008 - everything has been on the web since then.

  • I just installed menu 24 Firefox and Gmail (Search Images cards Play...) have disappeared. How to restore this menu?

    I just installed menu 24 Firefox and Gmail (Search Images cards Play...) have disappeared. How to restore this menu?

    If it's the black navigation at the top that you bar look, we're sorry, that it has nothing to do with firefox.

    For your information

    The bar is removed by Google, Google updated their menu bars, as last week check out this article for more information http://techcrunch.com/2013/09/19/googles-new-app-launcher-style-navigational-menu-weeks-away-from-launch/

  • Is it possible to restore an iPhone on a previous backup?  My phone was stolen 2 weeks ago and took me off but the thief has changed a lot of my apps and things.  I just want to know whether and how to restore them from before flight

    Is it possible to restore an iPhone on a previous backup?  My phone was stolen 2 weeks ago and took me off but the thief has changed a lot of my apps and things.  I just want to know whether and how to restore them from before flight

    How the thief has changed a lot?

    You do not have a password, find my iPhone ON?

    Read here for the restoration of the backup: http://support.apple.com/en-us/HT201252

  • Satellite 1800-814: how to measure the temperature of the processor?

    I replaced the radiator component on my laptop as it freezes suddenly during the operation. Now everything seems to be better, but still a last question. How to measure the temperature of the processor?

    Dominic displays only HDD temp and MBM profile for 1800-224 display cases and the cpu. But if I can use this profile? Any other ideas how to meausre CPU temp?

    MBM shows me around 40 to 49 ° C for the cpu. Is this normal or too high just to run windows?

    Thanks in advance

    Greetings
    Jens Grieger

    Hello

    See this http://forums.computers.toshiba-europe.com/forums/thread.jspa?threadID=5564&messageID=19417

    Maybe the help!

  • Satellite L500 - how to restore the menu "repair your computer"?

    Hello world

    I have a laptop Toshiba L500, Yestaday I tried to restore the system to the factory settings (by pressing F8 at startup high and choose "repair your computer"). In the system has been installed almost, but at a stage of installation drivers to read memory cards and similar - there was a failure (the blue screen and need down) - after that - Windows 7 is not loaded. parsing errors (by means using a floppy disk to another Windows 7 install) says that the registry is damaged, cannot repair.

    but the main problem - when you press F8 at startup upward - there is no MORE menu 'Repair your computer' (!) . It is impossible to start Windows 7 predefined. So there's the hidden sector containing Windows predefined (I saw when loading a disc of hatch - Total order could start - and hidden sector was visible). All files in drive recovery HARD necessary are also available.

    How to restore the menu "repair your computer"? or how it is possible to start Windows predefined without pressing F8?

    > Hidden article exists, I saw it, there are all the files recovery HARD drive (which was in the laptop after buying), but I can't begin to recover Windows because I don't have menu not 'repair your computer' to start the laptop. He disappeared...
    Of course, the flag in the Advanced Start menu seems to be deleted and therefore drive recovery HARD option isn't available anymore.
    Probably the partition has changed.

    But in case of HARD drive recovery files are still available on the recovery partition, you can try to create the USB support of own recovery using of workaround:

    [How to create a recovery media USB flash drive to the valorisation of the ISO images - or (DVD) discs | http://aps2.toshiba-tro.de/kb0/HTD4103KB0000R01.htm]

    I guess that this directive should be very useful.

  • Is the difference between TSMC and Samsung Chip in the real Iphone 6 s? If this is the case, how can I found it before buying a new? How can I

    Is the difference between TSMC and samsung chip processors in the real Iphone 6 s? If this is the case, how can I found it before buying a new one?

    No, it isn't.

  • How to measure how long a Boolean value is high with thick County?

    I acquire the impulse response of a parallax Distance sensor, but I I don't know how to measure the number of features that this signal is high (the time of the input signal is high is proportional to the distance). I would like to reset the counter thickness when this signal is low. is this possible? Y at - it another option?

    Thank you...

    for (imstuck) wrote:

    You will need to adjust some if you want an indicator of up-to-date at all times.

    Here is a very minimalist version which updates the timer continuously while the switch is on and holds last value when the switch is off. Try it!

  • How to measure the frequency of a clock using meter in LabVIEW?

    Hi guys,.

    Someone knows how to measure the frequency of a signal introduced in LabVIEW (in the FPGA PXI-7813R), using a counter in LabVIEW?

    Essentially, I want to use this counter as a kind of Logic Analyzer.

    Thank you, Anoop

    I don't know what you mean by "manual".  It is all managed in a housing structure.

  • How to measure high voltage (60-70 v) and current (75-80 a) using a DAQ PCI or USB DAQ

    Hello

    I work with a system that works on about 5kW. The output of the system voltage can go maximum up to 60-70 v and thus the corresponding current around 75-80 a. I have 10 these systems that I want to read one by one continuously for long periods.

    I am designing the automated system best suited for this and looking for the best material that would be appropriate for this purpose. Looking for options, I found that an SCC - A10 attenuator may be used to get the tension down by a factor of 10. But I'm confused, if the high current will pose a problem and also how to measure this high current.

    I need to measure the voltage and current at the same time. Please suggest what would be the most appropriate fitting for the same (preferably PCI or USB)

    The hope of a quick response. Thanks and greetings

    Reena Sharma

    Facilitated learning

    Reena says:

    Hi all

    There is good news that the idea of using a compact data acquisition has been accepted by the authorities of the society. I'll be very grateful, if you could suggest me with some hardware modules suitable for my application and how I can use them best.

    Thank you very much

    Reena

    I was able to make a few suggestions, but do not have the time to understand your needs and the forums are not the best solution.

    Your Local OR representitive actully gets paid to do this kind of thing.  a google search suggests THAT LME is in Pasadena. Zack Collins would be the contact rep

  • DO YOU KNOW HOW TO CLEAN THE TASKBAR BEFORE THE ICONS FOR ITEMS FROM THERE?

    HELLO CLASSMATES.

    I WOULD LIKE TO KNOW HOW TO CLEAN THE TASKBAR BEFORE THE ICONS FOR ITEMS FROM THERE.

    PLEASE, I BEG YOU.

    Thank you.

    JOE

    I had the same problem.  Mine was up here an easy solution.   Right-click on the taskbar and display the properties.  Check hide them icons inactive and click Customize.  I had multiple entries in the items being passed, including volume control icon.  Remove the elements in the item passed I have no idea from whence they came.  I ran MicrosoftFixit50015.msi (a Windows package install).  Then re-checked the past again and all elements had disappeared or been corrected.  SEEMS this file or box on the PC has become corrupted.  I changed the control volume on always point display.  Also, I went to control panel and sounds and re-checked the volume icon to Place in the taskbar.   Rebooted the system and has worked for me so far.  Good luck!

  • Anyone know how long it will be before I can connect my Sony vaio vista to the router from the sky?

    I have just a Sony vaio with vista home premium laptop

    It will connect to my new router from Sky, but not to the internet

    can someone tell me how long it will be before the Microsoft fix this problem?

    its driving me crazy that he plugged in without problem on the old router from Sky

    I have no problem with my apple devices or just two other portable Windows vista it is a problem

    Hello! Have you tried contacting the support? Here's the phone number of the sky. Just call them and describe your problem. It could help you, I guess that

Maybe you are looking for

  • Replacement charger

    Hi, I'm on G4 more bike for 5 months and faces a problem with pin support (loose contact). I visited service center and they are ready with the same charger 25W long wired as replacement. I it have not yet collected. Can I substitute a 15W with appli

  • Resize the Windows Server 2003 boot partition

    My client has Server 2003 with a RAID. The system volume / start is 12 GB. Right next to this boot on the partition volume is 30 GB of unallocated space. The rest of the disk is allocated to a separate partition in which all their data lives. Can I e

  • Finding information on the ink using the built-in Web server in Photosmarts

    SAP (built-in web server) is a useful tool which is used in many respects related to networking, it can provide information on Web Services and can also set Static IP and static DNS on the printer. But, if it is connected to the network via Ethernet

  • JSON parsing doubt!

    My Json text is: {{"itemLists": ["2"],"user":{"password":"pwd@103","userId":"103","userType":"SUPPLIER","username":"Clark"}} I wrote json parser such as: try { JSONObject mainouter = new JSONObject(result); JSONArray ja=mainouter.getJSONArray( "itemL

  • BlackBerry Smartphones Can I use my BB8900 charger on my new BB9800?

    I can't find any documentation that explains my old charger (RIM Pt # HDW - 17955 - 001) is or is not approved for use with my new 9800. It is provided only with a Micro USB cable that plugs into an AC adapter. Since I'm working on 2 sites, I like to