I am using latest Monotouch 5.2.4. As part of my development, I am trying to change the background border of the Popover controller. As per apple documentation, this can be managed using a custom class inherited from UIPopoverBackgroundView class.
So I have created such class as below
public class MyPopoverBackground : UIPopoverBackgroundView
{
public MyPopoverBackground ()
{
UIImageView imgBackground = new UIImageView();
UIImage img = UIImage.FromFile(@"SupportData/Popbg.png");
img.StretchableImage(18,10);
imgBackground.Image = img;
this.AddSubview(imgBackground);
}
}
After creation of this class, I am trying to associate this view with the Popup object I have in my view controller. It's defined as below
UIPopoverController popup = new UIPopoverController(searchPage);
popup.popOverBackroundViewClass = new MyPopoverBackground(); //This line throws compilation error
The last line in above code, where the assignment is happing throws compilation error ("does not contain definition for..").
What does this mean? Is this not supported in Monotouch (seems to be supported in Objective-C as I see many examples online)? Or I am missing something.
Appreciate your help.