Select to view content in your preferred language

Defining Custom Pointer

989
2
01-31-2011 05:49 AM
AlexanderStepanov
Occasional Contributor
Hi All:

I am trying to define some custom pointers for my tools.
( for example toggling map.openHandCursorVisible property will change between "openHand/pan" and "regular" cursor.). I would like to add 2 additional types. Should I work with cursor manager directly in Flex or using AGS Flex API?

I will appreciate if you could point me out to documentation/examples where this issue is discussed.

Kind regards,
Alexander
Tags (2)
0 Kudos
2 Replies
AndyGup
Esri Regular Contributor
Alexander,

Try something like this. Create your own png image and then:

[Embed('../images/i_pointer_cursor.png')]
private var _pointerCursor:Class;

map.cursorManager.setCursor(_pointerCursor,2,0,-3); 



If you want access to default cursors you can try something like this:

Mouse.cursor = MouseCursor.ARROW;


-Andy
Esri Developer Network Team
0 Kudos
AlexanderStepanov
Occasional Contributor
Andy, thank you!

I will try it.

Kind regards,
Alexander


Alexander,

Try something like this. Create your own png image and then:

[Embed('../images/i_pointer_cursor.png')]
private var _pointerCursor:Class;

map.cursorManager.setCursor(_pointerCursor,2,0,-3); 



If you want access to default cursors you can try something like this:

Mouse.cursor = MouseCursor.ARROW;


-Andy
Esri Developer Network Team
0 Kudos