[Mono-bugs] [Bug 551940] New: MFMailComposeViewController.MailComposeDelegate / .Finished not working ...

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Nov 2 14:33:06 EST 2009


http://bugzilla.novell.com/show_bug.cgi?id=551940


           Summary: MFMailComposeViewController.MailComposeDelegate /
                    .Finished not working ...
    Classification: Mono
           Product: MonoTouch
           Version: unspecified
          Platform: i386
        OS/Version: Mac OS X 10.6
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Class Libraries
        AssignedTo: gnorton at novell.com
        ReportedBy: fbergman at u.washington.edu
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US)
AppleWebKit/532.3 (KHTML, like Gecko) Chrome/4.0.223.11 Safari/532.3

Thank you so much for pointing out that you do have a
MFMailComposeViewController. I've been working with it and for the first times
it was just not working correctly for me. I was setting up the controller, and
then made sure it would disappear by setting the finished event to: 

controller.Finished += delegate { DismissModelViewControllerAnimated(true);};

unfortunately this was never called by the runtime. I think it should!

next i created a new class which inherited from
MFMailComposeViewControllerDelegate and implemented the Finished method there,
which basically just called
controller.DismissModelViewControllerAnimated(true). 

I then assigned an instance of the class to controller.MailComposeDelegate ...
but to my surprise this delegate was never called. It really should!!!

In a last ditch effort i looked at other methods available ... as it turns out
if i use controller.WeakMailComposeDelegate and assign an instance of my
MFMailViewcontrollerDelegate subclass, then it works. And i can finally dismiss
the modal view controller.


Reproducible: Always

Steps to Reproduce:
1. create an instance of MFMailViewController
2. implement .Finished event, or subclass MFMailViewControllerDelegate,
implement finished and assign an instance to controller.MailComposeDelegate
3. display controller with presentModalViewController(controller, true)
Actual Results:  
the mail view controller is displayed, however cannot be dismissed! because the
finished method is never called. 

Expected Results:  
the mail controller should be dismissed on a press to cancel / sent

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list