Xamarin.Forms 2.0.1-pre1 Released

TheRealJasonSmithTheRealJasonSmith USXamarin Team Xamurai

Apologies for the light feature/bug list. We were really focused on 2.0.0 and service releases.

Features

  • Add PanGestureRecognizer

Bug Fixes

  • [Android] Resolve issue where AnchorX was sometimes incorrectly represented on Android
  • [Android] Resolve issue where toolbar items sometimes disappeared
  • [Android] Resolve issue where back arrow was wrong color
  • [UWP] Updated ActionSheet to use a ContentDialog and use a more windows friendly theme
  • [XamlC] Fix all sorts of minor issues
  • [WinRT] Entry no longer has erronious padding/display when in password mode
  • [iOS] SearchBar text and placeholder colors now correct
  • [WP8] Resolve issue where calling RemovePage for root of NavigationPage would result in a crash
  • [WP8] Resolve issue where images would sometimes get sized to 0,0 due to measurement before load finishes
«1

Posts

  • MarkoLudolphMarkoLudolph DEMember ✭✭
    edited December 2015

    I am currently porting an app to WP8.1 and I want to use a tabbed page. But actually, there's a padding around the content page (it works fine with a navigation page). Is this a bug (and is there already a ticket for it) or is this intended behaviour?

    image

  • TheRealJasonSmithTheRealJasonSmith USXamarin Team Xamurai

    Im sorry can you be more clear what your page hierarchy is here. I do believe WP adds padding on tabs (its from the default templates, not us).

  • AndreasBrostenAndreasBrosten USMember ✭✭

    I had hoped for mor fixes for WP8. The Forms 2.0 added all sorts of rendering issues. And after a short scan of this forum I can see I'm not the only one with WP8 issues after the Forms 2.0 update.

    Are you (the Xamarin team) aware of the poor WP8 status? Are you working on it?

  • TheRealJasonSmithTheRealJasonSmith USXamarin Team Xamurai

    We are working on it. We are also working on WinRT and UWP improvements. There were major changes in all windows backends to modernize some of the layout mechanisms. Unfortunately such a large fundamental change means lots of shift. We did our best to shake out all the issues but clearly we didn't find them all. We are now working through them.

  • DarkwingDuckDarkwingDuck USMember ✭✭

    I posted a serious bug in TabbedPages on iOS but no one seems to care: https://bugzilla.xamarin.com/show_bug.cgi?id=36251

    When you tap the currently selected tab again the page's toolbar items are gone the next time you switch to this tab/page again. See Bugzilla for a test project.

  • TheRealJasonSmithTheRealJasonSmith USXamarin Team Xamurai

    We care, just not been figured out yet.

  • MarkoLudolphMarkoLudolph DEMember ✭✭

    @TheRealJasonSmith The page layout is really simple: It's one tabbed page (green) as MainPage, with only one content page (red) as child, that's all.

    When I use a navigation page instead of a tabbed page, there's no padding around the content page. So, the behaviour is inconsistent between tabbed page and navigation page.

  • rmarinhormarinho PTMember, Insider, Beta Xamurai

    @MarkoLudolph i think what Jason was trying to say, is that padding is specific to how Pivot renderes natively on WinRT no ? Don't forget that XF maps to native controls and the native UX on the platform, tabs behave different in each platform using each platform ux guidelines. That said i will take a look to make sure.

    @DarkwingDuck thanks, i m able to reproduce, i m on it.

  • MarkoLudolphMarkoLudolph DEMember ✭✭

    @rmarinho Thank's for looking it up. That's why I asked, if it's a bug or desired behaviour.

  • SpaceMonkeySpaceMonkey GBMember ✭✭✭

    @rmarinho

    Just wanted to say thanks, man, you're the only one who fixed the bug I reported after 4 releases of its being ignored. You seem to be doing the same now for the bug reported by @DarkwingDuck

    just to be clear, the bug I reported was the 'android tablet landscape appcompat masterdetailpage toolbar buttons hidden' one, and I can confirm it's fixed now.

  • rmarinhormarinho PTMember, Insider, Beta Xamurai

    @SpaceMonkey no problem everyone is here to help and make Xamarin.Forms better and of course fix bugs. We are always triaging bugs and trying to address the more important ones, and rest assure that everyone on the team is working alot to get more bug fixes and other work that needs to get done under the covers and doesn't get seen by the users.

  • ChaseFlorellChaseFlorell CAInsider, University mod

    PanGestureRecognizer :smiley:

  • ChaseFlorellChaseFlorell CAInsider, University mod
    edited December 2015

    Just sitting down to look at the PanGestureRecognizer. Any chance we can get a 30 second run down on how to use the api? I'm Seeing (int)TouchPoints and a PanUpdated event.

  • MarkoLudolphMarkoLudolph DEMember ✭✭

    Showstopper bug on WP 8.1 @rmarinho @TheRealJasonSmith . OnStart, OnResume and OnSleep on the Application class are not getting called on WP 8.1. I made a test project and followed the Tutorial https://developer.xamarin.com/guides/cross-platform/xamarin-forms/windows/getting-started/phone/ to make sure, it's not a problem with my app. Tested with 2.0 and pre1.

  • robsamcartcomrobsamcartcom USMember ✭✭

    My back arrow is still black. How do I change the color to white like it was in previous versions?

  • MarkoLudolphMarkoLudolph DEMember ✭✭

    Well, according to this http://blogs.msdn.com/b/mspfe/archive/2013/06/17/suspend-and-resume-in-winrt.aspx, Sleep/Suspend is not called automatically, when you move the app in the background, while you are debugging. You have to trigger that manually in VS (wtf, MS). Anyway, OnStart/OnResume are still broken, OnSleep works.

  • GautamJainGautamJain INMember ✭✭✭

    @rmarinho

    The slow scroll bug in editor (iOS) bug has been long pending - https://bugzilla.xamarin.com/show_bug.cgi?id=35184

    It was fixed long time back. It was supposed to be included 2 releases back. But still doesn't exists in 2.0.1-pre1?

  • rmarinhormarinho PTMember, Insider, Beta Xamurai
    edited December 2015

    @Gautam-Jain i just confirmed that this is fixed in 2.0 stable and 2.0.1-pre1 do you have a repro case?

  • rmarinhormarinho PTMember, Insider, Beta Xamurai

    @ChaseFlorell , TouchPoints is the number of fingers you want to monitor to trigger the gesture, here's a short example :

    public class PanContainer : ContentView
            {
                public PanContainer ()
                {
                    var pan = new PanGestureRecognizer {
                        TouchPoints = 2
                    };
    
                    pan.PanUpdated += (object s, PanUpdatedEventArgs e) => {
                        switch (e.StatusType) {
    
                            case GestureStatus.Started: break;
    
                            case GestureStatus.Running:
                                Content.TranslationX = e.TotalX;
                                Content.TranslationY = e.TotalY;
                                break;
    
                            default:
                                Content.TranslationX = Content.TranslationY = 0;
                                break;
                        }
                    };
    
                    GestureRecognizers.Add (pan);
                }
            }
    
            public PanGestureGalleryPage ()
            {
                var image = new Image { Source = "http://placehold.it/2000x2000", BackgroundColor = Color.Gray, WidthRequest = 2000, HeightRequest = 2000, VerticalOptions = LayoutOptions.Center, HorizontalOptions = LayoutOptions.Center };
    
                var panme = new PanContainer { Content = image };
    
                Content = new Grid { Children = { panme }, Padding = new Thickness (20) };
            }
    
  • GautamJainGautamJain INMember ✭✭✭

    @rmarinho

    It was not in the bug fixes list (2.0.0). So I thought that it wasn't included in that release. I will use that. Thanks.

  • RussellCollinghamRussellCollingham GBUniversity ✭✭
    edited December 2015
  • ThibaultDThibaultD SEMember ✭✭✭
    edited December 2015

    "iOS WebView crashes when loading an URL with encoded parameters"
    https://bugzilla.xamarin.com/show_bug.cgi?id=35733
    Was also corrected in 2.0.1.6492-pre1 although it does not appear in the patch note.

    I tested and the problem is gone :)

  • ChaseFlorellChaseFlorell CAInsider, University mod

    Thanks for that @rmarinho, one more, what's the secret to keeping the gesture attached to your finger, and animating it smoothly?

  • rmarinhormarinho PTMember, Insider, Beta Xamurai

    @ChaseFlorell not sure if i understand, it should follow the finger, and the go back to the original position on the example i gave, since we set the translation back to 0, you could also use some math and throttling the events to maybe smooth things out.

  • ChaseFlorellChaseFlorell CAInsider, University mod
    edited December 2015

    @rmarinho, while you're mostly right about the following finger bit, I find that if I remove the default section where it returns to 0, 0, I would "expect" the view to stop exactly where my finger is.

    Also, all of the animations are super jittery, and TranslateTo doesn't seem to help.

        public class PanGestureGalleryPage : ContentPage
        {
            public PanGestureGalleryPage()
            {
                var image = new BoxView
                {
                    BackgroundColor = Color.Gray,
                    WidthRequest = 200,
                    HeightRequest = 200,
                    VerticalOptions = LayoutOptions.Center,
                    HorizontalOptions = LayoutOptions.Center
                };
    
                var panme = new PanContainer {Content = image};
    
                Content = new Grid {Children = {panme}, Padding = new Thickness(20)};
            }
        }
    
    public class PanContainer : ContentView
    {
        public PanContainer()
        {
            var pan = new PanGestureRecognizer
            {
                TouchPoints = 1
            };
    
            pan.PanUpdated += (s, e) =>
            {
                switch (e.StatusType)
                {
                    case GestureStatus.Started:
                        break;
    
                    case GestureStatus.Running:
                        Content.TranslationX = e.TotalX;
                        Content.TranslationY = e.TotalY;
                        break;
    
                    default:
                        Content.TranslationX = Content.TranslationY = 0;
                        break;
                }
            };
    
            GestureRecognizers.Add(pan);
        }
    }
    

    image

  • EvgeniyZverevEvgeniyZverev USMember ✭✭
    edited December 2015

    @MarkoLudolph said:
    Showstopper bug on WP 8.1 @rmarinho @TheRealJasonSmith . OnStart, OnResume and OnSleep on the Application class are not getting called on WP 8.1. I made a test project and followed the Tutorial https://developer.xamarin.com/guides/cross-platform/xamarin-forms/windows/getting-started/phone/ to make sure, it's not a problem with my app. Tested with 2.0 and pre1.

    I posted this a couple of months ago. No attention at all.
    https://forums.xamarin.com/discussion/52524/windows-8-1-windows-phone-8-1-windows-10-related-issues#latest

    Reposting into release 2.0 discussion did not help either.
    https://forums.xamarin.com/discussion/comment/166751/#Comment_166751

    Give up hope on that, use the workaround.

  • rmarinhormarinho PTMember, Insider, Beta Xamurai

    @ChaseFlorell we aren't doing any animations oob, we provide you the values, and the translation effect is up to you..

  • ChaseFlorellChaseFlorell CAInsider, University mod

    Yep, I totally get that @rmarinho, I'm talking more about the jump that you see where the Translation is opposite to the direction I'm swiping.

    I see the values come in, but, for example, with a downwards swipe motion, I don't see the TotalY value climb incrementally. I guess I would expect the TotalY value to climb similar to

    2, 4, 6, 8

    But instead I see

    2, 4, 6, 3, 2, 1

  • BradChase.2654BradChase.2654 USMember ✭✭✭
    edited December 2015

    @ChaseFlorell I am seeing weird results too... here are mine:

    -14.63818359375
    -10.6298828125
    -54.1610107421875
    -39.7008056640625
    -22.06787109375
    -87.366943359375
    -62.6954345703125
    -41.8048095703125
    -41.2557373046875
    -59.154052734375
    -18.3258056640625
    -17.559814453125
    -98.1290283203125
    -40.692626953125
    -41.528076171875
    -45.71337890625
    -22.7691650390625
    -42.531982421875
    -40.664306640625
    -19.662109375
    -18.811767578125
    -36.9491577148438
    -127.198059082031
    -13.347900390625
    -42.5111694335938
    -29.9188842773438
    -15.8697509765625
    -84.1915283203125

    On and on... That is on a gentle swipe across the screen. @rmarinho is this to be expected?

    EDIT: Its almost as if they are out of order, that could be the issue. I cant seem to think of a way to reorder them without some identification. I need to know where the pan is incrementally because the user could go in any direction and I wont know which...

  • SamanthaHoutsSamanthaHouts USXamarin Team Xamurai

    @ChaseFlorell & @BradChase.5446: We are aware of an issue with the PanGestureRecognizer on Android devices, and we'll be fixing it soon. In the meantime, you may want to try testing with an iOS or Windows device instead.

  • Shane000Shane000 USMember ✭✭✭
    edited December 2015

    If I call navigation.PushModalAsync() after app.MainPage = page; on iOS I usually get this:

    Dec 8 16:04:37 My-iPod ProductMobileiOS[1320] <Warning>: Warning: Attempt to present <Xamarin_Forms_Platform_iOS_ModalWrapper: 0x189319d0> on <Xamarin_Forms_Platform_iOS_PlatformRenderer: 0x18964f60> whose view is not in the window hierarchy!

    navigation = current page's INavigation

    Is this a bug I should be filing (it's been around for as long as I can remember) or is there a workaround for knowing when app.MainPage = page; actually completes and puts the view into the view hierarchy?

    thanks

  • BradChase.2654BradChase.2654 USMember ✭✭✭
    edited December 2015

    @SamanthaHouts Ahh ok thanks! I was unaware it was being worked on, thanks again.

    btw I use this to counteract it for now as it gets pretty close:

    if( e.StatusType == GestureStatus.Running ) { Element.TranslationX += (e.TotalX / 3); Debug.WriteLine(Element.TranslationX); return; }

    EDIT: I forgot to mention, THIS IS ONLY TEMPORARY CODE FOR TESTING PURPOSES ONLY! hah make sure I say that because the code has no rhyme or reason.

  • GuiWaltrickeGuiWaltricke BRMember ✭✭
    • Bug, appears in 2.0.0 and still occurs in 2.0

    When the TapGesture is added inside a Frame on Android the Tapped Event is not fired.

    Sample:

    Frame constructor:

    var tapGesture = new TapGestureRecognizer();
    this.GestureRecognizers.Add(tapGesture);
    tapGesture.Tapped += tapGesture_Tapped;
    
    void tapGesture_Tapped(object sender, EventArgs e)
     {
         DisplayAlert("MSG", "Tapped", "Ok");
    }
    

    May i post in bugzilla?

  • Many thanks for fixing: https://bugzilla.xamarin.com/show_bug.cgi?id=35391

    Good Job!

  • LGMaestrelliLGMaestrelli BRMember ✭✭✭

    @GuilhermeWaltricke

    Same problem here...

    TapGestureRecognizer is not firing when added to a frame

  • HenrikPerssonHenrikPersson SEMember
    edited December 2015

    I updated to 2.0.1.6492-pre1
    because I had the special characters in WebView in iOS issue mentioned here
    https://bugzilla.xamarin.com/show_bug.cgi?id=35733

    But I still have the issue. e.g the WebView works with normal characters but when a special character like an "Å" is in it it'll crash.

    I'm running Visual Studio 2015 on Windows and Xamarin and Xamarin.iOS is updated to latest stable

    Have I missed something here?

    Nevermind I got it to work by formatting with Uri

    Also after updating the Xamarin.Forms my Visual Studio now reports thousands of errors where "The name X does not exist in the current context" even though the code compiles and runs fine without any problems.

  • SpaceMonkeySpaceMonkey GBMember ✭✭✭
    edited December 2015

    I found a bug in Frame:

    https://bugzilla.xamarin.com/show_bug.cgi?id=36939

    A null exception is thrown when I do a long tap. It seems to be trying to open a context menu.

  • NMackayNMackay GBInsider, University mod

    There is a bug calling PopToRootAsync when OnResume is raised using FormsAppcompat, thanks to @DirkWilhelm for highlighting this issue

    https://bugzilla.xamarin.com/show_bug.cgi?id=36907

Sign In or Register to comment.