My favorites | Sign in
Project Home Downloads Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 35: how to delete objecthandal selected object
1 person starred this issue and may be notified of changes. Back to list
Status:  New
Owner:  ----


 
Reported by abidr...@gmail.com, Feb 4, 2010
hi all,

how to delete objecthandal selected object.

i try to this code but select object not properly deleted & show every time
his id.


var theSelected:ObjectHandles = SelectionManager.instance.currentlySelected
as ObjectHandles; 
			 	var parentContainer:DisplayObjectContainer;
			 			
		        if(selectedObject != null)
			    {
			 		var txt1:TextArea = selectedObject.getChildAt(0) as TextArea;
				    if(txt1 != null)
	        		{
	        			myRemote.deleteFrontData(sessionid,txt1.id);
	        				
	        		}
		 			if( theSelected != null && theSelected.parent != null ) {
      				
      					SelectionManager.instance.selectNone();        // Cosmetical
stuff, just deselect.
      					parentContainer = theSelected.parent;            // Get the
parent container
      					parentContainer.removeChild( theSelected );   // Remove the
selected OH
    				} 
		 			}

Powered by Google Project Hosting