yasirkula / UnityNativeShare

A Unity plugin to natively share files (images, videos, documents, etc.) and/or plain text on Android & iOS
MIT License
890 stars 131 forks source link

Send button does not work - with Messages on Landscape mode #127

Open yosun opened 2 years ago

yosun commented 2 years ago

Description of the bug

Send button does not work - with Messages on Landscape mode

Reproduction steps

Share a texture and a string message from UnityNativeShare API to Messages

Platform specs

Please provide the following info if this is a Unity 3D repository.

https://www.youtube.com/watch?v=GLgQIoLaegM

yasirkula commented 2 years ago

Thanks for the video! Can you see any related logs in Xcode console? Does omitting texture or message make a difference?

yosun commented 2 years ago

I think it has to do with perhaps the length of the string? It seems to work for shorter strings.

Xcode afaik does not record anything since the send button isn't successfully usable

yasirkula commented 2 years ago

Can this be an iOS issue? Could you share a content from WhatsApp to other apps with the same text that you are using with Native Share?

MGGranny commented 2 years ago

I ran in to the same issue with a string with 111 characters. Sharing the same string in WhatsApp works.

yasirkula commented 2 years ago

Does sharing the same string from WhatsApp, Facebook or Twitter to Messages work properly?

MGGranny commented 2 years ago
yasirkula commented 2 years ago

@MGGranny Which NativeShare functions are you calling to initialize the shared data? If you're calling SetSubject, can you omit it and see if it makes a difference?

MGGranny commented 2 years ago

Here you can see the setters I use before the Share call:

        new NativeShare()
            .SetUrl( url )
            .SetSubject( title )
            .SetText( text )
            .SetCallback( ( result, target ) => callback?.Invoke( result ) )
            .Share();

I tried removing SetSubject, SetText and both of them, but the same bug still happened when sharing to Messages app on iOS 15.