0

MonoTouch.Dialog:

Using a custom OwnerDrawnElement, I create the Element with a custom Draw()

The Draw() is fired when the element is selected.

How can I tell if the Draw() is fired due to a user Selecting it so that I can change the UI to indicate a Select?

Ian Vink
  • 66,960
  • 104
  • 341
  • 555

1 Answers1

0

Inside this method in the custom OwnerDrawnElement, check for the Highlighted state:

public override void Draw (RectangleF bounds, CGContext context, UIView view)
{
    bool highlighted = this.GetActiveCell().Highlighted;
    if(highlighted) ....
} 
Ian Vink
  • 66,960
  • 104
  • 341
  • 555