Share Text for iPadOS 13.2 and 13.2.2 does not bring up "pop-over" window, so does not function.
It appears to work fine on iPhone and and versions iPadOS 13.1 and previous.
Asked on Xamarin Forum.
Pop-Over (activity controller) allows shared text to be sent to various apps
Nothing happens
Share File also does not work
As a workaround/hack until the PR is approved you can call the Share.RequestAsync twice. For some reason, it works this way, to some extent.
await Share.RequestAsync(new ShareTextRequest
{
Text = "Share me!"
});
if (Device.Idiom == TargetIdiom.Tablet)
{
//todo: change after PR #979 for Xamarin.Essensialas is intergrated (https://github.com/xamarin/Essentials/issues/979)
await Share.RequestAsync(new ShareTextRequest
{
Text = "Share me!"
});
}
I've done a little more investigation of this. On my iPad with 12.4.2, the "SourceRect" in the native code is "X=0,Y=0,Width=0,Height=0". On my iPad with 13.2, it is "X=Infinity,Y=Infinity,Width=0,Height=0".
And, now that I think about it, the system "feels" like there is a non-visible pop-up up.
I think if nothing else changes, I will change my PR to check for infinities and replace with 0, unless there is a better idea. (For example, Issue #944 suggests that the pop-up should be top-right).
There appears no way currently for XE Share to position the pop-up, which for the most part is probably OK with most.
As a workaround/hack until the PR is approved you can call the Share.RequestAsync twice. For some reason, it works this way, to some extent.
await Share.RequestAsync(new ShareTextRequest { Text = "Share me!" }); if (Device.Idiom == TargetIdiom.Tablet) { //todo: change after PR #979 for Xamarin.Essensialas is intergrated (https://github.com/xamarin/Essentials/issues/979) await Share.RequestAsync(new ShareTextRequest { Text = "Share me!" }); }
I've done a little test for myself -- I didn't like the results. On iPad with iOS12, I got two pop-ups. On iPad 13.2.2, I did not get any.
@Redth Please approve that PR by bobwhitten as soon as possible and release a new version or preview version on nuget, since this is a mission critical bug and the workaround posted here doesn't work.
I got some comments here that may be useful to discuss: https://github.com/xamarin/Essentials/pull/980#issuecomment-554398486
I don't want to push anyne and I'm very thankful for everyone who contributes on fixing this issue. But no matter how, please do it as soon as possible, it breaks a lot of apps on new iOS devices and developers can't tell the customers not to update their devices to a new stable iPadOS Version
Thanks everyone for working on this. We hope to have an update soon!
@mattleibow @Redth @jamesmontemagno Is there any chance of getting an updated Nuget Package within this week? Due to our release cycle we otherwise have to wait more than 7 weeks to get a new version of our App without that Bug out. I'm very thankful for everyone working on getting that fixed.
Sorry, but no that isn鈥檛 going to happen this week. You鈥檙e best off with forking and building it yourself in this case 馃様
How can the integration of 10 Lines of code on a mission critical bug take longer than 2 weeks? :(
@bobwhitten commited a fix on 12th of November...
This bit of code fixed the issue in our project, on iOS 13.2. Hope it helps.
///hot fix
var window = UIApplication.SharedApplication.KeyWindow;
var vc = window.RootViewController;
while (vc.PresentedViewController != null)
{
vc = vc.PresentedViewController;
}
if (UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Pad)
{
var sr = new CoreGraphics.CGRect(vc.View.Bounds.Width, 20, 0, 0);
ctrl.PopoverPresentationController.SourceRect = sr;
}
//END OF HOTFIX
Please see #980 for more info on how we are going to address this.
I realize this is a seemingly small change and is critical for some. We are going to roll the fix into our next release.
Duplicate of #944 and will be addressed by #1002
@Redth This issue is back.
Please open a new issue with more details.
The bug has returned with iPad 13.4.x
I'm seeing it too. Works on old iPad with 12.4.6. Another breaking change from Apple?
@Redth This is the same bug. This is what the console says when you try to share on iPad:
[LayoutConstraints] Unable to simultaneously satisfy constraints.
Probably at least one of the constraints in the following list is one you don't want.
Try this:
(1) look at each constraint and try to figure out which you don't expect;
(2) find the code that added the unwanted constraint or constraints and fix it.
(
"
"
)
Will attempt to recover by breaking constraint Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in
I can't reproduce this on the simulator with just a simple Share. please open a new bug with repro code.
See #1247. I did not see the [Layout constraint] messages. Also, I could not get simulator to work on my PC/iMac set up -- not sure why. But did repro on both iPad Air & iPad Pro 12.9" with latest iPadOS.
Most helpful comment
Share File also does not work