Selecting objects by their stage location

I'm trying to create an application that will allow searching of a database and create resulting movie clips on the stage. Is there a way to select all the movie clips that fall within a certain region of the stage?
Thanks,
Dave

I guess a lot depends on each use case but in principal you can loop through stage children and put the once that fall into certain area into an array. Something like this:
var collection:Array = [];
var currentChild:DisplayObject;
var chldrentNumber:int = stage.numChildren;
// child boundaries
var childBounds:Rectangle;
// stage area boundaries
var boundaries:Rectangle = new Rectangle (50, 50 , 400, 400);
for(var i:int = 0; i < chldrentNumber; i++) {
     currentChild = stage.getChildAt(i);
     childBounds = currentChild.getBounds(stage);
     if (childBounds.x >= boundaries.x &&
          childBounds.y <= boundaries.y &&
          childBounds.y + childBounds.height <= boundaries.height &&
          childBounds.x + childBounds.width <= boundaries.width) {
          collection.push(currentChild);

Similar Messages

  • Selectively import iPhoto albums (and keep them in their current location)?

    I'm new to Aperture.
    I have about 60,000 photos in iPhoto. I would like to import my iPhoto collection in year-by-year albums to break up this collection to more manageable pieces. I've made smart albums in iPhoto for each year.
    From Aperture I would like to import these albums while keeping the photos in the iPhoto library.
    I assume I would click the 'import' icon (top left), then navigate to my iPhoto library in the bottom pane, select the album from iPhoto, choose 'Store files: In their current location' and go.
    Problem: my iPhoto library does not appear in the file browser from the import window.
    Am I doing something wrong here? How would I accomplish this? Is there a different/better way to achieve this?

    I had the same idea as you about a year or more ago. The problem with importing iPhoto images into Aperture by reference is that when iPhoto gets updated and its library layout changes (happens every major iPhoto update), Aperture has trouble finding the images. When you try to relocate masters, you cannot peek into the iPhoto library package to reconnect them so you're screwed.
    I have changed my strategy. I now keep all images in Aperture and only copy images into iPhoto when I need some iPhoto feature such as calendars or greeting cards.

  • Can we have a stage location outside the Server?

    I am using Weblogic 9.2 and I need to have a stage location outside the server.
    I can use No Stage option when I deploy, but on Cluster I found that it has only one source location for the Cluster. So on the second node, it looks for the same location as the first node and if it is different, it will not get deployed.
    I can make it working by keeping that location shared between the nodes. But I don't want to this.
    Here is the details I need:
    1. In Cluster, is there any way to specify different source location for different Servers in the Cluster.
    2. In the config.xml, can I use any variable(which is defined somewhere) for the location which has different values on different nodes(first node and second node)
    3. If I use External Stage mode, can I specify a stage location outside the server.
    If any one have any information, please help me.

    Look at OSS <a href="https://service.sap.com/sap/support/notes/133381">Note 133381 - Database-Hints in Open SQL for MS SQL Server</a> (Basic note is <a href="https://service.sap.com/sap/support/notes/129385">Note 129385 - Database hints in Open SQL</a>
    Extract:
    Index selection is controlled using the table hint "INDEX(index_val [,...n])" as described in Books-On-Line.
    In addition the MSSQL db interface provides another way to specify which index to use. This feature allows a hint syntax like this:
              o %_HINTS MSSQLNT 'TABLE <tablename> INDEX(<suffix>)'.
    Regards

  • Adding objects to the stage & acceessing stage properties - I'm a bit confused..

    Hi,
    I'm a little confused on two fronts regarding display
    programming:
    A. What the best way to add objects to the stage?
    B. How to access stage properties.
    I can do both of these when the project is an 'Action Script
    Project', but I'm having trouble when it is a 'Flex Project' (e.g.
    an MXML file). See the two attached files with questions included
    in the comment to see exactly what I mean.
    A. What the best way to add objects to the stage?
    =====================================
    In an action script project that extends Sprite I can just
    call addChild()
    In an MXML project I can add objects to the stage by first
    adding them to a UIComponent, then adding that to the stage.
    1. Is that the best way to do it?
    In this doc:
    http://livedocs.adobe.com/flex/3/html/help.html?content=05_Display_Programming_02.html
    it says that
    quote:
    Each SWF file has an associated ActionScript class, known as
    the main class of the SWF file. When Flash Player opens a SWF file
    in an HTML page, Flash Player calls the constructor function for
    that class and the instance that is created (which is always a type
    of display object) is added as a child of the Stage object. The
    main class of a SWF file always extends the Sprite class
    2. why cant I just add a sprite object direct to the stage
    without the UIComponent?
    3. What is the 'main class', and how can i get access to it?
    B. How to access stage properties.
    =========================
    In an action script project that extends Sprite I can just
    call trace(stage.framerate)
    But in an MXML file I cannot figure out how to access the
    stage properties.
    See the attached code for the things that I tried, but which
    didnt work.
    In the page:
    http://www.actionscript.org/forums/showthread.php3?t=140655
    It says
    quote:
    For stage access you have a couple of rules:
    * natively, only display objects have inherent access to
    stage
    * display objects only have a valid reference to stage if
    they're within the stage's display list (on the screen, after added
    to it with addChild)
    * The only display objects which immediately have access to
    the stage before the use of addChild (in their constructor) are the
    document/application class instance (root) and any instance from
    the library placed on the timeline (not created with AS).
    * Non-display object classes have to be passed or assigned a
    reference to the stage from another object which already has access
    to it - they cannot access it otherwise.
    4. How do I access the stage properties in the MXML project?
    5. I suspect this is related to the "main class", which I
    dont yet understand - is it?
    Sorry for the long post.
    cheers
    tom

    "tom saffell" <[email protected]> wrote in
    message
    news:gd7cm9$d1v$[email protected]..
    > Thanks Luigi - that helps a lot.
    > I hadnt seen the Flex 3 Developer Guide before - it's
    very useful.
    >
    > I now see that I can access properties of the
    application object directly
    > with
    > this.<property>.
    > However, the framerate property cannot be set by
    actionscript, only in
    > MXML (I
    > can set it in the <mx:application> tag). But I
    need to be able to set it
    > programatically, dependent on user input.
    >
    > 5. Is there a way around this?
    > 6. Can I set the stage's framerate to achieve the same
    outcome?
    >
    > I still dont understand why I cannot access the stage
    object. When I call
    > either
    this.stage or
    uic.stage * then I get
    quote:
    Cannot access
    > a
    > property or method of a null object reference.
    My understanding is
    > that I
    > can access the stage object via any display object on
    the display list.
    > I'm
    > confused about this bit..
    >
    > * - uic is a UIComponent that has been added to the
    display list (i think)
    > by
    > calling addChild(uic) from the AS3 within the
    application
    >
    > 7. How do I access stage properties in AS3 in an MXML
    project?
    http://www.adobe.com/livedocs/flex/3/html/help.html?content=05_Display_Programming_10.html
    It seems like possibly your real problem is that you're
    having trouble
    searching the Help effectively:
    http://flexdiary.blogspot.com/2008/07/getting-help-in-flex-builder.html

  • DropTarget check against all objects on the stage

    Hey all,
    Not sure the best way to do this.  I have a class we will call DropActivity, here is the code
    package com.activitycontrol
              import com.activitycontrol.DropCheck;
              public class DropActivity
                   // Constants:
                   // Public Properties:
                   // Private Properties:
                   private var _selectedClip:Object;
                        // Initialization:
                        public function DropActivity(/*selectedClip:Object*/)
                        // Public Methods:
                        public function set selectedClip(selectedClip:Object):void
                                  _selectedClip = selectedClip;
                        public function stopDraggingMe():void
                                       var dropCheck:DropCheck = new DropCheck();
                                       //dropCheck.checkAgainst = dropTarget.name; ///***********
                                       if (dropCheck.canBeDropped == true)
                                            _selectedClip.stopDrag();     
                        // Protected Methods:
    when the stopDraggingMe() method is called from another object (code shown below) I need to see all the objects on the stage to see what objects on the stage my currently selected movie clip is over and assign it to the dropCheck.checkAgainst method (that will be checked against an array to see if it can in fact be dropped, if so set the canBeDropped value to true and therefor run the .stopDrag() ).  I have read using root is not a good coding practice in AS 3.
    call to the stopDraggingme() mehod.
    private function setDown(event:MouseEvent):void
                             var droppedItem:DropActivity = new DropActivity();
                             droppedItem.selectedClip = this;
                             droppedItem.stopDraggingMe();

    No, I think I can use drop target, I just need to use it from the DropActivity class and not a document class. I just don't know how to use it from a non-document class.
    "and you need to loop through all displayobjects to see which have a positive hitTest with your dropped object, correct?"
    I am trying to say..... ok, what movie clip is currently under the one I have selected,  the drop activity class knows what object I have selcted as it is in the selectedClip variable.  so I need to find out what clip is under it ......... the light just came on!
    answer duh......dropCheck.checkAgainst = _selectedClip.dropTarget.parent.name;
    thanks a bunch kglad you have helped me out once again, you are the man. I might just have to buy you a beer one of these days.

  • ERROR: OUI files not found at their expected location. while cloning 11.5.9

    Dear Friends,
    Getting error when cloning 11.5.9 from PROD to DEV:
    ERROR: OUI files not found at their expected location. Please make sure that the pre-requisit OUI patch was applied correctly: patch should be unzipped directly at the ORACLE_HOME root level so that
    <iAS ORACLE_HOME>/oui21/oui/lib/OraInstaller.jar exists.
    Restart adclone.pl after performing required corrections.
    I applied the patch 5035661 also but still the error exists.
    Please let me know the fix.
    [appldev@betestoracle bin]$ perl adcfgclone.pl appsTier
    First Creating a new context file for the cloned system.
    The program is going to ask you for information about the new system:
    Enter the values for the new APPL_TOP Context:
    Does the target system have more than one application tier server node (y/n) [n] ?:
    Is the target system APPL_TOP divided into multiple mount points (y/n) [n] ?:
    Target system APPL_TOP mount point [apps/applprod/prodappl]:/apps/DEV/devappl
    Target system COMMON_TOP directory [apps/applprod/prodcomn]:/apps/DEV/devcomn
    Location of JDK 1.3.1 on the target system [usr/java/jdk1.3.1_10]:
    The new context file has to contain port numbers related to target system.
    Do you want to preserve the port values from the source system on the target system (y/n) [y] ?:n
    Clone Context uses the same port pool mechanism as the Rapid Install
    Once you choose a port pool, Clone Context will validate the port availability.
    Enter the port pool number:[0-99]
    50
    Checking the port pool 50
    done: Port Pool 50 is free
    Web Listener port is 8050
    Complete port information available at /apps/DEV/devappl/admin/out/PROD_betestoracle/portpool.lst
    Backing up /apps/DEV/devappl/admin/PROD_betestoracle.xml to /apps/DEV/devappl/admin/PROD_betestoracle.xml7.bak
    Creating the new APPL_TOP Context file from :
    /apps/DEV/devappl/ad/11.5.0/admin/template/adxmlctx.tmp
    The new APPL_TOP context file has been created :
    /apps/DEV/devappl/admin/PROD_betestoracle.xml
    Log file located at /tmp/CloneContext_05131045.log
    Please enter the APPS password:
    apps
    Running Rapid Clone with command:
    perl ./adclone.pl java=/apps/DEV/devcomn/util/jre/1.1.8 mode=apply stage=/apps/DEV/devcomn/clone component=appsTier method=CUSTOM appctxtg=/apps/DEV/devappl/admin/PROD_betestoracle.xml
    ERROR: OUI files not found at their expected location. Please make sure that the pre-requisit OUI patch was applied correctly: patch should be unzipped directly at the ORACLE_HOME root level so that
    <iAS ORACLE_HOME>/oui21/oui/lib/OraInstaller.jar exists.
    Restart adclone.pl after performing required corrections.
    Starting application Services for PROD:
    Running:
    /apps/DEV/devcomn/admin/scripts/PROD_betestoracle/adstrtal.sh APPS/<appspwd>
    Regards,
    DB

    ERROR: OUI files not found at their expected location.Please see these docs.
    Troubleshooting RapidClone issues with Oracle Applications R12 [ID 603104.1] -- adcfgclone.pl appsTier fails with "ERROR: OUI files not found at their expected location"
    Preclone DBtier Fails: Error: Oui Files Not Found [ID 739589.1]
    Troubleshooting Guide and Known Issues List for the Oracle Application Management Pack for Oracle E-Business Suite [ID 812294.1]
    Application Management Pack for Oracle E-Business Suite Release 2.0.x Troubleshooting Guide [ID 412044.1]
    Thanks,
    Hussein

  • Can't edit objects on the stage

    Hi,
    I'm stumped helping my colleague on the issue below so I'm logging this question.
    Issue: My colleague is trying to edit a slide but can't edit any of the objects on the stage. However, it works fine when I open the same project on my machine. Is there a setting on her machine that's causing the issue?
    In the screenshot below, check out Slide 2 (selected) notice how:
    in the thumbnail there are multiple objects (white image on the left, blue text caption in the center) on the slide.
    in the timeline multiple objects are available and selectable. All are set to be visible (the little "eye" isn't switched to off).
    when you look at the stage, the only things that we see are the background and a single button.
    The objects also appear fine in Preview.
    On the stage, can "phatomly" select objects, but she can't change the characteristics of them (e.g., change text in a text caption, resize object, move object).
    Screenshot:
    OS: Windows 7
    Captivate: v5.5 (running as Administrator)
    Background info:
    This project was initially created in an older Captivate version (4.0 or 5.0) and is now being edited/updated.
    Last week, my colleague was trying to edit the same project (using v5.0). When she clicked play on the timeline, her audio wouldn't play. When she watched the Preview or tried to edit the audio, the audio would play just fine. Also, on my machine (running v5.5) it worked fine. This prompted me to suggest that she update to v5.5. Alas, it seems this fixed the audio issue, only to create this video issue.
    Thanks,
    - Dino

    Here's a bigger/better quality image. I hope it helps.
    Notice how the Text Caption is selected in the timeline and it's properties are visible on the right. Yet the item itself is nowhere to be seen on the stage. Also, now it seems to have disappeared from the thumbnail.

  • Aperature Import - storing files in their current location

    I imported my archive of photos from my server into Aperture while continuing to store my files in their current location.
    I noticed about 5 folders were skipped. (I have them organized in years back to 1968, and only 5 years didn't import) All have sub folders of .jpg files.
    When I went back to import these folders individually into the project, from the project folder using the import icon, I don't get a button to import them. It says "no files to import"
    When I try to ad them right clicking on what I want to be the parent folder and adding a folder, I can select the folder, click import, and a dialog box pops up saying "Import incomplete, 0 images have been imported into your library."
    I can't seem to figure out why these files were skipped and why I can't import them?
    Any ideas?

    Hi MtnMac2;
    Have you attempted to open any of these photo with any other application?
    Allan

  • 'select objects: click and drag to select several objects' doesn't work

    I have recently upgraded to Office 2010, and have the same problem as
    http://social.technet.microsoft.com/Forums/en-US/office2010/thread/75270638-e02b-4a78-b291-043abbca04ae?prof=required
    When I use Select - Select Objects in the Editing part of the ribbon to select multiple drawing shapes, it no longer works like in office 2007. I can't drag a rectangle in the document to select objects within an area.
    I would have guessed this is the same problem as the link I refer to, but I'm not running the beta version of 2010. It seems not to be solved.
    Anything I can do to fix this?

    I have just registered so I could reply to this thread.
    The registration process was very ... aehm ... frustrating, I was only able to fill in the correct Captcha after about 10 ties. But ... this is not unexpected, when working with a Microsfoft product. How am I supposed to know whether that bloody captcha
    wants me to to write '4Yp8' or '4yP8'. There is no way to tell. You can distinguish capital letters when it is something like A, a or H, h, but not between y and Y or P and p.
    I would like to thank all the posters for suggested workarounds. They work. Kinda - sorta ... . I was able to finish the editing of large picture (consisting of many graphics objects) that HAS to be made in word (My boss said so). All your tips saved
    me *hours* of frustration.
    I would like to tell Microsoft programmers AND their managers, that *if* the quote in the second post is correct: 
    ================
    The work needed to make the object selection work as it did in Word 2007 was out of scope for this release. It's not as
    simple as using the same feature that existed in the last version since we upgrading our graphics/art features; the way the shapes/objects need to be selected is different than how "old" graphics/art is selectable in Word 2007.
    That said, the "select object" tool that exists in Word 2010 should allow you to select individual shapes. You can select
    multiple shapes holding down the CTRL or SHIFT key while clicking shapes. You might ask how this is different than selecting shapes without turning on "select objects"; the answer to that would be to allow you to select shapes that are "behind" text, or more
    easily select rotated shapes, etc.
    ================
    You are bunch of incompetent amateurs. 
    If I used such lame excuse for missing important functionality at work, I would be very soon replaced by a more competent programmer.
    This time I am not a programmer, I am AN USER. And, as an user I do not care if your internal data structure for new objects doesn't let you do something easily. Find a way to implement that feature or change the data structure. Period.

  • My Itunes library files looses their file location

    My Itunes library files looses their file location only if I select them. If I close Itunes and then start again they are all there. It is only when I select one or any of my library files, that Itunes "looses" them and I have to manually "locate" them. Several sofeware "upgrades" back, ITunes worked fine. Apple is sending too many "patches" and is about to LOOSE ME....

    Each time you restart iTunes it assumes that all the tracks are where it thinks they are. The exclamation marks only show up if iTunes attempts to do something with the files and cannot find them.
    Possible causes are that you or some third party tool like WIndows Media Player have moved, renamed or deleted the files, or that the drive they live on has changed drive letters. It is also possible that iTunes has changed from expecting the files to be in the pre-iTunes 9 layout to post-iTunes 9 layout,or vice-versa, and so is looking in slightly the wrong place.
    Select a track with an exclamation mark, use Ctrl-I to get info, then cancel when asked to try to locate the track. Look on the summary tab for the location that iTunes thinks the file should be. Now take a look around your hard drive(s). Hopefully you can locate the track in question. If a section of your library has simply been moved, or a drive letter has changed, it should be possible to reverse the actions.
    Alternatively, as long as you can find a location holding the missing files, then you might be able to reconnect iTunes to them using my FindTracks script. To start with test it out on a handful of tracks that show up as missing in action. If it can find & repair the links to those throw larger selections at it until everything is connected.
    tt2

  • Why does the new operating system not delete the moved files from their original location - it seems like an enormous waste of space, time and effort to clean up every file once you've moved it

    Why does the new operating system not delete the moved files from their original locations - it seems like an enormous waste of space, time and effort to clean up every file once you've moved it - also, when transferring large amounts of files it becomes a very large problem remembering which files were transferred and which not.

    You're going to need to be more specific, as I'm not quite sure I understand what you're talking about.
    If you're referring to copying from an external hard drive or flash drive, and you want to actually move files rather than copy them, you can hold down the option key to force it to do a "move" rather than a "copy." This is not new behavior, though... the Mac OS has worked this way as long as I can recall (and I've been using it since 1984).
    If you're having a problem with trying to move files from one place to another on a single drive causing them to be copied instead, that is likely because of some permissions issue preventing you from actually being able to move them.

  • I have consolidate my folders related to the video I am in the progress of working on.  Premiere elements does not follow their new location.  How do I syn them back up all at once so premiere doesn't ask me for their location when I open the project

    I have consolidate my folders related to the video I am in the progress of working on.  Premiere elements does not follow their new location.  How do I syn them back up all at once so premiere doesn't ask me for their location when I open the project

    This is the Photoshop Elements forum, not the Premiere Elements forum, located here:
    https://forums.adobe.com/community/premiere_elements
    When you open the project, it should ask you where the first file is located. After you tell it where it is, it should be able to find the rest of them if they are located near the first one.  Then save the file.  If you move the files again, you will have to relink them again.

  • Service template problem - Unable to perform the job because one or more of the selected objects are locked by another job - ID 2606

    Hello,
    I’ve finally managed to deploy my first guest cluster with a shared VHDX using a service template. 
    So, I now want to try and update my service template.  However, whenever I try to do anything with it, in the services section, I receive the error:
    Unable to perform the job because one or more of the selected objects are locked by another job.  To find out which job is locking the object, in the jobs view, group by status, and find the running or cancelling job for the object.  ID 2606
    Well I tried that and there doesn’t seem to be a job locking the object.  Both the cluster nodes appear to be up and running, and I can’t see a problem with it at all.  I tried running the following query in SQL:
    SELECT * FROM [VirtualManagerDB].[dbo].[tbl_VMM_Lock] where TaskID='Task_GUID'
    but all this gives me is an error that says - conversion failed when converting from a character string to uniqueidentifier msg 8169, level 16, State 2, Line 1
    I'm no SQL expert as you can probably tell, but I'd prefer not to deploy another service template in case this issue occurs again.
    Can anyone help?

    No one else had this?

  • Unable to remove a host from VMM - Error (2606) Unable to perform the job because one or more of the selected objects are locked by another job.

    I am unable to remove a host from my Virtual Machine Manager 2012 R2. I receive the following error:
    Error (2606)
    Unable to perform the job because one or more of the selected objects are locked by another job.
    Recommended Action
    To find out which job is locking the object, in the Jobs view, group by Status, and find the running or canceling job for the object. When the job is complete, try again.
    I have already tried running the following command in SQL Server Management Studio
    SELECT * FROM [VirtualManagerDB].[dbo].[tbl_VMM_Lock] where TaskID='Task_GUID'
    I received this error back:
    Msg 8169, Level 16, State 2, Line 1
    Conversion failed when converting from a character string to uniqueidentifier.
    I have also tried rebooting both the host and the Virtual Machine Manager Server.  After rebooting them both, I still receive the same error when trying to remove the host.
    Here are my server details
    VMM Server OS = Windows 2012 Standard
    VMM Version = 2012 R2 3.2.7510.0
    Host OS = Windows 2012 R2 Datacenter
    Host Agent Version = 3.2.75.10.0
    SQL Server OS = Windows 2012 Datacenter
    SQL Version = 2012 SP 1 (11.0.3000.0)

    Hi there,
    How many hosts are you managing with your VMM server?
    The locking job might be the background host refresher job. Did you see any jobs in the jobs view, when the host removal job failed?
    If there is no active jobs in the jobs view when this host removal job fails, can you please turn on the VMM tracing, retry the host removal, and paste back the traces for the failed job (search for exception and paste the whole stack)?
    Thanks!
    Cheng

  • How do I restore files to their original location from the trash bin?

    I accidentally deleted a large number of files. I was trying to delete a certain type of file from a specific folder, but ended up deleting all of the files of that type from the computer and, worse, from the external hard drive docked on my desktop. We are talking about 6000+ files. I could not in five years manually copy these files back into their original locations. I deleted additional files after this before I realized what was happening, so I've used up my one undo. Is there no way in Mac OS X to automatically restore these files back to their original locations? It's worth noting that I have not emptied the trash bin; the files are all still there, and this is a brand new computer, so Time Machine hasn't been configured (even if it had been, the external hard drive I would have used for back up is the one I would need to be restoring these files to). You would think something like spotlight, so proficient at finding the file types I was looking for, would also be able to put them back to their original locations.

    That is a feature available in Windows but not on you Mac. Your only slender hope is Undo, but it only has one go, and you say you've used it.
    If the task of relocating them seems impossible, and you say the machine is brand new, then the quickest thing would be to reinstall the OS and start again, as you would not have personalised/changed it much, so soon.

Maybe you are looking for

  • Problem with Flash player in Ubuntu 11.04 for Firefox

    I am running Ubuntu 11.04 on my laptop and use firefox as my main browser. I have a very strange experience when browsing video sites like Youtube.com or Bumperhit.com Some videos are playing all right. But some others, show an error message "Please

  • How to forward a page from multiple frames

    hi,, in my first jsp page there are 4 frames header ,footer,one left frame and right frame in my header log out is there if im clicking logout it should forward to login page.it is happening but that page is coming within that header part(frame).how

  • Since updating to iOS 6, I cannot access any of my purchased movies in the cloud

    on any of my devices (ipad 3, ipad 2, iPhone 4S or iPhone 4) but I can access them via Apple TV.  I have hundreds of purchased movies, so its not rescinded rights by the networks/studios.  I have restarted the devices. I've deleted settings.  I hones

  • External Hard Drive- switching from Mac to PC?

    I have an External Hard Drive that I purchased and have been using on my Powerbook G4. If I plug it into a PC, will it lose all my data or screw something up, or is that transition safe? I never formatted the EHD manually like someone suggested, it d

  • This styles file is bad or corrupted- Elements 3.0

    Ok so, I use photoshop elements 3.0, and the other day something weird happened and now it refuses to work. A few days ago it was fine and working well, but suddenly something pops up saying "This styles file is bad or corrupted" and it just suddenly