Email popup (native.showPopup) Fallback if no email accounts

Hi!

I love the new native.showPopup feature for composing emails. However, while testing it on actual devices I ran into some trouble: On some devices, nothing happened when activating the email pop up.

Turns out, these devices did not have any email accounts added or activated in iOS - meaning, it had nothing to send the email from.

It would be good if there was some kind of fallback or just warning message in these cases, like illustrated here perhaps:

  
local function fallbackFunction()  
 print("No email accounts found!")  
end   
local options =  
 {   
 fallback = fallbackFunction  
 }  
  
native.showPopup("mail", options)  

I apologize if this is the wrong forum for this, but I though it was a pretty crucial sub-feature to implement, to guarantee a smooth working feature. To my users, it looks like a bug that the “email”-button does nothing.

For the record I tested this on iphones and ipads with version 5.0.1.

Thanks [import]uid: 13935 topic_id: 20866 reply_id: 320866[/import]

Please file a bug report/feature request. Some kind of ‘canSupportEmail’ API should have been provided at the get-go.
[import]uid: 7563 topic_id: 20866 reply_id: 82286[/import]

Markus,

We’ve added a new API called [lua]native.canShowPopup(“mail”)[/lua] as of daily build #990. This will allow you to detect if e-mail is available on the device. You can find documentation for this new API on our daily build page in zip form. It’s not available on our website yet since this API is not available in our release version yet.
[import]uid: 32256 topic_id: 20866 reply_id: 137999[/import]

Markus,

We’ve added a new API called [lua]native.canShowPopup(“mail”)[/lua] as of daily build #990. This will allow you to detect if e-mail is available on the device. You can find documentation for this new API on our daily build page in zip form. It’s not available on our website yet since this API is not available in our release version yet.
[import]uid: 32256 topic_id: 20866 reply_id: 137999[/import]