Sample code for showing custom cursor (can be used for hand cursor too) in
datagrid. Same can be extended to any component
*Sample datagrid code:*
<mx:DataGrid id="myDatagrid" itemRollOver="*showMyCursor*()"
itemRollOut="*removeMyCursor*()">
<mx:columns><mx:DataGridColumn headerText="name" dataField="name" /> add
more coulmns if needed </mx:columns>
</mx:DataGrid>
*Action script to change mouse pointer to cutom cursor*
[Embed("/assetFolder/myCursorImage.gif")]
private var myCursor:Class;
private var myCursorID:int; //This will be generated automatically
private function *showMyCursor*():void {
if (CursorManager.currentCursorID == CursorManager.NO_CURSOR) {
CursorManager.setCursor(myCursor, CursorManagerPriority.HIGH, 3, 2);
myCursorID= CursorManager.currentCursorID; //It will help in removing the
cursor later
}
}
*Action script to change cutom cursor to mouse pointer*
private function *removeMyCursor*():void {
CursorManager.removeCursor(myCursorID);
//Removes ther cursor with specified Id
}
Hope this helps !!!
Thanks,
Kaushal.
On Tue, Apr 13, 2010 at 8:55 AM, Rajesh <[email protected]> wrote:
> Hi all
>
> I want to show hand cursor when i move my mouse over any Column
> series. I have shown the data labels vertically inside the column
> series. So the hand cursor is not showing properly.
>
> I guess Due to the data labels.
>
> Please provoide me any solution to show hand cursor in this case
>
> Thanks in Advance
>
> Rajesh
>
> --
> You received this message because you are subscribed to the Google Groups
> "Flex India Community" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<flex_india%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/flex_india?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups "Flex
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/flex_india?hl=en.