[flexcoders] Draggable Spark Panel with scrollable text area?

2011-11-07 Thread method_air
How can I make this panel draggable, yet still maintain TextArea scrollability?

s:Panel title=Load Edits Text mouseDown={mouseDownHandler(event)} 
mouseUp=mouseUpHandler(event)
mx:TextArea id=tArea
width=600
height=400
selectable=true

change=editsPasteHandler(event)
/
/s:Panel

protected function mouseDownHandler(event:MouseEvent):void
{
(event.currentTarget as 
UIComponent).startDrag();
}

protected function mouseUpHandler(event:MouseEvent):void
{
(event.currentTarget as UIComponent).stopDrag();
}

Cheers,

Philip



RE: [flexcoders] Draggable Spark Panel with scrollable text area?

2011-11-07 Thread Philip Smith

http://code.google.com/p/force-explorer/source/browse/trunk/Flex/Explorer/src/components/DraggablePanel.as?r=8

To: flexcoders@yahoogroups.com
From: loudj...@hotmail.com
Date: Mon, 7 Nov 2011 22:14:15 +
Subject: [flexcoders] Draggable Spark Panel with scrollable text area?


















 



  



  
  
  How can I make this panel draggable, yet still maintain TextArea 
scrollability?



s:Panel title=Load Edits Text mouseDown={mouseDownHandler(event)} 
mouseUp=mouseUpHandler(event)

mx:TextArea id=tArea

width=600

height=400

selectable=true


change=editsPasteHandler(event)

/

/s:Panel



protected function mouseDownHandler(event:MouseEvent):void

{

(event.currentTarget as 
UIComponent).startDrag();

}



protected function mouseUpHandler(event:MouseEvent):void

{

(event.currentTarget as UIComponent).stopDrag();

}



Cheers,



Philip